--- a/gcc/config/i386/driver-i386.c +++ a/gcc/config/i386/driver-i386.c @@ -637,33 +637,27 @@ const char *host_detect_local_cpu (int argc, const char **argv) } else if (vendor == signature_CENTAUR_ebx) { - if (arch) + processor = PROCESSOR_GENERIC; + + switch (family) { - switch (family) - { - case 6: - if (model > 9) - /* Use the default detection procedure. */ - processor = PROCESSOR_GENERIC; - else if (model == 9) - cpu = "c3-2"; - else if (model >= 6) - cpu = "c3"; - else - processor = PROCESSOR_GENERIC; - break; - case 5: - if (has_3dnow) - cpu = "winchip2"; - else if (has_mmx) - cpu = "winchip2-c6"; - else - processor = PROCESSOR_GENERIC; - break; - default: - /* We have no idea. */ - processor = PROCESSOR_GENERIC; - } + default: + /* We have no idea. */ + break; + + case 5: + if (has_3dnow || has_mmx) + processor = PROCESSOR_I486; + break; + + case 6: + if (model > 9) + /* Use the default detection procedure. */ + ; + else if (model == 9) + processor = PROCESSOR_PENTIUMPRO; + else if (model >= 6) + processor = PROCESSOR_I486; } } else @@ -694,7 +688,17 @@ const char *host_detect_local_cpu (int argc, const char **argv) /* Default. */ break; case PROCESSOR_I486: - cpu = "i486"; + if (arch && vendor == signature_CENTAUR_ebx) + { + if (model >= 6) + cpu = "c3"; + else if (has_3dnow) + cpu = "winchip2"; + else if (has_mmx) + cpu = "winchip2-c6"; + } + else + cpu = "i486"; break; case PROCESSOR_PENTIUM: if (arch && has_mmx) @@ -798,7 +802,9 @@ const char *host_detect_local_cpu (int argc, const char **argv) } else if (has_ssse3) { - if (has_movbe) + if (vendor == signature_CENTAUR_ebx) + cpu = "x86-64"; + else if (has_movbe) /* Assume Bonnell. */ cpu = "bonnell"; else @@ -817,8 +823,13 @@ const char *host_detect_local_cpu (int argc, const char **argv) /* It is Pentium M. */ cpu = "pentium-m"; else if (has_sse) - /* It is Pentium III. */ - cpu = "pentium3"; + { + if (vendor == signature_CENTAUR_ebx) + cpu = "c3-2"; + else + /* It is Pentium III. */ + cpu = "pentium3"; + } else if (has_mmx) /* It is Pentium II. */ cpu = "pentium2";