diff options
author | Aaron Sawdey <acsawdey@linux.vnet.ibm.com> | 2017-03-01 19:58:05 +0000 |
---|---|---|
committer | Aaron Sawdey <acsawdey@gcc.gnu.org> | 2017-03-01 13:58:05 -0600 |
commit | af15f9938b40bd59c891c75436590157385d0013 (patch) | |
tree | 734b3f1f8788c7d385470b73b72a64029b6a3462 | |
parent | 489909059b8c7dfa3b379be229e7cb1feab9675d (diff) | |
download | gcc-af15f9938b40bd59c891c75436590157385d0013.zip gcc-af15f9938b40bd59c891c75436590157385d0013.tar.gz gcc-af15f9938b40bd59c891c75436590157385d0013.tar.bz2 |
re PR target/79752 (incorrect code generation for __divkf3 with -O2 -mcpu=power9)
2017-03-01 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
PR target/79752
* config/rs6000/rs6000.md (peephole2 for udiv/umod): Should emit
udiv rather than div since input pattern is unsigned.
From-SVN: r245817
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/config/rs6000/rs6000.md | 4 |
2 files changed, 8 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d791c18..f2fb7ff 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2017-03-01 Aaron Sawdey <acsawdey@linux.vnet.ibm.com> + + PR target/79752 + * config/rs6000/rs6000.md (peephole2 for udiv/umod): Should emit + udiv rather than div since input pattern is unsigned. + 2017-03-01 Uros Bizjak <ubizjak@gmail.com> * config/i386/i386.c (print_reg): Warn for values of diff --git a/gcc/config/rs6000/rs6000.md b/gcc/config/rs6000/rs6000.md index 06c0a8b..466075a 100644 --- a/gcc/config/rs6000/rs6000.md +++ b/gcc/config/rs6000/rs6000.md @@ -3161,8 +3161,8 @@ && ! reg_mentioned_p (operands[3], operands[1]) && ! reg_mentioned_p (operands[3], operands[2])" [(set (match_dup 0) - (div:GPR (match_dup 1) - (match_dup 2))) + (udiv:GPR (match_dup 1) + (match_dup 2))) (set (match_dup 3) (mult:GPR (match_dup 0) (match_dup 2))) |