diff options
author | Michael Meissner <meissner@cygnus.com> | 1998-05-13 22:10:04 +0000 |
---|---|---|
committer | Jeff Law <law@gcc.gnu.org> | 1998-05-13 16:10:04 -0600 |
commit | ae78d2768e3228db3964587c9315ade0a15ad71c (patch) | |
tree | 08cdb6865426e5e1729f7094bd42c370a0383818 /gcc/rtlanal.c | |
parent | 82ce5b758e986bc47f21d72fb87de8bf236bdd5b (diff) | |
download | gcc-ae78d2768e3228db3964587c9315ade0a15ad71c.zip gcc-ae78d2768e3228db3964587c9315ade0a15ad71c.tar.gz gcc-ae78d2768e3228db3964587c9315ade0a15ad71c.tar.bz2 |
rtlanal.c (find_reg_note): Ignore notes that are not on on insns of class 'i'.
* rtlanal.c (find_reg_note): Ignore notes that are not on on
insns of class 'i'.
(find_regno_note): Likewise.
Co-Authored-By: Jeffrey A Law <law@cygnus.com>
From-SVN: r19733
Diffstat (limited to 'gcc/rtlanal.c')
-rw-r--r-- | gcc/rtlanal.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/gcc/rtlanal.c b/gcc/rtlanal.c index e2fc66a..b410553 100644 --- a/gcc/rtlanal.c +++ b/gcc/rtlanal.c @@ -1259,6 +1259,10 @@ find_reg_note (insn, kind, datum) { register rtx link; + /* Ignore anything that is not an INSN, JUMP_INSN or CALL_INSN. */ + if (GET_RTX_CLASS (GET_CODE (insn)) != 'i') + return 0; + for (link = REG_NOTES (insn); link; link = XEXP (link, 1)) if (REG_NOTE_KIND (link) == kind && (datum == 0 || datum == XEXP (link, 0))) @@ -1279,6 +1283,10 @@ find_regno_note (insn, kind, regno) { register rtx link; + /* Ignore anything that is not an INSN, JUMP_INSN or CALL_INSN. */ + if (GET_RTX_CLASS (GET_CODE (insn)) != 'i') + return 0; + for (link = REG_NOTES (insn); link; link = XEXP (link, 1)) if (REG_NOTE_KIND (link) == kind /* Verify that it is a register, so that scratch and MEM won't cause a |