summaryrefslogtreecommitdiff
path: root/gcc/rtlanal.c
diff options
context:
space:
mode:
authorsteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2007-02-20 22:11:52 +0000
committersteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2007-02-20 22:11:52 +0000
commite4f51d19ea7e0a169e7efbce63cc8c62e71851bb (patch)
treecbbca2e4e5c53d02da8c53c3ab7269794ce135b2 /gcc/rtlanal.c
parent0d51184a2158cf3ab280f491f33cc49b6108d2f4 (diff)
downloadgcc-e4f51d19ea7e0a169e7efbce63cc8c62e71851bb.tar.gz
* rtlanal.c (find_reg_equal_equiv_note): Do not find REG_EQ*
notes on an insn with multiple sets, even if single_set returns non-NULL for that insn. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122177 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/rtlanal.c')
-rw-r--r--gcc/rtlanal.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/gcc/rtlanal.c b/gcc/rtlanal.c
index 2d156638b6d..b23eec4cf9f 100644
--- a/gcc/rtlanal.c
+++ b/gcc/rtlanal.c
@@ -1676,11 +1676,18 @@ find_reg_equal_equiv_note (rtx insn)
if (!INSN_P (insn))
return 0;
+
for (link = REG_NOTES (insn); link; link = XEXP (link, 1))
if (REG_NOTE_KIND (link) == REG_EQUAL
|| REG_NOTE_KIND (link) == REG_EQUIV)
{
- if (single_set (insn) == 0)
+ /* FIXME: We should never have REG_EQUAL/REG_EQUIV notes on
+ insns that have multiple sets. Checking single_set to
+ make sure of this is not the proper check, as explained
+ in the comment in set_unique_reg_note.
+
+ This should be changed into an assert. */
+ if (GET_CODE (PATTERN (insn)) == PARALLEL && multiple_sets (insn))
return 0;
return link;
}