summaryrefslogtreecommitdiff
path: root/gcc/common.opt
Commit message (Collapse)AuthorAgeFilesLines
* 2008-06-04 Xinliang David Li <davidxl@google.com>davidxl2008-06-041-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 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. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@136374 138bc75d-0d04-0410-961f-82ee72b054a4
* * omp-low.c (gate_expand_omp_ssa): Remove.aldyh2008-05-231-4/+0
| | | | | | | | | | | (pass_expand_omp_ssa): Remove. (gate_expand_omp): Do not check for flag_openmp_ssa. * common.opt (-fopenmp-ssa): Remove. * passes.c (init_optimization_passes): Remove pass_expand_omp_ssa. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@135786 138bc75d-0d04-0410-961f-82ee72b054a4
* Revert r135493 & r135463davidxl2008-05-201-4/+0
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@135599 138bc75d-0d04-0410-961f-82ee72b054a4
* Check in tree-dce enh to trunkdavidxl2008-05-171-0/+4
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@135463 138bc75d-0d04-0410-961f-82ee72b054a4
* 2008-05-08 Richard Guenther <rguenther@suse.de>rguenth2008-05-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/invoke.texi (-fdump-tree-salias): Remove documentation. (-ftree-salias): Likewise. (salias-max-implicit-fields): Remove param documentation. (salias-max-array-elements): Likewise. * tree-pass.h (pass_create_structure_vars): Remove. * params.h (SALIAS_MAX_IMPLICIT_FIELDS): Remove. (SALIAS_MAX_ARRAY_ELEMENTS): Likewise. * tree-ssa-alias.c (create_structure_vars): Remove. (gate_structure_vars): Likewise. (pass_create_structure_vars): Likewise. (gate_build_alias): Likewise. (pass_build_alias): Adjust to run always and dump the function. * common.opt (ftree-salias): Hide. * passes.c (init_optimization_passes): Remove pass_create_structure_vars, adjust comment. * params.def (PARAM_SALIAS_MAX_IMPLICIT_FIELDS): Remove. (PARAM_SALIAS_MAX_ARRAY_ELEMENTS): Likewise. * opts.c (decode_options): Do not set flag_tree_salias. (common_handle_option): Add OPT_ftree_salias to the backward compatibility section. * gcc.dg/tree-ssa/20040911-1.c: Adjust. * gcc.dg/tree-ssa/20040517-1.c: Likewise. * gcc.dg/tree-ssa/pr26421.c: Likewise. * gcc.dg/tree-ssa/pr23382.c: Likewise. * gcc.dg/tree-ssa/alias-15.c: Likewise. * gcc.dg/tree-ssa/inline_asm-1.c: Likewise. * gcc.dg/tree-ssa/inline_asm-2.c: Likewise. * gcc.dg/tree-ssa/pta-fp.c: Likewise. * gcc.dg/tree-ssa/20031015-1.c: Likewise. * gcc.dg/tree-ssa/alias-12.c: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@135111 138bc75d-0d04-0410-961f-82ee72b054a4
* 2008-05-08 Seongbae Park <seongbae.park@gmail.com>spark2008-05-081-8/+1
| | | | | | | | | | * common.opt (Wframe-larger-than=): Shorten the help message to one line. * doc/invoke.texi (Wframe-larger-than=): Add more description. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@135097 138bc75d-0d04-0410-961f-82ee72b054a4
* * common.opt (ftree-loop-distribution): Add Optimizationnickc2008-04-221-1/+1
| | | | | | | attribute. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@134556 138bc75d-0d04-0410-961f-82ee72b054a4
* gcc/ChangeLog:spark2008-03-311-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-03-31 Seongbae Park <seongbae.park@gmail.com> * common.opt (fprofile-dir=, fprofile-use=, fprofile-generate=): New options (fprofile-use): Add var flag_profile_use * coverage.c (coverage_begin_output): Do not open a gcno file for output only if -ftest-coverage is set. Do not add getpwd() to gcda file path. (build_gcov_info): Check the new flag flag_profile_datafile_relative_path. (coverage_init): Use profile_data_prefix. Read profile counter only if flag_profile_use is set. * opts.c (common_handle_option): New option fprofile-use=, fprofile-dir=, fprofile-generate=. * toplev.c (profile_data_prefix): New variable definition. * toplev.h (profile_data_prefix): New declaration. * doc/invoke.tex (Option Summary, Optimization Options): Add new options. gcc/testsuite/ChangeLog: 2008-03-31 Seongbae Park <seongbae.park@gmail.com> * g++.db/bprob/bprob.exp: Do not check gcno files. Use -fprofile-use for profile use. * gcc.misc-tests/bprob.exp: Ditto. * g++.dg/tree-pro/tree-prof.exp: Do not check gcno files. * gcc.dg/matrix/matrix.exp: Ditto. * gcc.dg/struct/struct-reorg.exp: Ditto. * gcc.dg/tree-prof/tree-prof.exp: Ditto. * gcc.dg/profile-dir-1.c: New test. * gcc.dg/profile-dir-2.c: New test. * gcc.dg/profile-dir-3.c: New test. ChangeLog: 2008-03-31 Seongbae Park <seongbae.park@gmail.com> * Makefile.tpl (.NOTPARALLEL): Serialize stageprofile libiberty. * Makefile.in (.NOTPARALLEL): Regenerate. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@133774 138bc75d-0d04-0410-961f-82ee72b054a4
* * common.opt (Wmudflap): New option.reichelt2008-03-201-0/+4
| | | | | | | | | | | | * tree-mudflap.c (mf_xform_derefs_1): Guard warning by OPT_Wmudflap. (mx_register_decls): Likewise. (mudflap_finish_file): Likewise. * doc/invoke.texi: Document -Wno-mudflap. * testsuite/libmudflap.c/pass63-frag.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@133385 138bc75d-0d04-0410-961f-82ee72b054a4
* * doc/invoke.texi: Document -ftree-loop-distribution.spop2008-02-281-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * tree-loop-distribution.c: New. * tree-pass.h (pass_loop_distribution): New. * graphds.h (struct graph): Add htab_t indices. * timevar.def (TV_TREE_LOOP_DISTRIBUTION): New. * tree-vectorizer.c (rename_variables_in_loop): Extern. (slpeel_tree_duplicate_loop_to_edge_cfg): Init PENDING_STMT to NULL. * tree-vectorizer.h (tree_duplicate_loop_on_edge): Declared. * tree-data-ref.c (debug_data_dependence_relations): New. (dump_data_dependence_relation): Also print data references. (free_data_ref): Extern. (same_access_functions): Moved... (find_vertex_for_stmt): Renamed rdg_vertex_for_stmt. (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component, debug_rdg_component, dump_rdg, debug_rdg, dot_rdg_1, dot_rdg, struct rdg_vertex_info, rdg_vertex_for_stmt): New. (create_rdg_edge_for_ddr, create_rdg_vertices): Cleaned up. (stmts_from_loop): Skip LABEL_EXPR. (hash_stmt_vertex_info, eq_stmt_vertex_info, hash_stmt_vertex_del): New. (build_rdg): Initialize rdg->indices htab. (free_rdg, stores_from_loop, ref_base_address, rdg_defs_used_in_other_loops_p, have_similar_memory_accesses, have_similar_memory_accesses_1, ref_base_address_1, remove_similar_memory_refs): New. * tree-data-ref.h: Depend on tree-chrec.h. (debug_data_dependence_relations, free_data_ref): Declared. (same_access_functions): ... here. (ddr_is_anti_dependent, ddrs_have_anti_deps, ddr_dependence_level): New. (struct rdg_vertex): Add has_mem_write and has_mem_reads. (RDGV_HAS_MEM_WRITE, RDGV_HAS_MEM_READS, RDG_STMT, RDG_MEM_WRITE_STMT, RDG_MEM_READS_STMT): New. (dump_rdg_vertex, debug_rdg_vertex, dump_rdg_component, debug_rdg_component, dump_rdg, debug_rdg, dot_rdg, rdg_vertex_for_stmt): Declared. (struct rdg_edge): Add level. (RDGE_LEVEL): New. (free_rdg, stores_from_loop, remove_similar_memory_refs, rdg_defs_used_in_other_loops_p, have_similar_memory_accesses): Declared. (rdg_has_similar_memory_accesses): New. * tree-vect-analyze.c: Remove unused static decls. * lambda.h (dependence_level): New. * common.opt (ftree-loop-distribution): New. * tree-flow.h (mark_virtual_ops_in_bb, slpeel_tree_duplicate_loop_to_edge_cfg, rename_variables_in_loop): Declared. * Makefile.in (TREE_DATA_REF_H): Depend on tree-chrec.h. (OBJS-common): Add tree-loop-distribution.o. (tree-loop-distribution.o): New rule. * tree-cfg.c (mark_virtual_ops_in_bb): New. (mark_virtual_ops_in_region): Use mark_virtual_ops_in_bb. * passes.c (init_optimization_passes): Schedule pass_loop_distribution. * testsuite/gcc.dg/tree-ssa/ldist-{1..12}.c: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@132745 138bc75d-0d04-0410-961f-82ee72b054a4
* 2008-02-26 Manuel Lopez-Ibanez <manu@gcc.gnu.org>manu2008-02-261-4/+0
| | | | | | | | | | | | | | PR 34351 * doc/invoke.texi (-Wall): Add -Wvolatile-register-var. * c-opts.c (c_common_handle_option): Wall enables Wvolatile-register-var. * common.opt: Move Wvolatile-register-var to... * c.opt: ...here. testsuite/ * gcc.dg/pr34351.c: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@132675 138bc75d-0d04-0410-961f-82ee72b054a4
* 2008-02-26 Manuel Lopez-Ibanez <manu@gcc.gnu.org>manu2008-02-261-1/+4
| | | | | | | | | | | | | | | | * common.opt (Wlarger-than=): New. * doc/invoke.texi (Warning Options): Replace -Wlarger-than- with -Wlarger-than=. * opts.c (common_handle_option): Handle -Wlarger-than=. * optc-gen.awk: Likewise. * opth-gen.awk: Likewise. * stor-layout.c (layout_decl): Use -Wlarger-than= for warning. * tree-optimize.c (tree_rest_of_compilation): Likewise. testsuite/ * gcc.dg/Wlarger-than2.c: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@132674 138bc75d-0d04-0410-961f-82ee72b054a4
* 2008-02-25 Janne Blomqvist <jb@gcc.gnu.org>jb2008-02-251-0/+4
| | | | | | | | | | | PR fortran/29549 * doc/invoke.texi (-fcx-limited-range): Document new option. * toplev.c (process_options): Handle -fcx-fortran-rules. * common.opt: Add documentation for -fcx-fortran-rules. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@132636 138bc75d-0d04-0410-961f-82ee72b054a4
* http://gcc.gnu.org/ml/gcc-patches/2008-02/msg01094.htmldnovillo2008-02-241-0/+4
| | | | | | | | | | | | | | | | | PR 33738 * tree-vrp.c (vrp_evaluate_conditional): With -Wtype-limits, emit a warning when comparing against a constant outside the natural range of OP0's type. * c.opt (Wtype-limits): Move ... * common.opt (Wtype-limits): ... here. testsuite/ChangeLog PR 33738 * g++.dg/warn/pr33738.C: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@132591 138bc75d-0d04-0410-961f-82ee72b054a4
* gcc/ChangeLog:spark2008-02-201-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-02-20 Seongbae Park <seongbae.park@gmail.com> * doc/invoke.texi (Warning Options): Add new option -Wframe-larger-than=. (-Wframe-larger-than): Document. * flags.h (warn_frame_larger_than, frame_larger_than_size): Add declarations for new option variables. * final.c (final_start_function): Check the frame size before emission and issue a Wframe-larger-than warning. * opts.c (warn_frame_larger_than, frame_larger_than_size): Add definitions for new option variables. (common_handle_option): Handle new option OPT_Wframe_larger_than_. * common.opt (Wframe-larger-than=): New option. gcc/testsuite/ChangeLog: 2008-02-20 Seongbae Park <seongbae.park@gmail.com> * gcc.dg/Wframe-larger-than.c: New option test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@132496 138bc75d-0d04-0410-961f-82ee72b054a4
* 2008-01-22 Manuel Lopez-Ibanez <manu@gcc.gnu.org>manu2008-01-221-2/+2
| | | | | | | | | | | | | | | | | | | | | | PR 32102 * doc/invoke.texi (-Wall): -Wall enables -Wstrict-overflow=1. * flags.h (warn_strict_aliasing): Remove. (warn_strict_overflow): Remove. * opts.c (warn_strict_aliasing): Remove. (warn_strict_overflow): Remove. * c-opts.c (c_common_handle_option): -Wall only sets -Wstrict-aliasing or -Wstrict-overflow if they are uninitialized. (c_common_post_options): Give default values to -Wstrict-aliasing and -Wstrict-overflow if they are uninitialized. * common.opt (Wstrict-aliasing): Specify Var and Init. (Wstrict-overflow): Likewise. testsuite/ * gcc.dg/Wstrict-overflow-21.c: New. * g++.dg/warn/Wstrict-aliasing-8.C: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@131720 138bc75d-0d04-0410-961f-82ee72b054a4
* ./:ian2008-01-181-1/+6
| | | | | | | | | | | | | | * common.opt: Add fmerge-debug-strings. * dwarf2out.c (DEBUG_STR_SECTION_FLAGS): Test flag_merge_debug_strings rather than flag_merge_constants. * doc/invoke.texi (Option Summary): Mention -fmerge-debug-strings. (Debugging Options): Document -fmerge-debug-strings. testsuite/: * gcc.dg/debug/dwarf2/var1.c: Add -fno-merge-debug-strings. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@131630 138bc75d-0d04-0410-961f-82ee72b054a4
* PR33713aldyh2007-12-031-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | * doc/invoke.texi: Remove -fforce-addr documentation. * expr.c (emit_move_insn): Remove use of flag_force_addr. (expand_expr_real_1): Same. (do_tablejump): Same. Call memory_address instead of memory_address_noforce. * expr.h (memory_address_noforce): Remove prototype. * explow.c (memory_address): Remove support for flag_force_addr. (validize_mem): Same. (memory_address_noforce): Remove. * common.opt: Add dummy documentation for -fforce-addr. * combine.c (can_combine_p): Remove -fforce-addr comment. * config/cris/cris.h (OPTIMIZATION_OPTIONS): Remove set of flag_force_addr. * config/m68k/m68k.h (PIC_CASE_VECTOR_ADDRESS): Remove comment relating to memory_address_noforce. * testsuite/gcc.c-torture/compile/20050802-1.c: Remove. * testsuite/gcc.c-torture/compile/20011113-1.c: Remove. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@130591 138bc75d-0d04-0410-961f-82ee72b054a4
* PR middle-end/34317jakub2007-12-031-1/+1
| | | | | | | | | * opts.c (common_handle_option): Handle OPT_ftree_store_copy_prop. * common.opt (ftree-store-copy-prop): Use the same help text as for other nop switches. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@130579 138bc75d-0d04-0410-961f-82ee72b054a4
* * common.opt (fshow-column): Default to 0.tromey2007-11-081-2/+2
| | | | | | | * configure: Rebuilt. * configure.ac (--enable-mapped-location): Default to 'yes'. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@130005 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-11-07 Kenneth Zadeck <zadeck@naturalbridge.com>zadeck2007-11-081-1/+1
| | | | | | | | | | | * common.opt: Add pointer to doc/options.texi. * doc/invoke.texi (-fdse, -fdce, -fauto-inc-dec, -fipa-pure-const, -fipa-reference): Add or correct doc. Sorted options list for -Os -O, -O2. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@130000 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-11-05 H.J. Lu <hongjiu.lu@intel.com>hjl2007-11-051-0/+8
| | | | | | | | PR driver/32632 * common.opt: Add shared and pie. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@129913 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-10-29 Richard Guenther <rguenther@suse.de>rguenth2007-10-291-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * passes.c (init_optimization_passes): Exchange store_copy_prop with copy_prop. * tree-pass.h (pass_store_copy_prop): Remove. * tree-ssa-copy.c (do_store_copy_prop): Remove. (stmt_may_generate-copy): Do not handle store_copy_prop. (get_copy_of_val): Likewise. (set_copy_of_val): Likewise. (copy_prop_visit_assignment): Likewise. (copy_prop_visit_stmt): Likewise. (copy_prop_visit_phi_node): Likewise. (init_copy_prop): Likewise. (execute_copy_prop): Likewise. (do_copy_prop): Remove. (gate_store_copy_prop): Likewise. (store_copy_prop): Likewise. (pass_store_copy_prop): Likewise. (pass_copy_prop): Call execute_copy_prop. * opts.c (decode_options): Do not set flag_tree_store_copy_prop. * common.opt (ftree-store-copy-prop): Mark obsolete. * doc/invoke.texi (ftree-store-copy-prop): Remove documentation. * gcc.dg/tree-ssa/ssa-copyprop-1.c: Scan optimized dump. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@129734 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-10-24 Olga Golovanevsky <olga@il.ibm.com>olga2007-10-241-0/+5
| | | | | | | | | | | | | | | | | | | | | | * ipa-type-escape.h: Expose function is_array_access_through_pointer_and_index. * ipa-type-escape.c (is_array_access_through_pointer_and_index): Add three new parameters. Add support of POINTER_PLUS_EXPR tree code. 2007-10-24 Olga Golovanevsky <olga@il.ibm.com> * ipa-struct-reorg.c, ipa-struct-reorg.h: New files. * tree-pass.h: Add pass_ipa_struct_reorg. * common.opt: Add ipa-struct-reorg flag. * Makefile.in: Add ipa-strcut-reorg.o compilation. * passes.c: Add pass pass_ipa_struct_reorg. * params.h: Add STRUCT_REORG_COLD_STRUCT_RATIO. * params.def: Add PARAM_STRUCT_REORG_COLD_STRUCT_RATIO. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@129600 138bc75d-0d04-0410-961f-82ee72b054a4
* * tree-parloops.c: New file.rakdver2007-09-151-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * tree-ssa-operands.h (free_stmt_operands): Declare. * tree-ssa-loop-manip.c (split_loop_exit_edge): Return the new basic block. * tree-pass.h (pass_parallelize_loops): Declare. * omp-low.c (expand_omp_parallel, expand_omp_for): Update SSA form for virtual operands. (build_omp_regions_1): Allow analysing just a single OMP region and its subregions. ( build_omp_regions_root, omp_expand_local): New functions. (build_omp_regions): Add argument to build_omp_regions_1 call. * builtins.def (DEF_GOMP_BUILTIN): Initialize OMP builtins when autoparallelization is run. * timevar.def (TV_TREE_PARALLELIZE_LOOPS): New. * tree-ssa-loop.c (gate_tree_parallelize_loops, tree_parallelize_loops, pass_parallelize_loops): New. * common.opt (ftree-parallelize-loops): New. * tree-flow.h (omp_expand_local, tree_duplicate_sese_tail, parallelize_loops): Declare. (add_phi_args_after_copy, split_loop_exit_edge): Declaration changed. * Makefile.in (tree-parloops.o): Added. * tree-cfg.c (add_phi_args_after_copy_edge, tree_duplicate_sese_tail): New functions. (add_phi_args_after_copy_bb): Use add_phi_args_after_copy_edge. (add_phi_args_after_copy): Call add_phi_args_after_copy_edge for one extra edge as well. (tree_duplicate_sese_region): Add argument to add_phi_args_after_copy. Use VEC_free to free doms vector. (move_block_to_fn): Update loop info. Remove phi nodes for virtual operands. Recompute operand caches in the new function. (move_sese_region_to_fn): Update loop info. * passes.c (init_optimization_passes): Add pass_parallelize_loops. * tree-ssa-operands.c (free_stmt_operands): New function. * doc/passes.texi: Document autoparallelization. * doc/invoke.texi (-ftree-parallelize-loops): New option. * gcc.dg/tree-ssa/parallelization-1.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128517 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-09-13 Seongbae Park <seongbae.park@gmail.com>spark2007-09-131-1/+1
| | | | | | | | * common.opt (femit-class-debug-always): Turn off by default. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128474 138bc75d-0d04-0410-961f-82ee72b054a4
* * tree-pass.h (pass_cselim): Declare new pass.matz2007-09-101-0/+4
| | | | | | | | | | | | | | | | | | | | | * passes.c (init_optimization_passes): Link in pass_cselim. * tree-ssa-phiopt.c (tree_ssa_phiopt_worker): Renamed from tree_ssa_phiopt; add do_store_elim parameter, handle it by calling cond_store_replacement. (condstoretemp): New static variable. (cond_store_replacement): New function. (tree_ssa_phiopt, tree_ssa_cs_elim): New wrappers around tree_ssa_phiopt_worker. (struct name_to_bb): New. (get_non_trapping, name_to_bb_hash, name_to_bb_eq, add_or_mark_expr, nt_init_block, nt_fini_block): New static functions. (seen_ssa_names, nontrap_set): New static variables. (gate_cselim, pass_cselim): Define new pass. * common.opt (ftree-cselim): New flag. * toplev.c (process_options): Set flag_tree_cselim if required. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128324 138bc75d-0d04-0410-961f-82ee72b054a4
* * cgraphbuild.c (rebuild_cgraph_edges): Export.rakdver2007-09-071-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * cgraph.h (rebuild_cgraph_edges): Declare. * tree-pass.h (pass_expand_omp_ssa): New. * omp-low.c (find_omp_clause): Export. (copy_var_decl): Split from omp_copy_decl_2. (build_omp_barrier): Return the call to emit instead of emitting it directly. (lower_rec_input_clauses, expand_omp_single): Gimplify the result of build_omp_barrier. (extract_omp_for_data, expand_parallel_call, expand_omp_parallel, expand_omp_for_generic, expand_omp_for_static_nochunk, expand_omp_for_static_chunk, expand_omp_for, expand_omp_sections): Adapted to work on SSA form. (execute_expand_omp): Do not invalidate dominance information. (gate_expand_omp): Do not run with -fopenmp-ssa flag. (gate_expand_omp_ssa, pass_expand_omp_ssa): New. * gimplify.c (gimplify_omp_for): Ensure that the control variable is a gimple_reg. (force_gimple_operand): Allow gimplifying code expressions without value. * tree-predcom.c (mark_virtual_ops_for_renaming): Handle phi nodes. * common.opt (fopenmp-ssa): New. * tree-flow.h (find_omp_clause, copy_var_decl): Declare. * Makefile.in (tree-cfg.o): Add TREE_INLINE_H dependency. * tree-cfg.c: Include tree-inline.h. (struct move_stmt_d): Replace vars_to_remove by vars_map field. (replace_by_duplicate_decl, replace_ssa_name, mark_virtual_ops_in_region): New functions. (move_stmt_r, move_block_to_fn, move_sese_region_to_fn): Adapted to work on SSA form. * passes.c (init_optimization_passes): Add pass_expand_omp_ssa pass. * tree-ssa-operands.c (get_expr_operands): Handle operands of OMP constructs. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128223 138bc75d-0d04-0410-961f-82ee72b054a4
* * gcc.dg/tree-ssa/loadpre8.c: Disable inlining.hubicka2007-09-041-0/+4
| | | | | | | | | | | | | | | | | | | | | | * gcc.dg/tree-ssa/pr27236.c: Likewise. * gcc.dg/tree-ssa/predcom-1.c: Likewise. * gcc.dg/tree-ssa/predcom-2.c: Likewise. * gcc.dg/tree-ssa/flatten-2.c: Avoid overactive tail call ellim. * gcc.dg/tree-ssa/loadpre5.c: Likewise. * gcc.dg/vect/costmodel/i386/costmodel-fast-math-vect-pr29925.c: Likewise. * invoke.texi (-finline-small-functions): Document. * ipa-inline.c (cgraph_default_inline_p): Do not use DECL_INLINE when deciding what is inlinable. (cgraph_decide_recursive_inlining): Handle flag_inline_functions. (cgraph_decide_inlining_of_small_function): Handle new flags. (cgraph_decide_inlining_incrementally): Likewise. * opts.c (decode_options): Enable flag_inline_small_functions at -O2 * common.opt (finline-small-functions): New. * Makefile.in (build/gengtype.o-warn): Work around PR29478 git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128092 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-09-04 Emmanuel Thome <Emmanuel.Thome@inria.fr>paolo2007-09-041-0/+2
| | | | | | | | PR c++/14178 * common.opt: Mention ABI version 2 in comment. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128085 138bc75d-0d04-0410-961f-82ee72b054a4
* Add new fp flags: -fassociative-math and -freciprocal-mathrevitale2007-09-041-0/+9
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128075 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-08-18 Paul Brook <paul@codesourcery.com>jsm282007-08-181-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Joseph Myers <joseph@codesourcery.com> * Makefile.tpl (DEBUG_PREFIX_CFLAGS_FOR_TARGET): New. (CFLAGS_FOR_TARGET, CXXFLAGS_FOR_TARGET): Include it. * Makefile.in: Regenerate. * configure.ac (--with-debug-prefix-map): New. * configure: Regenerate. config: 2007-08-18 Paul Brook <paul@codesourcery.com> Joseph Myers <joseph@codesourcery.com> * mt-gnu (CXXFLAGS_FOR_TARGET): Add $(DEBUG_PREFIX_CFLAGS_FOR_TARGET). gcc: 2007-08-18 Paul Brook <paul@codesourcery.com> Joseph Myers <joseph@codesourcery.com> * common.opt (-fdebug-prefix-map=): New option. * opts.c: Include debug.h. (common_handle_option): Handle -fdebug-prefix-map. * final.c: Include ggc.h. (struct debug_prefix_map, debug_prefix_maps, add_debug_prefix_map, remap_debug_filename): New. * Makefile.in (final.o, opts.o): Update dependencies. * debug.h (remap_debug_filename, add_debug_prefix_map): Declare. * configure.ac: Check for assembler --debug-prefix-map support. * configure, config.in: Regenerate. * gcc.c (ASM_MAP): Define conditional on HAVE_AS_DEBUG_PREFIX_MAP. (ASM_DEBUG_SPEC): Include ASM_MAP. * doc/install.texi (--with-debug-prefix-map): Document. * doc/invoke.texi (-fdebug-prefix-map): Document. * dbxout.c (dbxout_init, dbxout_start_source_file, dbxout_source_file): Call remap_debug_filename. * dwarf2out.c (add_comp_dir_attribute, maybe_emit_file, dwarf2out_start_source_file, dwarf2out_finish): Call remap_debug_filename. (file_table_relative_p): Do not check d->emitted_number. * toplev.c (output_file_directive): Call remap_debug_filename. * vmsdbgout.c (write_srccorr): Call remap_debug_filename. * xcoffout.c (xcoffout_source_file): Call remap_debug_filename. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@127613 138bc75d-0d04-0410-961f-82ee72b054a4
* ./:ian2007-08-071-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | * common.opt (finstrument-functions-exclude-function-list): New option. (finstrument-functions-exclude-file-list): New option. * opts.c (char_p): Define and DEF_VEC. (flag_instrument_functions_exclude_functions): New static variable. (flag_instrument_functions_exclude_files): New static variable. (add_instrument_functions_exclude_list): New static function. (flag_instrument_functions_exclude_p): New function. (common_handle_option): Handle new options. * flags.h (flag_instrument_functions_exclude_p): Declare. * gimplify.c (gimplify_function_tree): Call flag_instrument_functions_exclude_p. * doc/invoke.texi (Option Summary): Mention new options. (Code Gen Options): Document new options. testsuite/: * gcc.dg/instrument-1.c: New test. * gcc.dg/instrument-2.c: New test. * gcc.dg/instrument-3.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@127284 138bc75d-0d04-0410-961f-82ee72b054a4
* New flag to control reg-moves generationrevitale2007-08-051-0/+4
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@127223 138bc75d-0d04-0410-961f-82ee72b054a4
* Change copyright header to refer to version 3 of the GNU General Public ↵nickc2007-07-261-4/+3
| | | | | | License and to point readers at the COPYING3 file and the FSF's license web page. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@126948 138bc75d-0d04-0410-961f-82ee72b054a4
* Add ability to track uninitialized variables, and mark uninitializedctice2007-07-131-0/+4
| | | | | | | | | variables in the Dwarf debug info. Controlled by compile option -fvar-tracking-uninit git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@126630 138bc75d-0d04-0410-961f-82ee72b054a4
* PR target/27855uros2007-07-091-0/+4
| | | | | | | | | | | * doc/extend.texi: Add ftree-reassoc flag. * common.opt (ftree-reassoc): New flag. * tree-ssa-reassoc.c (gate_tree_ssa_reassoc): New static function. (struct tree_opt_pass pass_reassoc): Use gate_tree_ssa_reassoc. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@126491 138bc75d-0d04-0410-961f-82ee72b054a4
* * common.opt (fipa-matrix-reorg): Add Optimization attribute.nickc2007-06-281-4/+4
| | | | | | | (fdce, fdse, fpredictive-commoning): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@126073 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-06-12 Seongbae Park <seongbae.park@gmail.com>spark2007-06-121-1/+5
| | | | | | | | | | | | | | * opts.c (common_handle_option): Handle new option -fdbg-cnt-list. * dbgcnt.c (dbg_cnt_set_limit_by_name): Return value to indicate an error. (dbg_cnt_process_single_pair, dbg_cnt_list_all_counters): New functions (dbg_cnt_process_opt): Print an error on a bad argument. * dbgcnt.h (dbg_cnt_list_all_counters): New function declaration. * common.opt (-fdbg-cnt-list): New. * doc/invoke.texi (-fdbg-cnt-list,-fdbg-cnt=): New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@125657 138bc75d-0d04-0410-961f-82ee72b054a4
* Merge dataflow branch into mainlinedberlin2007-06-111-0/+16
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@125624 138bc75d-0d04-0410-961f-82ee72b054a4
* gcc/ChangeLog:hjagasia2007-06-081-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2007-06-08 Harsha Jagasia <harsha.jagasia@amd.com> Tony Linthicum <tony.linthicum@amd.com> * doc/extend.texi: Add fvect-cost-model flag. * common.opt (fvect-cost-model): New flag. * tree-vectorizer.c (new_stmt_vec_info): Initialize inside and outside cost fields in stmt_vec_info struct for STMT. * tree-vectorizer.h (stmt_vec_info): Define inside and outside cost fields in stmt_vec_info struct and access functions for the same. (TARG_COND_BRANCH_COST): Define cost of conditional branch. (TARG_VEC_STMT_COST): Define cost of any vector operation, excluding load, store and vector to scalar operation. (TARG_VEC_TO_SCALAR_COST): Define cost of vector to scalar operation. (TARG_VEC_LOAD_COST): Define cost of aligned vector load. (TARG_VEC_UNALIGNED_LOAD_COST): Define cost of misasligned vector load. (TARG_VEC_STORE_COST): Define cost of vector store. (vect_estimate_min_profitable_iters): Define new function. * tree-vect-analyze.c (vect_analyze_operations): Add a compile-time check to evaluate if loop iterations are less than minimum profitable iterations determined by cost model or minimum vect loop bound defined by user, whichever is more conservative. * tree-vect-transform.c (vect_do_peeling_for_loop_bound): Add a run-time check to evaluate if loop iterations are less than minimum profitable iterations determined by cost model or minimum vect loop bound defined by user, whichever is more conservative. (vect_estimate_min_profitable_iterations): New function to estimate mimimimum iterartions required for vector version of loop to be profitable over scalar version. (vect_model_reduction_cost): New function. (vect_model_induction_cost): New function. (vect_model_simple_cost): New function. (vect_cost_strided_group_size): New function. (vect_model_store_cost): New function. (vect_model_load_cost): New function. (vectorizable_reduction): Call vect_model_reduction_cost during analysis phase. (vectorizable_induction): Call vect_model_induction_cost during analysis phase. (vectorizable_load): Call vect_model_load_cost during analysis phase. (vectorizable_store): Call vect_model_store_cost during analysis phase. (vectorizable_call, vectorizable_assignment, vectorizable_operation, vectorizable_promotion, vectorizable_demotion): Call vect_model_simple_cost during analysis phase. gcc/testsuite/ChangeLog: 2007-06-08 Harsha Jagasia <harsha.jagasia@amd.com> * gcc.dg/vect/costmodel: New directory. * gcc.dg/vect/costmodel/i386: New directory. * gcc.dg/vect/costmodel/i386/i386-costmodel-vect.exp: New testsuite. * gcc.dg/vect/costmodel/i386/costmodel-fast-math-vect-pr29925.c: New test. * gcc.dg/vect/costmodel/i386/costmodel-vect-31.c: New test. * gcc.dg/vect/costmodel/i386/costmodel-vect-33.c: New test. * gcc.dg/vect/costmodel/i386/costmodel-vect-68.c: New test. * gcc.dg/vect/costmodel/i386/costmodel-vect-reduc-1char.c: New test. * gcc.dg/vect/costmodel/x86_64: New directory. * gcc.dg/vect/costmodel/x86_64/x86_64-costmodel-vect.exp: New testsuite. * gcc.dg/vect/costmodel/x86_64/costmodel-fast-math-vect-pr29925.c: New test. * gcc.dg/vect/costmodel/x86_64/costmodel-vect-31.c: New test. * gcc.dg/vect/costmodel/x86_64/costmodel-vect-33.c: New test. * gcc.dg/vect/costmodel/x86_64/costmodel-vect-68.c: New test. * gcc.dg/vect/costmodel/x86_64/costmodel-vect-reduc-1char.c: New test. * gcc.dg/vect/costmodel/x86_64/costmodel-pr30843.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@125575 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-05-07 Razya Ladelsky <razya@il.ibm.com> razya2007-05-281-0/+5
| | | | | | | | | | | | | | | | | * matrix-reorg.c: New file. Implement matrix flattening and transposing optimization. * tree-pass.h: Add matrix reorg pass. * common.opt: Add fipa-mreorg flag. * Makefile.in: Add matrix-reorg.c. * passes.c: Add matrix reorg pass. * varpool.c (add_new_static_var): New function. * cgraph.h (add_new_static_var): Declare. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@125126 138bc75d-0d04-0410-961f-82ee72b054a4
* * doc/passes.texi: Document predictive commoning.rakdver2007-05-241-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/invoke.texi (-fpredictive-commoning): Document. * opts.c (decode_options): Enable flag_predictive_commoning on -O3. * tree-ssa-loop-im.c (get_lsm_tmp_name): Export. Allow adding indices to the generated name. (schedule_sm): Pass 0 to get_lsm_tmp_name. * tree-ssa-loop-niter.c (stmt_dominates_stmt_p): Export. * tree-pretty-print.c (op_symbol_1): Renamed to ... (op_symbol_code): ... and exported. (dump_omp_clause, op_symbol): Use op_symbol_code instead of op_symbol_1. * tree-pass.h (pass_predcom): Declare. * timevar.def (TV_PREDCOM): New timevar. * tree-ssa-loop.c (run_tree_predictive_commoning, gate_tree_predictive_commoning, pass_predcom): New. * tree-data-ref.c (find_data_references_in_loop): Find the references in dominance order. (canonicalize_base_object_address): Ensure that the result has pointer type. (dr_analyze_innermost): Export. (create_data_ref): Code to fail for references with invariant address moved ... (find_data_references_in_stmt): ... here. * tree-data-ref.h (dr_analyze_innermost): Declare. * tree-affine.c: Include tree-gimple.h and hashtab.h. (aff_combination_find_elt, name_expansion_hash, name_expansion_eq, tree_to_aff_combination_expand, double_int_constant_multiple_p, aff_combination_constant_multiple_p): New functions. * tree-affine.h (aff_combination_constant_multiple_p, tree_to_aff_combination_expand): Declare. * tree-predcom.c: New file. * common.opt (fpredictive-commoning): New option. * tree-flow.h (op_symbol_code, tree_predictive_commoning, stmt_dominates_stmt_p, get_lsm_tmp_name): Declare. * Makefile.in (tree-predcom.o): Add. (tree-affine.o): Add TREE_GIMPLE_H dependency. * passes.c (init_optimization_passes): Add dceloop after copy propagation in loop optimizer. Add predictive commoning to loop optimizer passes. * gcc.dg/tree-ssa/predcom-1.c: New test. * gcc.dg/tree-ssa/predcom-2.c: New test. * gcc.dg/tree-ssa/predcom-3.c: New test. * gcc.dg/tree-ssa/predcom-4.c: New test. * gcc.dg/tree-ssa/predcom-5.c: New test. * gcc.dg/vect/dump-tree-dceloop-pr26359.c: Test dceloop2 dumps. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@125030 138bc75d-0d04-0410-961f-82ee72b054a4
* * common.opt (fforward-propagate): Fix "Optimization" annotation.steven2007-04-141-2/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@123830 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-03-09 Dirk Mueller <dmueller@suse.de>mueller2007-03-091-0/+4
| | | | | | | | | | | | | | | | | | PR c++/17946 * doc/invoke.texi (-Wlogical-op): Document. * common.opt (-Wlogical-op): New. * c-common.h (warn_logical_operator): Declare. * c-common.c (warn_logical_operator): Define. * c-typeck.c (parser_build_binary_op): Call warn_logical_operator. * cp/call.c (build_new_op): Call warn_logical_operator. * testsuite/gcc.dg/Wlogical-op-1.c: New. * testsuite/g++.dg/warn/Wlogical-op-1.C: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122751 138bc75d-0d04-0410-961f-82ee72b054a4
* * doc/loop.texi: Document the Omega linear constraints solver.spop2007-03-091-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/invoke.texi: Document -fcheck-data-deps, omega-max-vars, omega-max-geqs, omega-max-eqs, omega-max-wild-cards, omega-hash-table-size, omega-max-keys, and omega-eliminate-redundant-constraints. * tree-pass.h (pass_check_data_deps): Declared. * omega.c: New. * omega.h: New. * timevar.def (TV_CHECK_DATA_DEPS): Declared. * tree-ssa-loop.c (check_data_deps, gate_check_data_deps, pass_check_data_deps): New. * tree-data-ref.c (init_data_ref): Remove declaration. (dump_data_dependence_relation): Dump DDR_INNER_LOOP. (analyze_array): Renamed init_array_ref, move up initializations. (init_data_ref): Renamed init_pointer_ref. Moved before its call. Removed arguments that are set to NULL. (analyze_indirect_ref): Correct indentation, correct call to init_pointer_ref. (object_analysis): Call init_array_ref instead of analyze_array. (initialize_data_dependence_relation): Initialize DDR_INNER_LOOP. (access_functions_are_affine_or_constant_p): Use DR_ACCESS_FNS instead of DR_ACCESS_FNS_ADDR. (init_omega_eq_with_af, omega_extract_distance_vectors, omega_setup_subscript, init_omega_for_ddr_1, init_omega_for_ddr, ddr_consistent_p): New. (compute_affine_dependence): Check consistency of ddrs when flag_check_data_deps is passed. (analyze_all_data_dependences): Uncomment. (tree_check_data_deps): New. * tree-data-ref.h: Include omega.h. (DR_ACCESS_FNS_ADDR): Removed. (data_dependence_relation): Add inner_loop. (DDR_INNER_LOOP): New. * common.opt (fcheck-data-deps): New. * tree-flow.h (tree_check_data_deps): Declare. * Makefile.in (TREE_DATA_REF_H): Depend on omega.h. (OBJS-common): Depend on omega.o. (omega.o): Define. * passes.c (pass_check_data_deps): Scheduled. * params.def (PARAM_OMEGA_MAX_VARS, PARAM_OMEGA_MAX_GEQS, PARAM_OMEGA_MAX_EQS, PARAM_OMEGA_MAX_WILD_CARDS, PARAM_OMEGA_HASH_TABLE_SIZE, PARAM_OMEGA_MAX_KEYS, PARAM_VECT_MAX_VERSION_CHECKS, PARAM_OMEGA_ELIMINATE_REDUNDANT_CONSTRAINTS): New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122749 138bc75d-0d04-0410-961f-82ee72b054a4
* * common.opt (Warray-bounds): Add Warning attribute.nickc2007-02-211-7/+7
| | | | | | | | | | (Wstrict-overflow, Wstrict-overflow=, Wcoverage-mismatch): Likewise. (fsized-zeroes): Add Optimization attribute. (fsplit-wide-types, ftree-scev-cprop): Likewise. * c.opt (Wc++0x-compat): Add Warning attribute. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122200 138bc75d-0d04-0410-961f-82ee72b054a4
* 2007-02-19 Manuel Lopez-Ibanez <manu@gcc.gnu.org>manu2007-02-191-8/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * c.opt (Waddress): New. * common.opt (Walways-true): Delete. (Wstring-literal-comparison): Delete. * doc/invoke.texi (Warning Options): Delete -Walways-true and -Wstring-literal-comparison. Add -Waddress. (Waddress): New. (Walways-true): Delete. (Wstring-literal-comparison): Delete. * doc/extend.texi (#pragma GCC diagnostic): Use -Wformat consistently instead of -Walways-true in example. * c-opts.c (c_common_handle_option): -Waddress is enabled by -Wall. * c-typeck.c (parser_build_binary_op): Replace -Wstring-literal-comparison and -Walways-true with -Waddress. * c-common.c (c_common_truthvalue_conversion): Replace -Walways-true with -Waddress. cp/ * typeck.c (build_binary_op): Replace -Wstring-literal-comparison and -Walways-true with -Waddress. * cvt.c (convert_to_void): Replace unconditional warning with -Waddress. testsuite/ * gcc.dg/20031012-1.c: Replace -Walways-true with -Waddress. * gcc.dg/Walways-true-1.c: Likewise. * gcc.dg/weak/weak-3.c: Likewise. * gcc.dg/Werror-1.c: Likewise. * gcc.dg/Werror-3.c: Likewise. * gcc.dg/Werror-4.c: Likewise. * gcc.dg/Werror-5.c: Likewise. * gcc.dg/Werror-6.c: Likewise. * gcc.dg/Werror-7.c: Likewise. * gcc.dg/Werror-8.c: Likewise. * gcc.dg/Werror-10.c: Likewise. * gcc.dg/Werror-11.c: Likewise. * gcc.dg/Werror-12.c: Likewise. * g++.old-deja/g++.mike/warn8.C: Likewise. * g++.dg/warn/Walways-true-1.C: Likewise. * g++.dg/warn/Walways-true-2.C: Likewise. * g++.dg/warn/noeffect8.C: Warn only with -Waddress. * g++.dg/warn/Wstring-literal-comparison-1.C: Replace -Wstring-literal-comparison with -Waddress. * gcc.dg/Wstring-literal-comparison-4.c: Replace -Wno-string-literal-comparison with -Wno-address. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122136 138bc75d-0d04-0410-961f-82ee72b054a4
* ./:ian2007-02-131-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * common.opt: Add Wstrict-overflow and Wstrict-overflow=. * flags.h (warn_strict_overflow): Declare. (enum warn_strict_overflow_code): Define. (issue_strict_overflow_warning): New static inline function. * opts.c (warn_strict_overflow): New variable. (common_handle_option): Handle OPT_Wstrict_overflow and OPT_Wstrict_overflow_. * c-opts.c (c_common_handle_option): Set warn_strict_overflow for OPT_Wall. * fold-const.c: Include intl.h. (fold_deferring_overflow_warnings): New static variable. (fold_deferred_overflow_warning): New static variable. (fold_deferred_overflow_code): New static variable. (fold_defer_overflow_warnings): New function. (fold_undefer_overflow_warnings): New function. (fold_undefer_and_ignore_overflow_warnings): New function. (fold_deferring_overflow_warnings_p): New function. (fold_overflow_warning): New static function. (make_range): Add strict_overflow_p parameter. Change all callers. (extract_muldiv, extract_muldiv_1): Likewise. (fold_unary) [ABS_EXPR]: Check ABS_EXPR before calling tree_expr_nonnegative_p. (fold_negate_expr): Call fold_overflow_warning. (fold_range_test): Likewise. (fold_comparison): Likewise. (fold_binary): Likewise. Call tree_expr_nonnegative_warnv_p instead of tree_expr_nonnegative_p. (tree_expr_nonnegative_warnv_p): Rename from tree_expr_nonnegative_p, add strict_overflow_p parameter. (tree_expr_nonnegative_p): New function. (tree_expr_nonzero_warnv_p): Rename from tree_expr_nonzero_p, add strict_overflow_p parameter. (tree_expr_nonzero_p): New function. * passes.c (verify_interpass_invariants): New static function. (execute_one_pass): Call it. * tree-ssa-loop-niter.c (expand_simple_operations): Ignore fold warnings. (number_of_iterations_exit, loop_niter_by_eval): Likewise. (estimate_numbers_of_iterations): Likewise. (scev_probably_wraps_p): Likewise. * tree-ssa-ccp.c: Include "toplev.h". (evaluate_stmt): Defer fold overflow warnings until we know we are going to optimize. (struct fold_stmt_r_data): Add stmt field. (fold_stmt_r): Defer fold overflow warnings until we know we optimized. (fold_stmt): Initialize stmt field of fold_stmt_r_data. (fold_stmt_inplace): Likewise. * tree-cfgcleanup.c: Include "toplev.h" rather than "errors.h". (cleanup_control_expr_graph): Defer fold overflow warnings until we know we are going to optimize. * tree-cfg.c (fold_cond_expr_cond): Likewise. * tree-ssa-threadedge.c (simplify_control_stmt_condition): Likewise. * tree-vrp.c (vrp_expr_computes_nonnegative): Call tree_expr_nonnegative_warnv_p instead of tree_expr_nonnegative_p. * tree-ssa-loop-manip.c (create_iv): Likewise. * c-typeck.c (build_conditional_expr): Likewise. (build_binary_op): Likewise. * tree-vrp.c (vrp_expr_computes_nonzero): Call tree_expr_nonzero_warnv_p instead of tree_expr_nonzero_p. (extract_range_from_unary_expr): Likewise. * simplify-rtx.c (simplify_const_relational_operation): Warn when assuming that signed overflow does not occur. * c-common.c (pointer_int_sum): Ignore fold overflow warnings. * tree.h (tree_expr_nonnegative_warnv_p): Declare. (fold_defer_overflow_warnings): Declare. (fold_undefer_overflow_warnings): Declare. (fold_undefer_and_ignore_overflow_warnings): Declare. (fold_deferring_overflow_warnings_p): Declare. (tree_expr_nonzero_warnv_p): Declare. * doc/invoke.texi (Option Summary): Add -Wstrict-overflow to list of warning options. (Warning Options): Document -Wstrict-overflow. * Makefile.in (tree-ssa-threadedge.o): Depend on toplev.h. (tree-ssa-ccp.o): Likewise. (tree-cfgcleanup.o): Change errors.h dependency to toplev.h. (fold-const.o): Depend on intl.h. testsuite/: * gcc.dg/Wstrict-overflow-1.c: New test. * gcc.dg/Wstrict-overflow-2.c: New test. * gcc.dg/Wstrict-overflow-3.c: New test. * gcc.dg/Wstrict-overflow-4.c: New test. * gcc.dg/Wstrict-overflow-5.c: New test. * gcc.dg/Wstrict-overflow-6.c: New test. * gcc.dg/Wstrict-overflow-7.c: New test. * gcc.dg/Wstrict-overflow-8.c: New test. * gcc.dg/Wstrict-overflow-9.c: New test. * gcc.dg/Wstrict-overflow-10.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@121895 138bc75d-0d04-0410-961f-82ee72b054a4
* * doc/invoke.texi (Overall Options): Document --help=. ↵nickc2007-02-121-161/+182
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gcc.c (target_help_flag): Rename to print_subprocess_flag. (cc1_options): Pass --help= on to cc1. (display_help): Add description of --help=. (process_command): Add code to handle --help=. Allow translated --help and --target-help switches to be passed on to compiler sub-process. (main): Remove unused if statement. * opts.c (columns): Remove. (LEFT_COLUMN): Define. (wrap_help): Add columns argument. (print_filtered_help): Change parameters to be an include bitmask, an exclude bitmask, an any bitmask and the column width. Move the code to display the params list here. Add code to display the status of options rather than their descriptions if the quiet flag is not active. (print_specific_help): Change parameters to be an include bitmask, an exclude bitmask and an any bitmask. Move code to look up the column width here. Decide upon the title for an options listing. (common_handle_options): Add code to handle --help=. Adapt code for --help and --target-help to use the revised form of the print_specific_help function. (print_help): Delete. (print_param_help): Delete. (print_switch): Delete. * opts.h (cl_lang_count): Add prototype. (CL_PARAMS, CL_WARNING, CL_OPTIMIZATION, CL_MIN_OPTION_CLASS, CL_MAX_OPTION_CLASS): New defines. * optc-gen.awk: Add construction of cl_lang_count. * c.opt: Add Warning attribute to warning options and Optimization attribute to optimization options. * common.opt: Likewise. Add --help=. Add -fhelp and -ftarget-help as aliases for the transformed --help and --target-help options. * opt-functions.awk: Add code to handle Warning and Optimization attributes. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@121849 138bc75d-0d04-0410-961f-82ee72b054a4