* ifcvt.c (noce_process_if_block): Make a copy of the destination
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 31 Jan 2002 11:07:14 +0000 (11:07 +0000)
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 31 Jan 2002 11:07:14 +0000 (11:07 +0000)
when copying back from a temporary.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@49369 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/ifcvt.c

index bfc1972..410e1b0 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 5a9a854..a7860e3 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 ();