]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
recog.c (split_insn): Copy the original SET_SRC before using it as a note.
authorRichard Sandiford <rdsandiford@googlemail.com>
Thu, 2 Aug 2012 20:44:38 +0000 (20:44 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Thu, 2 Aug 2012 20:44:38 +0000 (20:44 +0000)
gcc/
* recog.c (split_insn): Copy the original SET_SRC before using
it as a note.

From-SVN: r190102

gcc/ChangeLog
gcc/recog.c

index edecc9728f521fdd5853465a3791b3e2e8b7326a..524ae209da8f867a4d70ea0748fdbcc9bda79419 100644 (file)
@@ -1,3 +1,8 @@
+2012-08-02  Richard Sandiford  <rdsandiford@googlemail.com>
+
+       * recog.c (split_insn): Copy the original SET_SRC before using
+       it as a note.
+
 2012-08-02  Richard Sandiford  <rdsandiford@googlemail.com>
 
        * reorg.c (dbr_schedule): Delete REG_BR_PRED loop.
index a05e8c608f7cd59c01e7ef0f5bbfaee77e4d4069..d7381abd579a6e2affad83f1aa306719addf9e15 100644 (file)
@@ -2831,7 +2831,8 @@ split_insn (rtx insn)
          if (note && CONSTANT_P (XEXP (note, 0)))
            set_unique_reg_note (last, REG_EQUAL, XEXP (note, 0));
          else if (CONSTANT_P (SET_SRC (insn_set)))
-           set_unique_reg_note (last, REG_EQUAL, SET_SRC (insn_set));
+           set_unique_reg_note (last, REG_EQUAL,
+                                copy_rtx (SET_SRC (insn_set)));
        }
     }