diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-12-03 20:35:08 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-12-03 20:35:08 +0000 |
commit | d0a9f10b71d18d00d772314a89ab9fa0937c876b (patch) | |
tree | b0a37d5c035d1b078e8b2a87a5ebefb755e18305 | |
parent | 4768418427400992b8959d2f40009eb2d685624e (diff) | |
download | gcc-d0a9f10b71d18d00d772314a89ab9fa0937c876b.tar.gz |
PR c/59708
* expmed.c (expand_widening_mult): Return const0_rtx if
coeff is 0.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@218331 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/expmed.c | 3 |
2 files changed, 7 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index eff109f584c..aa2f9589e5f 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,9 @@ 2014-12-03 Jakub Jelinek <jakub@redhat.com> + PR c/59708 + * expmed.c (expand_widening_mult): Return const0_rtx if + coeff is 0. + * doc/gimple.texi (gimple_build_assign_with_ops): Remove. (gimple_build_assign): Document the new overloads. diff --git a/gcc/expmed.c b/gcc/expmed.c index 0304e46ebb3..708f04f11c5 100644 --- a/gcc/expmed.c +++ b/gcc/expmed.c @@ -3289,6 +3289,9 @@ expand_widening_mult (machine_mode mode, rtx op0, rtx op1, rtx target, enum mult_variant variant; struct algorithm algorithm; + if (coeff == 0) + return CONST0_RTX (mode); + /* Special case powers of two. */ if (EXACT_POWER_OF_2_OR_ZERO_P (coeff)) { |