Hello! > As reported in [1] the host processor detection has not yet been updated > to recognize Intel Ivy Bridge and Haswell processors. > This small patch adds the detection of these processors and assumes > core-avx2 as march for unknown processors of the PENTIUMPRO family that > support AVX2.
I have committed slightly improved (attached) patch that uses core-avx-i for IvyBridge and adds another IvyBridge model number. While there, I also reordered a bunch of statements. Thanks, Uros.
Index: driver-i386.c =================================================================== --- driver-i386.c (revision 202024) +++ driver-i386.c (working copy) @@ -644,13 +644,18 @@ const char *host_detect_local_cpu (int argc, const /* Atom. */ cpu = "atom"; break; + case 0x0f: + /* Merom. */ + case 0x17: + case 0x1d: + /* Penryn. */ + cpu = "core2"; + break; case 0x1a: case 0x1e: case 0x1f: case 0x2e: /* Nehalem. */ - cpu = "corei7"; - break; case 0x25: case 0x2c: case 0x2f: @@ -662,20 +667,23 @@ const char *host_detect_local_cpu (int argc, const /* Sandy Bridge. */ cpu = "corei7-avx"; break; - case 0x17: - case 0x1d: - /* Penryn. */ - cpu = "core2"; + case 0x3a: + case 0x3e: + /* Ivy Bridge. */ + cpu = "core-avx-i"; break; - case 0x0f: - /* Merom. */ - cpu = "core2"; + case 0x3c: + /* Haswell. */ + cpu = "core-avx2"; break; default: if (arch) { /* This is unknown family 0x6 CPU. */ - if (has_avx) + if (has_avx2) + /* Assume Haswell. */ + cpu = "core-avx2"; + else if (has_avx) /* Assume Sandy Bridge. */ cpu = "corei7-avx"; else if (has_sse4_2)