summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorktkachov <ktkachov@138bc75d-0d04-0410-961f-82ee72b054a4>2015-12-14 11:33:00 +0000
committerktkachov <ktkachov@138bc75d-0d04-0410-961f-82ee72b054a4>2015-12-14 11:33:00 +0000
commit4bc89ef0ff8d1b727dc79e044980fbe9577c1e53 (patch)
tree67a99df131f3aa22aba42eb7b4005cdcdb13ed87
parentf1cf83ef626cfdb8c85316ad7a8a5e4ade87b4f4 (diff)
downloadgcc-4bc89ef0ff8d1b727dc79e044980fbe9577c1e53.tar.gz
[combine] Don't create LSHIFTRT of zero bits in change_zero_ext
* combine.c (change_zero_ext): Do not create a shift of zero length. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@231613 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/combine.c3
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 6d3210f63c8..c79b65c9141 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+2015-12-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
+
+ * combine.c (change_zero_ext): Do not create a shift of zero length.
+
2015-12-14 Claudiu Zissulescu <claziss@synopsys.com>
* config/arc/arc.c (TARGET_NO_SPECULATION_IN_DELAY_SLOTS_P):
diff --git a/gcc/combine.c b/gcc/combine.c
index 71b1656ba33..317a4b0e12a 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -11045,7 +11045,8 @@ change_zero_ext (rtx *src)
if (BITS_BIG_ENDIAN)
start = GET_MODE_PRECISION (mode) - size - start;
- x = gen_rtx_LSHIFTRT (mode, XEXP (x, 0), GEN_INT (start));
+ x = simplify_gen_binary (LSHIFTRT, mode,
+ XEXP (x, 0), GEN_INT (start));
}
else if (GET_CODE (x) == ZERO_EXTEND
&& GET_CODE (XEXP (x, 0)) == SUBREG