diff options
author | Andrew Haley <aph@cygnus.com> | 1999-11-22 14:53:20 +0000 |
---|---|---|
committer | Andrew Haley <aph@gcc.gnu.org> | 1999-11-22 14:53:20 +0000 |
commit | ee265800a59c05c2a8b90789a3b8b0da41048cb5 (patch) | |
tree | 1aef890d421b309c06309caea7931fda8a0d45c8 /gcc | |
parent | 6c85df69493ee39a1d611150f00982e1f546491b (diff) | |
download | gcc-ee265800a59c05c2a8b90789a3b8b0da41048cb5.zip gcc-ee265800a59c05c2a8b90789a3b8b0da41048cb5.tar.gz gcc-ee265800a59c05c2a8b90789a3b8b0da41048cb5.tar.bz2 |
emit-rtl.c (gen_sequence): Only return the pattern of an insn if its code is INSN and it has no notes.
Fri Nov 12 14:08:40 1999 Andrew Haley <aph@cygnus.com>
* emit-rtl.c (gen_sequence): Only return the pattern of an insn if
its code is INSN and it has no notes.
From-SVN: r30612
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/emit-rtl.c | 14 |
2 files changed, 12 insertions, 7 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 6cec51c..abec23f 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +Fri Nov 12 14:08:40 1999 Andrew Haley <aph@cygnus.com> + + * emit-rtl.c (gen_sequence): Only return the pattern of an insn if + its code is INSN and it has no notes. + 1999-11-22 Andrew Haley <aph@cygnus.com> * varasm.c (function_defined): Remove. diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c index 16fe0bc..3b485d0 100644 --- a/gcc/emit-rtl.c +++ b/gcc/emit-rtl.c @@ -3393,16 +3393,16 @@ gen_sequence () for (tem = first_insn; tem; tem = NEXT_INSN (tem)) len++; - /* If only one insn, return its pattern rather than a SEQUENCE. + /* If only one insn, return it rather than a SEQUENCE. (Now that we cache SEQUENCE expressions, it isn't worth special-casing - the case of an empty list.) */ + the case of an empty list.) + We only return the pattern of an insn if its code is INSN and it + has no notes. This ensures that no information gets lost. */ if (len == 1 && ! RTX_FRAME_RELATED_P (first_insn) - && (GET_CODE (first_insn) == INSN - || GET_CODE (first_insn) == JUMP_INSN - /* Don't discard the call usage field. */ - || (GET_CODE (first_insn) == CALL_INSN - && CALL_INSN_FUNCTION_USAGE (first_insn) == NULL_RTX))) + && GET_CODE (first_insn) == INSN + /* Don't throw away any reg notes. */ + && REG_NOTES (first_insn) == 0) { if (!ggc_p) { |