diff options
author | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 2000-06-13 16:06:26 +0000 |
---|---|---|
committer | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 2000-06-13 16:06:26 +0000 |
commit | 07c6fb8736fc84b5978f0111447afbd7caf478df (patch) | |
tree | 92faf5042f2368cd34d4381090cd55578905517c | |
parent | 358104ac5711cc5ee1b453355bfcf335c2278048 (diff) | |
download | ppe42-gcc-07c6fb8736fc84b5978f0111447afbd7caf478df.tar.gz ppe42-gcc-07c6fb8736fc84b5978f0111447afbd7caf478df.zip |
* final.c (final_scan_insn): Delete notes between cc0 setter and
user when restarting from setter.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34517 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/final.c | 20 |
2 files changed, 24 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 998fd5dbcd2..9ae4e515626 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +Tue Jun 13 10:05:30 2000 Hans-Peter Nilsson <hp@axis.com> + + * final.c (final_scan_insn): Delete notes between cc0 setter and + user when restarting from setter. + 2000-06-13 J. David Anglin <dave@hiauly1.hia.nrc.ca> * vax.h (INDEX_TERM_P): Define evaluation order of &&'s in || and diff --git a/gcc/final.c b/gcc/final.c index ae0e9cbd0fe..35782db678d 100644 --- a/gcc/final.c +++ b/gcc/final.c @@ -2943,10 +2943,28 @@ final_scan_insn (insn, file, optimize, prescan, nopeepholes) needs to be reinserted. */ if (template == 0) { + rtx prev; + if (prev_nonnote_insn (insn) != last_ignored_compare) abort (); new_block = 0; - return prev_nonnote_insn (insn); + + /* We have already processed the notes between the setter and + the user. Make sure we don't process them again, this is + particularly important if one of the notes is a block + scope note or an EH note. */ + for (prev = insn; + prev != last_ignored_compare; + prev = PREV_INSN (prev)) + { + if (GET_CODE (prev) == NOTE) + { + NOTE_LINE_NUMBER (prev) = NOTE_INSN_DELETED; + NOTE_SOURCE_FILE (prev) = 0; + } + } + + return prev; } /* If the template is the string "#", it means that this insn must |