aboutsummaryrefslogtreecommitdiff
path: root/gcc/config/rs6000/rs6000.md
diff options
context:
space:
mode:
authorSegher Boessenkool <segher@kernel.crashing.org>2016-07-07 05:09:03 +0200
committerSegher Boessenkool <segher@gcc.gnu.org>2016-07-07 05:09:03 +0200
commit5ddaee94e247a189a8a17af7dce8d45e0c30adee (patch)
tree2de57a6ecd444e6768a4028bf841dbcf613dfea2 /gcc/config/rs6000/rs6000.md
parent242fab3667f3c694204509a2d4c586954a858b93 (diff)
downloadgcc-5ddaee94e247a189a8a17af7dce8d45e0c30adee.zip
gcc-5ddaee94e247a189a8a17af7dce8d45e0c30adee.tar.gz
gcc-5ddaee94e247a189a8a17af7dce8d45e0c30adee.tar.bz2
rs6000: Make the ctr* patterns allow ints in vector regs (PR71763)
Similar to PR70098, which is about integers in floating point registers, we can have the completely analogous problem with vector registers as well now that we allow integers in vector registers. So, this patch solves it in the same way. This only works for targets with direct move. To recap: register allocation can decide to put an integer mode value in a floating point or vector register. If that register is used in a bd*z instruction, which is a jump instruction, reload can not do an output reload on it (it does not do output reloads on any jump insns), so the float or vector register will remain, and we have to allow it here or recog will ICE. Later on we will split this to valid instructions, including a move from that fp/vec register to an int register; it is this move that will still fail (PR70098) if we do not have direct move enabled. PR target/70098 PR target/71763 * config/rs6000/rs6000.md (*ctr<mode>_internal1, *ctr<mode>_internal2, *ctr<mode>_internal5, *ctr<mode>_internal6): Add *wi to the output constraint. gcc/testsuite/ PR target/70098 PR target/71763 * gcc.target/powerpc/pr71763.c: New file. From-SVN: r238076
Diffstat (limited to 'gcc/config/rs6000/rs6000.md')
-rw-r--r--gcc/config/rs6000/rs6000.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/gcc/config/rs6000/rs6000.md b/gcc/config/rs6000/rs6000.md
index 46f7382..7d9c660 100644
--- a/gcc/config/rs6000/rs6000.md
+++ b/gcc/config/rs6000/rs6000.md
@@ -12202,7 +12202,7 @@
(const_int 1))
(label_ref (match_operand 0 "" ""))
(pc)))
- (set (match_operand:P 2 "nonimmediate_operand" "=1,*r,m,*d*c*l")
+ (set (match_operand:P 2 "nonimmediate_operand" "=1,*r,m,*d*wi*c*l")
(plus:P (match_dup 1)
(const_int -1)))
(clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
@@ -12226,7 +12226,7 @@
(const_int 1))
(pc)
(label_ref (match_operand 0 "" ""))))
- (set (match_operand:P 2 "nonimmediate_operand" "=1,*r,m,*d*c*l")
+ (set (match_operand:P 2 "nonimmediate_operand" "=1,*r,m,*d*wi*c*l")
(plus:P (match_dup 1)
(const_int -1)))
(clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
@@ -12252,7 +12252,7 @@
(const_int 1))
(label_ref (match_operand 0 "" ""))
(pc)))
- (set (match_operand:P 2 "nonimmediate_operand" "=1,*r,m,*d*c*l")
+ (set (match_operand:P 2 "nonimmediate_operand" "=1,*r,m,*d*wi*c*l")
(plus:P (match_dup 1)
(const_int -1)))
(clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
@@ -12276,7 +12276,7 @@
(const_int 1))
(pc)
(label_ref (match_operand 0 "" ""))))
- (set (match_operand:P 2 "nonimmediate_operand" "=1,*r,m,*d*c*l")
+ (set (match_operand:P 2 "nonimmediate_operand" "=1,*r,m,*d*wi*c*l")
(plus:P (match_dup 1)
(const_int -1)))
(clobber (match_scratch:CC 3 "=X,&x,&x,&x"))