When gcc isn't built with gcc, we get if (arch) { /* FIXME: i386 is wrong for 64bit compiler. How can we tell if we are generating 64bit or 32bit code? */ cpu = "i386"; } else cpu = "generic";
It is suggested to use size of (void *): http://gcc.gnu.org/ml/gcc/2006-12/msg00651.html However, it only checks the pointer size of the compiler which is used to build gcc, not the pointer size of the gcc. -- Summary: -mtune=native is wrong when not built with gcc Product: gcc Version: unknown Status: UNCONFIRMED Severity: enhancement Priority: P3 Component: target AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: hjl at lucon dot org GCC target triplet: i686-pc-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30336