diff options
author | Ryan Hill <rhill@gentoo.org> | 2013-08-29 04:45:57 +0000 |
---|---|---|
committer | Ryan Hill <rhill@gentoo.org> | 2013-08-29 04:45:57 +0000 |
commit | 0f82b30a245a0ede8023664895bdf496b4c7b21f (patch) | |
tree | 9a55e829cd23a70f0f3e78d0688cb843fffea207 /4.8.1 | |
parent | Remove libgcc-ldflags patch since it doesn't actually work. (diff) | |
download | gcc-patches-0f82b30a245a0ede8023664895bdf496b4c7b21f.tar.gz gcc-patches-0f82b30a245a0ede8023664895bdf496b4c7b21f.tar.bz2 gcc-patches-0f82b30a245a0ede8023664895bdf496b4c7b21f.zip |
Add -march=native support for Ivy Bridge and Haswell.
Diffstat (limited to '4.8.1')
-rw-r--r-- | 4.8.1/gentoo/97_all_native-ivybridge-haswell.patch | 90 | ||||
-rw-r--r-- | 4.8.1/gentoo/README.history | 1 |
2 files changed, 91 insertions, 0 deletions
diff --git a/4.8.1/gentoo/97_all_native-ivybridge-haswell.patch b/4.8.1/gentoo/97_all_native-ivybridge-haswell.patch new file mode 100644 index 0000000..ff45e23 --- /dev/null +++ b/4.8.1/gentoo/97_all_native-ivybridge-haswell.patch @@ -0,0 +1,90 @@ +Backport -march=native support for Ivy Bridge (core-avx-i) and Haswell +(core-avx2). + +http://gcc.gnu.org/PR57927 + + +commit 78a5e928bc94e1ef35dc15853a609863bd10b327 +Author: uros <uros@138bc75d-0d04-0410-961f-82ee72b054a4> +Date: Wed Aug 28 08:25:13 2013 +0000 + + Backport from mainline + 2013-08-27 H.J. Lu <hongjiu.lu@intel.com> + + * config/i386/driver-i386.c (host_detect_local_cpu): Update + Haswell processor detection. + + Backport from mainline + 2013-08-27 Christian Widmer <shadow@umbrox.de> + + PR target/57927 + * config/i386/driver-i386.c (host_detect_local_cpu): Add detection + of Ivy Bridge and Haswell processors. Assume core-avx2 for unknown + AVX2 capable processors. + + + + git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_8-branch@202045 138bc75d-0d04-0410-961f-82ee72b054a4 +--- + gcc/ChangeLog | 20 ++++++++++++++++++-- + gcc/config/i386/driver-i386.c | 30 ++++++++++++++++++++---------- + 2 files changed, 38 insertions(+), 12 deletions(-) + + +--- a/gcc/config/i386/driver-i386.c ++++ b/gcc/config/i386/driver-i386.c +@@ -638,13 +638,18 @@ const char *host_detect_local_cpu (int argc, const char **argv) + /* 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: +@@ -656,20 +661,25 @@ const char *host_detect_local_cpu (int argc, const char **argv) + /* 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: ++ case 0x45: ++ case 0x46: ++ /* 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) diff --git a/4.8.1/gentoo/README.history b/4.8.1/gentoo/README.history index 95547da..44cc3a2 100644 --- a/4.8.1/gentoo/README.history +++ b/4.8.1/gentoo/README.history @@ -1,5 +1,6 @@ 1.2 (pending) - 20_all_libgcc-ldflags.patch + + 97_all_native-ivybridge-haswell.patch 1.1 26 Aug 2013 + 17_all_libitm-Werror.patch |