diff options
author | Xinliang David Li <davidxl@google.com> | 2008-06-04 21:49:45 +0000 |
---|---|---|
committer | Xinliang David Li <davidxl@gcc.gnu.org> | 2008-06-04 21:49:45 +0000 |
commit | c2699190282c19bd5703de0a606b842774715074 (patch) | |
tree | e298fb5d3a5ce2f2f94d42716feeeb493ca9e188 /gcc/doc | |
parent | 7db5da56edab33b9dc4ab1991ad06d023c9516b1 (diff) | |
download | gcc-c2699190282c19bd5703de0a606b842774715074.zip gcc-c2699190282c19bd5703de0a606b842774715074.tar.gz gcc-c2699190282c19bd5703de0a606b842774715074.tar.bz2 |
tree-call-cdce.c: New file.
2008-06-04 Xinliang David Li <davidxl@google.com>
* tree-call-cdce.c: New file.
(cond_dead_built_in_calls): New static variable.
(input_domain): New struct.
(check_pow): New function.
(check_builtin_call): Ditto.
(check_target_format): Ditto.
(is_call_dce_candidate): Ditto.
(gen_one_condition): Ditto.
(gen_conditions_for_domain): Ditto.
(get_domain): Ditto.
(gen_conditions_for_pow_cst_base): Ditto.
(gen_conditions_for_pow_int_base): Ditto.
(gen_conditions_for_pow): Ditto.
(get_no_error_domain): Ditto.
(gen_shrink_wrap_conditions): Ditto.
(shrink_wrap_one_built_in_call): Ditto.
(shink_wrap_conditional_dead_built_in_calls): Ditto.
(tree_call_cdce): Ditto.
(gate_call_cdce): Ditto.
(pass_call_cdce): New gimple pass.
* passes.c: (init_optimization_passes): New pass.
* tree-pass.h: New pass declaration.
* opts.c (decode_options): New flag setting.
* common.opt: Add -ftree-builtin-call-dce flag.
* Makefile.in: Add new source file.
* tempvar.def: New tv_id.
* doc/invoke.texi (-ftree-builtin-call-dce): New flag.
2008-06-04 Xinliang David Li <davidxl@google.com>
* gcc.dg/cdce1.c: New test.
* gcc.dg/cdce2.c: Ditto.
* g++.dg/cdce3.C: Ditto.
From-SVN: r136374
Diffstat (limited to 'gcc/doc')
-rw-r--r-- | gcc/doc/invoke.texi | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index ece9d9d..0b5ad59 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -352,8 +352,9 @@ Objective-C and Objective-C++ Dialects}. -fschedule-insns -fschedule-insns2 -fsection-anchors -fsee @gol -fsignaling-nans -fsingle-precision-constant -fsplit-ivs-in-unroller @gol -fsplit-wide-types -fstack-protector -fstack-protector-all @gol --fstrict-aliasing -fstrict-overflow -fthread-jumps -ftracer -ftree-ccp @gol --ftree-ch -ftree-copy-prop -ftree-copyrename -ftree-dce @gol +-fstrict-aliasing -fstrict-overflow -fthread-jumps -ftracer @gol +-ftree-builtin-call-dce -ftree-ccp -ftree-ch -ftree-copy-prop @gol +-ftree-copyrename -ftree-dce @gol -ftree-dominator-opts -ftree-dse -ftree-fre -ftree-loop-im @gol -ftree-loop-distribution @gol -ftree-loop-ivcanon -ftree-loop-linear -ftree-loop-optimize @gol @@ -5154,6 +5155,7 @@ compilation time. -fipa-reference @gol -fmerge-constants -fsplit-wide-types @gol +-ftree-builtin-call-dce @gol -ftree-ccp @gol -ftree-ch @gol -ftree-copyrename @gol @@ -5874,6 +5876,13 @@ enabled by default at @option{-O2} and higher. Perform dead code elimination (DCE) on trees. This flag is enabled by default at @option{-O} and higher. +@item -ftree-builtin-call-dce +@opindex ftree-builtin-call-dce +Perform conditional dead code elimination (DCE) for calls to builtin functions +that may set @code{errno} but are otherwise side-effect free. This flag is +enabled by default at @option{-O2} and higher if @option{-Os} is not also +specified. + @item -ftree-dominator-opts @opindex ftree-dominator-opts Perform a variety of simple scalar cleanups (constant/copy |