diff options
author | Alan Modra <amodra@bigpond.net.au> | 2005-12-02 06:15:54 +0000 |
---|---|---|
committer | Alan Modra <amodra@gcc.gnu.org> | 2005-12-02 16:45:54 +1030 |
commit | 815eb8f0ca3d0b677b5694781ac9b2809e39cd08 (patch) | |
tree | 730ebd016476c654c4418b56a23dac1460fc7f74 /gcc | |
parent | 87f2a9f57bfc1a95934202110badb4d1a31409ed (diff) | |
download | gcc-815eb8f0ca3d0b677b5694781ac9b2809e39cd08.zip gcc-815eb8f0ca3d0b677b5694781ac9b2809e39cd08.tar.gz gcc-815eb8f0ca3d0b677b5694781ac9b2809e39cd08.tar.bz2 |
re PR middle-end/25176 ([4.0 only] FAIL: Array_3 -O3 execution - bytecode->native test)
PR middle-end/25176
* function.c (expand_function_end): Emit blockage for unwinder
after return label.
From-SVN: r107871
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/function.c | 29 |
2 files changed, 23 insertions, 12 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a3c113a..d33807b3 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2005-12-02 Alan Modra <amodra@bigpond.net.au> + + PR middle-end/25176 + * function.c (expand_function_end): Emit blockage for unwinder + after return label. + 2005-12-01 Roger Sayle <roger@eyesopen.com> * tree.h (TREE_OVERFLOW): Make this flag/predicate specific to diff --git a/gcc/function.c b/gcc/function.c index c0339b8..ff80df7 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -4334,14 +4334,6 @@ expand_function_end (void) clear_pending_stack_adjust (); do_pending_stack_adjust (); - /* @@@ This is a kludge. We want to ensure that instructions that - may trap are not moved into the epilogue by scheduling, because - we don't always emit unwind information for the epilogue. - However, not all machine descriptions define a blockage insn, so - emit an ASM_INPUT to act as one. */ - if (flag_non_call_exceptions) - emit_insn (gen_rtx_ASM_INPUT (VOIDmode, "")); - /* Mark the end of the function body. If control reaches this insn, the function can drop through without returning a value. */ @@ -4373,10 +4365,23 @@ expand_function_end (void) /* Output the label for the actual return from the function. */ emit_label (return_label); - /* Let except.c know where it should emit the call to unregister - the function context for sjlj exceptions. */ - if (flag_exceptions && USING_SJLJ_EXCEPTIONS) - sjlj_emit_function_exit_after (get_last_insn ()); + if (USING_SJLJ_EXCEPTIONS) + { + /* Let except.c know where it should emit the call to unregister + the function context for sjlj exceptions. */ + if (flag_exceptions) + sjlj_emit_function_exit_after (get_last_insn ()); + } + else + { + /* @@@ This is a kludge. We want to ensure that instructions that + may trap are not moved into the epilogue by scheduling, because + we don't always emit unwind information for the epilogue. + However, not all machine descriptions define a blockage insn, so + emit an ASM_INPUT to act as one. */ + if (flag_non_call_exceptions) + emit_insn (gen_rtx_ASM_INPUT (VOIDmode, "")); + } /* If this is an implementation of throw, do what's necessary to communicate between __builtin_eh_return and the epilogue. */ |