This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/41239] Scheduler reorders division by zero before a call that might not return
- From: "jakub at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 8 Sep 2009 09:26:12 -0000
- Subject: [Bug rtl-optimization/41239] Scheduler reorders division by zero before a call that might not return
- References: <bug-41239-87@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #5 from jakub at gcc dot gnu dot org 2009-09-08 09:26 -------
Subject: Bug 41239
Author: jakub
Date: Tue Sep 8 09:25:47 2009
New Revision: 151500
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=151500
Log:
PR rtl-optimization/41239
* sched-int.h (struct deps): Add last_function_call_may_noreturn field.
* sched-rgn.c (deps_join): Join also last_function_call_may_noreturn
lists.
* sched-deps.c (sched_analyze_insn): Prevent moving trapping insns
across calls, as the calls might not always return normally.
(call_may_noreturn_p): New function.
(deps_analyze_insn): Update last_function_call_may_noreturn list.
(init_deps): Initialize it.
(remove_from_deps): Also remove calls from
last_function_call_may_noreturn list.
* gcc.c-torture/execute/pr41239.c: New test.
Added:
trunk/gcc/testsuite/gcc.c-torture/execute/pr41239.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/sched-deps.c
trunk/gcc/sched-int.h
trunk/gcc/sched-rgn.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41239