diff options
| author | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-03-10 23:01:59 +0000 |
|---|---|---|
| committer | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-03-10 23:01:59 +0000 |
| commit | cbaab9a304e62d2931cc110d2f95c533dec912ce (patch) | |
| tree | d0b4332250c090c621b3e27d56fe20bf0b378c4e | |
| parent | 49eb929e669de7871298ef220f167f1fbcbe4ca9 (diff) | |
| download | ppe42-gcc-cbaab9a304e62d2931cc110d2f95c533dec912ce.tar.gz ppe42-gcc-cbaab9a304e62d2931cc110d2f95c533dec912ce.zip | |
* sched-rgn.c (add_branch_dependences): Don't allow insns that throw
to move away from the end of the block.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@50548 138bc75d-0d04-0410-961f-82ee72b054a4
| -rw-r--r-- | gcc/ChangeLog | 5 | ||||
| -rw-r--r-- | gcc/sched-rgn.c | 9 |
2 files changed, 10 insertions, 4 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 6d98f862c77..26ee5030c22 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2002-03-10 Richard Henderson <rth@redhat.com> + + * sched-rgn.c (add_branch_dependences): Don't allow insns that throw + to move away from the end of the block. + 2002-03-10 Neil Booth <neil@daikokuya.demon.co.uk> PR preprocessor/5899 diff --git a/gcc/sched-rgn.c b/gcc/sched-rgn.c index e5a241b6327..20c8d72f77b 100644 --- a/gcc/sched-rgn.c +++ b/gcc/sched-rgn.c @@ -2277,10 +2277,10 @@ add_branch_dependences (head, tail) { rtx insn, last; - /* For all branches, calls, uses, clobbers, and cc0 setters, force them - to remain in order at the end of the block by adding dependencies and - giving the last a high priority. There may be notes present, and - prev_head may also be a note. + /* For all branches, calls, uses, clobbers, cc0 setters, and instructions + that can throw exceptions, force them to remain in order at the end of + the block by adding dependencies and giving the last a high priority. + There may be notes present, and prev_head may also be a note. Branches must obviously remain at the end. Calls should remain at the end since moving them results in worse register allocation. Uses remain @@ -2293,6 +2293,7 @@ add_branch_dependences (head, tail) || (GET_CODE (insn) == INSN && (GET_CODE (PATTERN (insn)) == USE || GET_CODE (PATTERN (insn)) == CLOBBER + || can_throw_internal (insn) #ifdef HAVE_cc0 || sets_cc0_p (PATTERN (insn)) #endif |

