diff options
author | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1997-09-04 15:54:24 +0000 |
---|---|---|
committer | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1997-09-04 15:54:24 +0000 |
commit | 34f8abb95e3dc50cb6960e171ba7053146b0ebc5 (patch) | |
tree | 92df26ce98c35ee9183f6d00a543d937eb685540 | |
parent | 4c13bcbddc06aa09e5aaa4f7a1bd88b2bd1e8a22 (diff) | |
download | gcc-34f8abb95e3dc50cb6960e171ba7053146b0ebc5.tar.gz |
* profile.c (output_arc_profiler): Verify next_insert_after is an
INSN before and after skipping a stack pop.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@15076 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/profile.c | 11 |
2 files changed, 11 insertions, 5 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index f6614c2b48d..81123aace07 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +Thu Sep 4 09:53:20 1997 Jim Wilson (wilson@cygnus.com) + + * profile.c (output_arc_profiler): Verify next_insert_after is an + INSN before and after skipping a stack pop. + Thu Sep 4 07:39:19 1997 J"orn Rennecke <amylaar@cygnus.co.uk> * final.c (shorten_branches): Don't count the lengths of deleted diff --git a/gcc/profile.c b/gcc/profile.c index 0509562f6f6..5360090ee84 100644 --- a/gcc/profile.c +++ b/gcc/profile.c @@ -1536,13 +1536,14 @@ output_arc_profiler (arcno, insert_after) rtx return_reg; rtx next_insert_after = next_nonnote_insn (insert_after); + /* The first insn after the call may be a stack pop, skip it. */ + if (GET_CODE (next_insert_after) == INSN + && GET_CODE (PATTERN (next_insert_after)) == SET + && SET_DEST (PATTERN (next_insert_after)) == stack_pointer_rtx) + next_insert_after = next_nonnote_insn (next_insert_after); + if (GET_CODE (next_insert_after) == INSN) { - /* The first insn after the call may be a stack pop, skip it. */ - if (GET_CODE (PATTERN (next_insert_after)) == SET - && SET_DEST (PATTERN (next_insert_after)) == stack_pointer_rtx) - next_insert_after = next_nonnote_insn (next_insert_after); - if (GET_CODE (PATTERN (insert_after)) == SET) return_reg = SET_DEST (PATTERN (insert_after)); else |