diff options
author | Ryan Hill <rhill@gentoo.org> | 2014-05-15 01:06:52 +0000 |
---|---|---|
committer | Ryan Hill <rhill@gentoo.org> | 2014-05-15 01:06:52 +0000 |
commit | 98bda9d5229b0ab37fc3d96a969367ce47c178d1 (patch) | |
tree | bbf89917aee680aebc1abea5d8e05c16d904804f /4.8.2 | |
parent | More backports. (diff) | |
download | gcc-patches-98bda9d5229b0ab37fc3d96a969367ce47c178d1.tar.gz gcc-patches-98bda9d5229b0ab37fc3d96a969367ce47c178d1.tar.bz2 gcc-patches-98bda9d5229b0ab37fc3d96a969367ce47c178d1.zip |
Backport a couple patches.
Diffstat (limited to '4.8.2')
-rw-r--r-- | 4.8.2/gentoo/95_all_pr60960-wrong-code.patch | 78 | ||||
-rw-r--r-- | 4.8.2/gentoo/96_all_pr59952-avx2-no-rtm.patch | 30 | ||||
-rw-r--r-- | 4.8.2/gentoo/README.history | 4 |
3 files changed, 112 insertions, 0 deletions
diff --git a/4.8.2/gentoo/95_all_pr60960-wrong-code.patch b/4.8.2/gentoo/95_all_pr60960-wrong-code.patch new file mode 100644 index 0000000..bc62e1a --- /dev/null +++ b/4.8.2/gentoo/95_all_pr60960-wrong-code.patch @@ -0,0 +1,78 @@ +http://gcc.gnu.org/PR60960 + + +commit d33dfa66ca1928edf3692991143967bf03cb08e6 +Author: jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> +Date: Mon May 5 08:16:43 2014 +0000 + + Backported from mainline + 2014-04-25 Jakub Jelinek <jakub@redhat.com> + + PR tree-optimization/60960 + * tree-vect-generic.c (expand_vector_operation): Only call + expand_vector_divmod if type's mode satisfies VECTOR_MODE_P. + + * gcc.c-torture/execute/pr60960.c: New test. + + + git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_8-branch@210064 138bc75d-0d04-0410-961f-82ee72b054a4 +--- + gcc/ChangeLog | 9 +++++++ + gcc/testsuite/ChangeLog | 8 ++++++ + gcc/testsuite/gcc.c-torture/execute/pr60960.c | 38 +++++++++++++++++++++++++++ + gcc/tree-vect-generic.c | 3 ++- + 4 files changed, 57 insertions(+), 1 deletion(-) + +--- a/gcc/tree-vect-generic.c ++++ b/gcc/tree-vect-generic.c +@@ -1006,7 +1006,8 @@ expand_vector_operation (gimple_stmt_iterator *gsi, tree type, tree compute_type + + if (!optimize + || !VECTOR_INTEGER_TYPE_P (type) +- || TREE_CODE (rhs2) != VECTOR_CST) ++ || TREE_CODE (rhs2) != VECTOR_CST ++ || !VECTOR_MODE_P (TYPE_MODE (type))) + break; + + ret = expand_vector_divmod (gsi, type, rhs1, rhs2, code); +--- /dev/null ++++ b/gcc/testsuite/gcc.c-torture/execute/pr60960.c +@@ -0,0 +1,38 @@ ++/* PR tree-optimization/60960 */ ++ ++typedef unsigned char v4qi __attribute__ ((vector_size (4))); ++ ++__attribute__((noinline, noclone)) v4qi ++f1 (v4qi v) ++{ ++ return v / 2; ++} ++ ++__attribute__((noinline, noclone)) v4qi ++f2 (v4qi v) ++{ ++ return v / (v4qi) { 2, 2, 2, 2 }; ++} ++ ++__attribute__((noinline, noclone)) v4qi ++f3 (v4qi x, v4qi y) ++{ ++ return x / y; ++} ++ ++int ++main () ++{ ++ v4qi x = { 5, 5, 5, 5 }; ++ v4qi y = { 2, 2, 2, 2 }; ++ v4qi z = f1 (x); ++ if (__builtin_memcmp (&y, &z, sizeof (y)) != 0) ++ __builtin_abort (); ++ z = f2 (x); ++ if (__builtin_memcmp (&y, &z, sizeof (y)) != 0) ++ __builtin_abort (); ++ z = f3 (x, y); ++ if (__builtin_memcmp (&y, &z, sizeof (y)) != 0) ++ __builtin_abort (); ++ return 0; ++} diff --git a/4.8.2/gentoo/96_all_pr59952-avx2-no-rtm.patch b/4.8.2/gentoo/96_all_pr59952-avx2-no-rtm.patch new file mode 100644 index 0000000..5679b4c --- /dev/null +++ b/4.8.2/gentoo/96_all_pr59952-avx2-no-rtm.patch @@ -0,0 +1,30 @@ +https://gcc.gnu.org/PR59952 + + +commit a360adbdd6a5c88bbe5aa2ee851516565482dba3 +Author: uros <uros@138bc75d-0d04-0410-961f-82ee72b054a4> +Date: Thu May 8 19:32:34 2014 +0000 + + PR target/59952 + * config/i386/i386.c (ix86_option_override_internal): Remove PTA_RTM + from core-avx2. + + + + git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_8-branch@210237 138bc75d-0d04-0410-961f-82ee72b054a4 +--- + gcc/ChangeLog | 6 ++++++ + gcc/config/i386/i386.c | 2 +- + 2 files changed, 7 insertions(+), 1 deletion(-) + +--- a/gcc/config/i386/i386.c ++++ b/gcc/config/i386/i386.c +@@ -2886,7 +2886,7 @@ ix86_option_override_internal (bool main_args_p) + | PTA_SSSE3 | PTA_SSE4_1 | PTA_SSE4_2 | PTA_AVX | PTA_AVX2 + | PTA_CX16 | PTA_POPCNT | PTA_AES | PTA_PCLMUL | PTA_FSGSBASE + | PTA_RDRND | PTA_F16C | PTA_BMI | PTA_BMI2 | PTA_LZCNT +- | PTA_FMA | PTA_MOVBE | PTA_RTM | PTA_HLE | PTA_FXSR | PTA_XSAVE ++ | PTA_FMA | PTA_MOVBE | PTA_HLE | PTA_FXSR | PTA_XSAVE + | PTA_XSAVEOPT}, + {"atom", PROCESSOR_ATOM, CPU_ATOM, + PTA_64BIT | PTA_MMX | PTA_SSE | PTA_SSE2 | PTA_SSE3 diff --git a/4.8.2/gentoo/README.history b/4.8.2/gentoo/README.history index 031e0b4..07be080 100644 --- a/4.8.2/gentoo/README.history +++ b/4.8.2/gentoo/README.history @@ -1,3 +1,7 @@ +1.5 (pending) + + 95_all_pr60960-wrong-code.patch + + 96_all_pr59952-avx2-no-rtm.patch + 1.4 11 Jan 2014 + 09_all_default-ssp.patch 1.3 03 Jan 2014 |