diff options
author | meissner <meissner@138bc75d-0d04-0410-961f-82ee72b054a4> | 2017-01-26 04:16:11 +0000 |
---|---|---|
committer | meissner <meissner@138bc75d-0d04-0410-961f-82ee72b054a4> | 2017-01-26 04:16:11 +0000 |
commit | 2c68ae9f6e10bf3c5e3031740d7827d31e44908c (patch) | |
tree | 67f22883ea37ccfae6a0be003804a504a0ef3599 /gcc | |
parent | 2f77c4487b015a931e70a5ee43453d3e98bbe8ce (diff) | |
download | gcc-2c68ae9f6e10bf3c5e3031740d7827d31e44908c.tar.gz |
[gcc]
2017-01-25 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/79179
* config/rs6000/vsx.md (vsx_extract_<mode>_store): Use wY
constraint instead of o for the stxsd instruction.
[gcc/testsuite]
2017-01-25 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/79179
* gcc.target/powerpc/pr79179.c: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244917 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/config/rs6000/vsx.md | 2 | ||||
-rw-r--r-- | gcc/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/testsuite/gcc.target/powerpc/pr79179.c | 23 |
4 files changed, 35 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4712d7c40d9..a068478407a 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2017-01-25 Michael Meissner <meissner@linux.vnet.ibm.com> + + PR target/79179 + * config/rs6000/vsx.md (vsx_extract_<mode>_store): Use wY + constraint instead of o for the stxsd instruction. + 2017-01-25 Carl Love <cel@us.ibm.com> * config/rs6000/rs6000-c (altivec_overloaded_builtins): Fix order diff --git a/gcc/config/rs6000/vsx.md b/gcc/config/rs6000/vsx.md index 28bbeb2a7d9..b10ade40db6 100644 --- a/gcc/config/rs6000/vsx.md +++ b/gcc/config/rs6000/vsx.md @@ -2323,7 +2323,7 @@ ;; Optimize storing a single scalar element that is the right location to ;; memory (define_insn "*vsx_extract_<mode>_store" - [(set (match_operand:<VS_scalar> 0 "memory_operand" "=m,Z,o") + [(set (match_operand:<VS_scalar> 0 "memory_operand" "=m,Z,wY") (vec_select:<VS_scalar> (match_operand:VSX_D 1 "register_operand" "d,wv,wb") (parallel [(match_operand:QI 2 "vsx_scalar_64bit" "wD,wD,wD")])))] diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 99bec45d5a7..1cce5212987 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2017-01-25 Michael Meissner <meissner@linux.vnet.ibm.com> + + PR target/79179 + * gcc.target/powerpc/pr79179.c: New test. + 2017-01-25 Bill Schmidt <wschmidt@linux.vnet.ibm.com> * gcc.target/powerpc/vsx-elemrev-4.c: Change expected code diff --git a/gcc/testsuite/gcc.target/powerpc/pr79179.c b/gcc/testsuite/gcc.target/powerpc/pr79179.c new file mode 100644 index 00000000000..0815a2e38b6 --- /dev/null +++ b/gcc/testsuite/gcc.target/powerpc/pr79179.c @@ -0,0 +1,23 @@ +/* { dg-do assemble { target { powerpc*-*-* && lp64 } } } */ +/* { dg-skip-if "do not override -mcpu" { powerpc*-*-* } { "-mcpu=*" } { "-mcpu=power9" } } */ +/* { dg-require-effective-target powerpc_p9vector_ok } */ +/* { dg-options "-mcpu=power9 -O3" } */ + +/* Compile with -O3 -mcpu=power9. It originally generated + + stxsd 12,1(9) + + which is illegal. */ + +#pragma pack(1) +struct { + signed : 1; + unsigned long a; +} b; + +void c(void) +{ + b.a = 0; + for (; b.a <= 45; b.a = (long)b.a + 1) + ; +} |