diff options
author | Alexandre Oliva <aoliva@redhat.com> | 2005-04-16 21:42:26 +0000 |
---|---|---|
committer | Alexandre Oliva <aoliva@gcc.gnu.org> | 2005-04-16 21:42:26 +0000 |
commit | 92750a3929a3974cd0d4baa6c2da3258a2d43b2b (patch) | |
tree | c27abe6e884efe6fc4512ac1e821f186a8dec173 /gcc/loop.c | |
parent | 29836d07d5175c17b66ded6083283117b26f13a7 (diff) | |
download | gcc-92750a3929a3974cd0d4baa6c2da3258a2d43b2b.zip gcc-92750a3929a3974cd0d4baa6c2da3258a2d43b2b.tar.gz gcc-92750a3929a3974cd0d4baa6c2da3258a2d43b2b.tar.bz2 |
re PR target/20126 (Inlined memcmp makes one argument null on entry)
PR target/20126
* loop.c (loop_givs_rescan): Handle non-replaceable (plus (reg)
(const)).
From-SVN: r98238
Diffstat (limited to 'gcc/loop.c')
-rw-r--r-- | gcc/loop.c | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -5488,6 +5488,15 @@ loop_givs_rescan (struct loop *loop, struct iv_class *bl, rtx *reg_map) loop_insn_emit_before (loop, 0, v->insn, gen_move_insn (*v->location, v->new_reg)); + else if (GET_CODE (*v->location) == PLUS + && REG_P (XEXP (*v->location, 0)) + && CONSTANT_P (XEXP (*v->location, 1))) + loop_insn_emit_before (loop, 0, v->insn, + gen_move_insn (XEXP (*v->location, 0), + gen_rtx_MINUS + (GET_MODE (*v->location), + v->new_reg, + XEXP (*v->location, 1)))); else { /* If it wasn't a reg, create a pseudo and use that. */ |