ifcvt.c (noce_process_if_block): Make a copy of the destination when copying back...
authorRichard Sandiford <rsandifo@redhat.com>
Thu, 31 Jan 2002 11:07:14 +0000 (11:07 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Thu, 31 Jan 2002 11:07:14 +0000 (11:07 +0000)
* ifcvt.c (noce_process_if_block): Make a copy of the destination
when copying back from a temporary.

From-SVN: r49369

gcc/ChangeLog
gcc/ifcvt.c

index bfc1972bfeab6c85640a06417ec8436ff2d06fa4..410e1b028be7359d03d443b480a7e95f2bf24f9c 100644 (file)
@@ -1,3 +1,8 @@
+2002-01-31  Richard Sandiford  <rsandifo@redhat.com>
+
+       * ifcvt.c (noce_process_if_block): Make a copy of the destination
+       when copying back from a temporary.
+
 2002-01-30  Richard Henderson  <rth@redhat.com>
 
        * ifcvt.c (dead_or_predicable): Handling merging when other_bb
index 5a9a85438f5366651058e2e12fc1159b0b768e80..a7860e3ea4e51c3c094bb8d1e01ffe1c25148132 100644 (file)
@@ -1792,7 +1792,7 @@ noce_process_if_block (test_bb, then_bb, else_bb, join_bb)
   if (orig_x != x)
     {
       start_sequence ();
-      noce_emit_move_insn (orig_x, x);
+      noce_emit_move_insn (copy_rtx (orig_x), x);
       insn_b = gen_sequence ();
       end_sequence ();