[patch] Fix PR middle-end/53590
Eric Botcazou
ebotcazou@adacore.com
Wed Jun 13 10:29:00 GMT 2012
This PR is about straight-line code not being as much vectorized in Ada as in C
or C++. The problem stems from the very conservative semantics implemented
under -fnon-call-exceptions for the sake of Java. We don't need it in Ada.
Tested on x86_64-suse-linux, OK for the mainline?
2012-06-13 Eric Botcazou <ebotcazou@adacore.com>
PR middle-end/53590
* common.opt (-fdelete-dead-exceptions): New switch.
* doc/invoke.texi (Optimization Options): Document it.
* cse.c (insn_live_p): Do not return true for an insn that could throw
if dead exceptions can be deleted.
* dce.c (can_alter_cfg): New flag.
(deletable_insn_p): Do not return false for an insn that can throw if
the CFG can be altered and dead exceptions can be deleted.
(init_dce): Set can_alter_cfg to false for fast DCE, true otherwise.
* dse.c (scan_insn): Do not preserve an insn that could throw if dead
exceptions can be deleted.
* tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Do not mark a
statement that could throw as necessary if dead exceptions can be
deleted.
ada/
* gcc-interface/misc.c (gnat_init_options_struct): Set
opts->x_flag_delete_dead_exceptions to 1.
--
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr53590.diff
Type: text/x-diff
Size: 5579 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20120613/ae14ee9e/attachment.bin>
More information about the Gcc-patches
mailing list