diff options
author | Richard Kenner <kenner@gcc.gnu.org> | 1997-05-18 08:39:57 -0400 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 1997-05-18 08:39:57 -0400 |
commit | 2ae3dcac7b4c2901bda0ff9b4fc6768309c35f42 (patch) | |
tree | a56f12fa3f6d73aaee5dcaf590d3ac4bbe1c3a44 /gcc | |
parent | 1f75ca0de2c87b3d0fe1e019ed678f8b3a147114 (diff) | |
download | gcc-2ae3dcac7b4c2901bda0ff9b4fc6768309c35f42.zip gcc-2ae3dcac7b4c2901bda0ff9b4fc6768309c35f42.tar.gz gcc-2ae3dcac7b4c2901bda0ff9b4fc6768309c35f42.tar.bz2 |
(maybe_eliminate_biv_1): In (set (cc0) <biv>) case, swap compare
operands when mult_val < 0 in one additional place.
From-SVN: r14087
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/loop.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -6343,9 +6343,10 @@ maybe_eliminate_biv_1 (x, insn, bl, eliminate_p, where) emit_insn_before (gen_move_insn (tem, copy_rtx (v->add_val)), where); - if (validate_change (insn, &SET_SRC (PATTERN (insn)), - gen_rtx (COMPARE, VOIDmode, - v->new_reg, tem), 0)) + /* Substitute the new register for its invariant value in + the compare expression. */ + XEXP (new, (INTVAL (v->mult_val) < 0) ? 0 : 1) = tem; + if (validate_change (insn, &SET_SRC (PATTERN (insn)), new, 0)) return 1; } } |