Commit Graph

139 Commits

Author SHA1 Message Date
Steven Bosscher 7ee2468b92 system.h (dump_file): Do not define.
gcc/
	* system.h (dump_file): Do not define.
	* tree-pass.h: Include dumpfile.h, which is a new file containing...
	(enum tree_dump_index, TDF_*, get_dump_file_name, dump_enabled_p,
	dump_initialized_p, dump_begin, dump_end, dump_node, dump_switch_p,
	dump_flag_name, dump_file, dump_flags, dump_file_name,
	get_dump_file_info, struct dump_file_info): all of this, moved to...
	* dumpfile.h: Here, new file.
	* tree-dump.h: Include dumpfile.h, but not tree-pass.h.
	(dump_stmt): Remove prototype for C++ specific function.
	(dump_enumerated_decls): Move prototype from here...
	* tree-flow.h (dump_enumerated_decls): ... to here.
	(get_ref_base_and_extent) Move prototype from here ...
	* tree.h (get_ref_base_and_extent) ... to here.
	* tree-ssa-live.c: Do not inclde tree-pretty-print.h, because
	gimple-pretty-print.h is enough.  Do not include tree-dump.h,
	include timevar.h and dumpfile.h instead.
	(struct numbered_tree_d, compare_decls_by_uid,
	dump_enumerated_decls_push, dump_enumerated_decls): Move from here ...
	* tree-dfa.c:(struct numbered_tree_d, compare_decls_by_uid,
	dump_enumerated_decls_push, dump_enumerated_decls):... to here.
	Do not include timevar.h.
	* tree.c: Do not include timevar.h.
	* tree-cfg.c: Do not include langhooks.h, tree-pretty-print.h, and
	timevar.h.
	(dump_cfg_stats): Use current_function_name.
	(gimple_cfg2vcg): Likewise.
	(dump_function_to_file): Likewise.
	* df-scan.c: Do not include tree-pass.h and timevar.h.
	Include dumpfile.h.
	(df_entry_block_bitmap_verify, df_exit_block_bitmap_verify): Do not
	use print_current_pass.
	* df-problems.c: Include dumpfile.h.
	Always define REG_DEAD_DEBUGGING, avoid #ifdef code, because it
	leads to errors in the code not selected.
	(df_note_compute): Do not print_rtl_with_bb here.  Fix compilation
	bug if REG_DEAD_DEBUGGING is not 0, get_insns is not available here.
	* lcm.c: Include dumpfile.h.
	Remove obsolete include of insn-attr.h.
	* dojump.c (do_compare_rtx_and_jump): Remove failure printing for
	missing probability notes.
	* stmt.c: Include dumpfile.h.
	(emit_case_decision_tree): Re-enable printing expand details only
	if TDF_DETAILS.
	* alias.c, auto-inc-dec.c, bb-reorder.c, caller-save.c, cfg.c, 
	cfgcleanup.c, cfgexpand.c, cfgloop.c, cfgloopmanip.c, cgraph.c, 
	cgraphclones.c, cgraphunit.c, combine.c, combine-stack-adj.c, 
	coverage.c, cprop.c, cse.c, cselib.c, dbgcnt.c, dce.c, df-core.c, 
	dse.c, dwarf2out.c, emit-rtl.c, except.c, expr.c, final.c, 
	function.c, fwprop.c, gcse.c, gimple-fold.c, 
	gimple-pretty-print.c, gimple-ssa-strength-reduction.c, 
	gimplify.c, graphite-blocking.c, graphite-clast-to-gimple.c, 
	graphite-dependences.c, graphite-interchange.c, 
	graphite-optimize-isl.c, graphite-poly.c, 
	graphite-sese-to-poly.c, haifa-sched.c, hw-doloop.c, ifcvt.c, 
	ipa.c, ipa-cp.c, ipa-inline-analysis.c, ipa-inline.c, 
	ipa-inline-transform.c, ipa-prop.c, ipa-pure-const.c, 
	ipa-reference.c, ipa-split.c, ipa-utils.c, ira.c, ira-emit.c, 
	jump.c, loop-doloop.c, loop-init.c, loop-invariant.c, loop-iv.c, 
	loop-unroll.c, loop-unswitch.c, lower-subreg.c, 
	lto-section-out.c, lto-streamer-in.c, matrix-reorg.c, mcf.c, 
	mode-switching.c, modulo-sched.c, omega.c, omp-low.c, passes.c, 
	plugin.c, postreload.c, postreload-gcse.c, predict.c, print-rtl.c, 
	print-tree.c, profile.c, recog.c, ree.c, regcprop.c, reginfo.c, 
	regmove.c, regrename.c, reg-stack.c, reload1.c, reorg.c, 
	sched-rgn.c, sched-vis.c, sel-sched.c, sel-sched-ir.c, 
	store-motion.c, tracer.c, trans-mem.c, tree-affine.c, 
	tree-call-cdce.c, tree-cfgcleanup.c, tree-chrec.c, 
	tree-data-ref.c, tree-diagnostic.c, tree-dump.c,
	tree-eh.c, tree-flow-inline.h, tree-if-conv.c, tree-into-ssa.c, 
	tree-mudflap.c, tree-nrv.c, tree-object-size.c, 
	tree-optimize.c, tree-outof-ssa.c, tree-predcom.c, 
	tree-pretty-print.c, tree-profile.c, tree-scalar-evolution.c, 
	tree-sra.c, tree-ssa-address.c, tree-ssa-alias.c, tree-ssa.c, 
	tree-ssa-ccp.c, tree-ssa-coalesce.c, tree-ssa-copy.c, 
	tree-ssa-copyrename.c,, tree-ssa-dce.c, tree-ssa-dom.c, 
	tree-ssa-dse.c, tree-ssa-forwprop.c, tree-ssa-ifcombine.c, 
	tree-ssa-loop.c, tree-ssa-loop-ch.c, tree-ssa-loop-im.c, 
	tree-ssa-loop-ivcanon.c, tree-ssa-loop-ivopts.c, 
	tree-ssa-loop-manip.c, tree-ssa-loop-niter.c, 
	tree-ssa-loop-prefetch.c, tree-ssa-loop-unswitch.c, 
	tree-ssa-math-opts.c, tree-ssa-operands.c, tree-ssa-phiopt.c, 
	tree-ssa-phiprop.c, tree-ssa-pre.c, tree-ssa-propagate.c, 
	tree-ssa-reassoc.c, tree-ssa-sccvn.c, tree-ssa-sink.c, 
	tree-ssa-structalias.c, tree-ssa-tail-merge.c, tree-ssa-ter.c, 
	tree-ssa-threadedge.c, tree-ssa-threadupdate.c, 
	tree-ssa-uncprop.c, tree-ssa-uninit.c, 
	tree-switch-conversion.c, tree-tailcall.c, 
	tree-vect-data-refs.c, tree-vect-loop.c, 
	tree-vect-loop-manip.c, tree-vectorizer.c, 
	tree-vect-patterns.c, tree-vect-slp.c, tree-vect-stmts.c, 
	tree-vrp.c, value-prof.c, var-tracking.c, web.c: Include tree-pass.h
	only if needed.  If tree-pass.h is included, do not include timevar.h
	and dumpfile.h.  If tree-pass.h is not included but dump_file, or
	dump_flags, or the TDF_* flags are used, include dumpfile.h.
	If gimple-pretty-print.h is included, don't include tree-pretty-print.h.
	Remove assorted unnecessary includes.

	* config/mn10300/mn10300.c, config/c6x/c6x.c, config/ia64/ia64.c,
	config/arm/arm.c, config/bfin/bfin.c, config/frv/frv.c,
	config/spu/spu.c, config/mep/mep.c, config/i386/i386.c:
	Include dumpfile.h.
	* config/rl78/rl78.c: Include dumpfile.h instead of tree-pass.h.
	* arm/t-arm, avr/t-avr, i386/t-i386, ia64/t-ia64, mep/t-mep,
	spu/t-spu-elf: Fix dependencies.

c-family/
	* c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
	* c-ada-spec.c: Likewise.
	* c-dump.c (dump_stmt): Move to cp/dump.c, the only user.

c/
	* c-decl.c: Include dumpfile.h instead of tree-dump.h.
	* Make-lang.in: Fix dependencies.

cp/
	* dump.c (dump_stmt): Moved here from c-dump.c.
	* optimize.c: Include dumpfile.h instead of tree-dump.h.
	* class.c: Likewise.
	* decl2.c: Likewise.
	* Make-lang.in: Fix dependencies.

fortran/
	* f95-lang.c: Include dumpfile.h instead of tree-dump.h.
	* Make-lang.in: Fix dependencies.

java/
	* java-gimplify.c Include dumpfile.h instead of tree-dump.h
	* Make-lang.in: Fix dependencies.

lto/
	* lto.c: Do not include timevar.h.
	* Make-lang.in: Fix dependencies.

ada/
	* gcc-interface/utils.c: Include timevar.h.
	* Make-lang.in: Fix dependencies.

From-SVN: r189519
2012-07-16 11:32:42 +00:00
Richard Biener 05232ff6d3 tree-if-conv.c (main_tree_if_conversion): Move bb under ENABLE_CHECKING.
2012-04-24  Richard Guenther  <rguenther@suse.de>

	* tree-if-conv.c (main_tree_if_conversion): Move bb under
	ENABLE_CHECKING.

From-SVN: r186763
2012-04-24 14:18:40 +00:00
Richard Guenther c654217566 re PR tree-optimization/53070 (ICE: in execute_cse_reciprocals, at tree-ssa-math-opts.c:513 with -O -ffast-math -ftree-loop-if-convert -fno-tree-loop-im)
2012-04-23  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/53070
	* tree-if-conv.c (combine_blocks): Free predicates in all blocks.
	(main_tree_if_conversion): Verify we succeeded in that.

	* gcc.dg/torture/pr53070.c: New testcase.

From-SVN: r186704
2012-04-23 12:47:02 +00:00
Richard Guenther 8b7db2596e re PR tree-optimization/52975 (Ofast produces not optimized code for vectorized "converted if")
2012-04-16  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/52975
	* tree-if-conv.c (predicate_bbs): Do not simplify inverted
	condition but always mark it with TRUTH_NOT_EXPR.

From-SVN: r186491
2012-04-16 11:03:16 +00:00
Richard Guenther 95df37bf8b re PR tree-optimization/52969 (ICE in in get_expr_operands, at tree-ssa-operands.c:1035 with -ftree-loop-if-convert-stores)
2012-04-13  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/52969
	* tree-if-conv.c (predicate_mem_writes): Properly gimplify
	the condition for the COND_EXPR and handle predicate negation
	by swapping the COND_EXPR arms.

	* gcc.dg/torture/pr52969.c: New testcase.

From-SVN: r186416
2012-04-13 12:22:16 +00:00
Rainer Orth d47657bd1d Fix sgi typos
libgcc:
	* config/arm/crtn.S: Fix typo.

	gcc/testsuite:
	* ada/acats/tests/cd/cdd1001.a (CDD1001): Fix typo.

	gcc:
	* config/microblaze/microblaze.md: Fix typo.
	* tree-if-conv.c: Likewise.
	* tree-vect-patterns.c: Likewise.

From-SVN: r185325
2012-03-13 10:22:56 +00:00
Richard Guenther cd7d9fd77b cfgexpand.c (gimple_expand_cfg): Free dominator info.
2012-03-05  Richard Guenther  <rguenther@suse.de>

	* cfgexpand.c (gimple_expand_cfg): Free dominator info.
	* tree-if-conv.c (combine_blocks): Free post-dominator info
	after breaking it.
	* tree-parloops.c (create_parallel_loop): Free and re-compute
	dominator info after breaking it.

From-SVN: r184933
2012-03-05 14:36:18 +00:00
Bernhard Reutner-Fischer b8f4632ce8 tree-if-conv (predicate_scalar_phi): Commentary typo fix.
2012-02-13  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>

	* tree-if-conv (predicate_scalar_phi): Commentary typo fix.

From-SVN: r184546
2012-02-24 10:42:24 +01:00
Richard Guenther 747633c574 re PR tree-optimization/50319 (if-conversion produces unvectorizable conditions)
2011-09-07  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/50319
	* tree-if-conv.c (set_bb_predicate): Assert we only set
	canonical predicates.
	(add_to_predicate_list): Simplify.  Allow TRUTH_NOT_EXPR
	around canonical predicates.
	(predicate_bbs): Do not re-gimplify already canonical
	predicates.  Properly unshare them though.
	(find_phi_replacement_condition): Simplify.

From-SVN: r178638
2011-09-07 14:19:33 +00:00
David Li 22c5fa5fbf dumping cleanup phase 1 -- Removing TODO_dump_func
From-SVN: r175051
2011-06-14 19:39:36 +00:00
Jakub Jelinek c2b5fc8de6 re PR tree-optimization/48975 (ICE in execute_cse_reciprocals() with -fno-tree-slp-vectorize)
PR tree-optimization/48975
	* tree-if-conv.c (combine_blocks): Call free_bb_predicate
	on all bbs here and free and clear ifc_bbs at the end.

	* gcc.dg/pr48975.c: New test.

From-SVN: r173709
2011-05-12 19:44:23 +02:00
Richard Guenther d7978bff88 re PR c/47892 (Fails to vectorize comparison code, if-conversion fails)
2011-04-20  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/47892
	* tree-if-conv.c (if_convertible_stmt_p): Const builtins
	are if-convertible.

	* gcc.dg/vect/fast-math-ifcvt-1.c: New testcase.

From-SVN: r172774
2011-04-20 15:50:26 +00:00
Richard Guenther 4979c28bc9 tree-if-conv.c (memrefs_read_or_written_unconditionally): Strip all non-variable offsets and compare the remaining bases of the two...
* tree-if-conv.c (memrefs_read_or_written_unconditionally): Strip all
	non-variable offsets and compare the remaining bases of the two
	accesses instead of looking for exact same data-ref.


Co-Authored-By: Ira Rosen <ira.rosen@linaro.org>

From-SVN: r171900
2011-04-03 08:30:53 +00:00
Richard Guenther b14fad9dd8 re PR tree-optimization/47849 (ICE: SIGSEGV in find_edge (cfganal.c:491) with -ftree-loop-if-convert -fno-tree-reassoc)
2011-02-23  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/47849
	* tree-if-conv.c (main_tree_if_conversion): Free postdom info.

From-SVN: r170441
2011-02-23 16:49:52 +00:00
Sebastian Pop db963b5287 Fix PR47271: only if-convert full writes.
2011-01-25  Sebastian Pop  <sebastian.pop@amd.com>
	    Jakub Jelinek  <jakub@redhat.com>

	PR tree-optimization/47271
	* tree-if-conv.c (bb_postdominates_preds): New.
	(if_convertible_bb_p): Call bb_postdominates_preds.
	(if_convertible_loop_p_1): Compute CDI_POST_DOMINATORS.
	(predicate_scalar_phi): Call bb_postdominates_preds.

	* gcc.dg/tree-ssa/ifc-pr47271.c: New.

Co-Authored-By: Jakub Jelinek <jakub@redhat.com>

From-SVN: r169233
2011-01-25 14:51:23 +00:00
Sebastian Pop 01be8516aa Fix PR47002: memory leaks.
2010-12-23  Sebastian Pop  <sebastian.pop@amd.com>

	PR tree-optimization/47002
	* tree-data-ref.c (compute_data_dependences_for_loop): Pass in a
	pointer to the loop_nest.
	(analyze_all_data_dependences): Initialize and free the loop_nest.
	(free_dependence_relations): Do not free loop_nest.
	(build_rdg): Pass in the loop_nest, datarefs, and dependence_relations.
	(free_rdg): Also free the data on edges.
	* tree-data-ref.h (build_rdg): Update declaration.
	(compute_data_dependences_for_loop): Same.
	* tree-if-conv.c (if_convertible_loop_p_1): Pass in the loop_nest.
	(if_convertible_loop_p): Allocate and free loop_nest.
	* tree-loop-distribution.c (rdg_flag_loop_exits): Free conds.
	(free_rdg_components): VEC_free components.
	(distribute_loop): Update call to build_rdg.  Allocate and free
	loop_nest, datarefs, and dependence_relations.
	* tree-loop-linear.c (linear_transform_loops): Allocate and free
	loop_nest.
	* tree-parloops.c (loop_parallel_p): Same.
	* tree-predcom.c (tree_predictive_commoning_loop): Same.
	* tree-vect-data-refs.c (vect_analyze_data_refs): Pass to
	compute_data_dependences_for_loop a pointer to LOOP_VINFO_LOOP_NEST.
	* tree-vect-loop.c (new_loop_vec_info): Initialize LOOP_VINFO_LOOP_NEST.
	(destroy_loop_vec_info): Free LOOP_VINFO_MAY_ALIAS_DDRS and
	LOOP_VINFO_LOOP_NEST.
	* tree-vect-slp.c (destroy_bb_vec_info): Call free_data_refs and
	free_dependence_relations.
	* tree-vectorizer.h (struct _loop_vec_info): Add a field loop_nest.
	(LOOP_VINFO_LOOP_NEST): New.

From-SVN: r168210
2010-12-23 16:25:52 +00:00
Sebastian Pop e639b20676 Fix PR45971: do not predicate condition phi nodes that are scev analyzable.
2010-11-10  Sebastian Pop  <sebastian.pop@amd.com>

	PR tree-optimization/45971
	* tree-if-conv.c (predicate_scalar_phi): Do not generate a COND_EXPR
	for phi nodes analyzable by scev.

	* gcc.dg/vect/O3-pr45971.c: New.

From-SVN: r166544
2010-11-10 16:06:47 +00:00
Sebastian Pop 0104d6c71a re PR tree-optimization/46036 (verify_ssa failed: definition in block 3 follows the use)
Fix PR46036.

2010-11-09  Sebastian Pop  <sebastian.pop@amd.com>

	PR tree-optimization/46036
	* tree-if-conv.c (predicate_bbs): Call unshare_expr before
	add_to_dst_predicate_list.

	* gfortran.dg/lto/pr46036_0.f90: New.

From-SVN: r166508
2010-11-09 19:23:43 +00:00
Jakub Jelinek e05eee4908 re PR tree-optimization/46008 (Floating point condexpr not vectorized)
PR tree-optimization/46008
	* tree-if-conv.c (predicate_bbs): Try to canonicalize c2
	if possible.

From-SVN: r165476
2010-10-14 21:34:16 +02:00
Sebastian Pop b0af49c40c Use DR_IS_WRITE instead of !DR_IS_READ.
2010-09-03  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-data-ref.c (dr_may_alias_p): Replace !DR_IS_READ with
	DR_IS_WRITE.
	(compute_all_dependences): Same.
	(create_rdg_edge_for_ddr): Same.
	* tree-data-ref.h (DR_IS_WRITE): New.
	(ddr_is_anti_dependent): Replace !DR_IS_READ with DR_IS_WRITE.
	* tree-if-conv.c (write_memrefs_written_at_least_once): Same.
	(write_memrefs_written_at_least_once): Same.
	* tree-predcom.c (suitable_component_p): Same.
	(determine_roots_comp): Same.
	(execute_load_motion): Same.
	* tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Same.
	(vect_enhance_data_refs_alignment): Same.
	(vect_analyze_group_access): Same.

From-SVN: r163841
2010-09-03 20:05:42 +00:00
Sebastian Pop 4b9c23ea4e Speed-up ifcvt_memrefs_wont_trap caching previous results.
This patch speeds up the ifcvt_memrefs_wont_trap computation by
caching the results of the computations in the data references ->aux
fields.

	* tree-if-conv.c (struct ifc_dr): New.
	(IFC_DR): New.
	(DR_WRITTEN_AT_LEAST_ONCE): New.
	(DR_RW_UNCONDITIONALLY): New.
	(memref_read_or_written_unconditionally): Use the cached values
	when possible.
	(write_memref_written_at_least_once): Same.
	(if_convertible_loop_p): Initialize and free DR->aux fields.

From-SVN: r163532
2010-08-24 23:36:04 +00:00
Sebastian Pop e1fd038a0c Do not check whether memory references accessed in every iteration trap.
This patch relaxes the checks from gimple_could_trap_p in order to
allow the flag_loop_if_convert_stores to if-convert more loops
in which it is possible to prove that:

- the accesses to an array in a loop do not trap (more than the
  original non-if-converted loop).  This is true when the memory
  accesses are executed at every iteration of the if-converted loop.

- the writes to memory occur on arrays that are not const qualified.
  This is true when there exists at least one unconditional write to
  the array in the analyzed program.  In this patch this analysis is
  limited to the loop to be if-converted.

	* gimple.c (gimple_could_trap_p_1): Not static anymore.
	Pass an extra bool parameter include_mem.
	(gimple_could_trap_p): Adjust call to gimple_could_trap_p_1.
	(gimple_assign_rhs_could_trap_p): Same.
	* gimple.h (gimple_could_trap_p_1): Declared.
	* tree-data-ref.h (same_data_refs_base_objects): New.
	(same_data_refs): New.
	* tree-if-conv.c (memrefs_read_or_written_unconditionally): New.
	(write_memrefs_written_at_least_once): New.
	(ifcvt_memrefs_wont_trap): New.
	(operations_could_trap): New.
	(ifcvt_could_trap_p): New.
	(if_convertible_gimple_assign_stmt_p): Call ifcvt_could_trap_p.
	Gets a vector of data refs.
	(if_convertible_stmt_p): Same.
	(if_convertible_loop_p_1): New.
	(if_convertible_loop_p): Call if_convertible_loop_p_1.

	* gcc.dg/tree-ssa/ifc-5.c: New.

From-SVN: r163531
2010-08-24 23:35:56 +00:00
Sebastian Pop bd544141e0 Add flag -ftree-loop-if-convert-stores.
This patch adds a flag that controls the replacement of the memory
writes that are in predicated basic blocks with a full write:

for (...)
  if (cond)
    A[i] = foo

is replaced with:

for (...)
  A[i] = cond ? foo : A[i]

In order to do this, we have to call gimple_could_trap_p instead of
gimple_assign_rhs_could_trap_p, as we have to also check that the LHS
of assign stmts does not trap.

	* common.opt (ftree-loop-if-convert-stores): New flag.
	* doc/invoke.texi (ftree-loop-if-convert-stores): Documented.
	* tree-if-conv.c (ifc_temp_var): Pass an extra parameter GSI.  Insert
	the created statement before GSI.
	(if_convertible_phi_p): Allow virtual phi nodes when
	flag_loop_if_convert_stores is set.
	(if_convertible_gimple_assign_stmt_p): Allow memory reads and writes
	Do not handle types that do not match is_gimple_reg_type.
	Remove loop and bb parameters.  Call gimple_could_trap_p instead of
	when flag_loop_if_convert_stores is set, as LHS can contain
	memory refs.
	(if_convertible_stmt_p): Remove loop and bb parameters.  Update calls
	to if_convertible_gimple_assign_stmt_p.
	(if_convertible_loop_p): Update call to if_convertible_stmt_p.
	(replace_phi_with_cond_gimple_assign_stmt): Renamed
	predicate_scalar_phi.  Do not handle virtual phi nodes.
	(ifconvert_phi_nodes): Renamed predicate_all_scalar_phis.
	Call predicate_scalar_phi.
	(insert_gimplified_predicates): Insert the gimplified predicate of a BB
	just after the labels for flag_loop_if_convert_stores, otherwise
	insert the predicate in the end of the BB.
	(predicate_mem_writes): New.
	(combine_blocks): Call predicate_all_scalar_phis.  When
	flag_loop_if_convert_stores is set, call predicate_mem_writes.
	(tree_if_conversion): Call mark_sym_for_renaming when
	flag_loop_if_convert_stores is set.
	(main_tree_if_conversion): Return TODO_update_ssa_only_virtuals when
	flag_loop_if_convert_stores is set.

	* gcc.dg/tree-ssa/ifc-4.c: New.
	* gcc.dg/tree-ssa/ifc-7.c: New.

From-SVN: r163530
2010-08-24 23:35:48 +00:00
Sebastian Pop 59ee2304b0 Outline fold_or_predicates from add_to_predicate_list.
2010-07-09  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (fold_or_predicates): New.
	(add_to_predicate_list): Call it.

From-SVN: r162007
2010-07-09 18:58:20 +00:00
Sebastian Pop d89e5e20b6 Call maybe_fold_or_comparisons to fold OR-ed predicates.
2010-07-08  Sebastian Pop  <sebastian.pop@amd.com>

	PR tree-optimization/44710
	* tree-if-conv.c (parse_predicate): New.
	(add_to_predicate_list): Call it, call maybe_fold_or_comparisons.
	Make sure that the predicates are either SSA_NAMEs or gimple_condexpr.

	* gcc.dg/tree-ssa/ifc-6.c: New.
	* gcc.dg/tree-ssa/ifc-pr44710.c: New.

From-SVN: r161964
2010-07-08 16:38:00 +00:00
Sebastian Pop 384a5197cb Add the -ftree-loop-if-convert flag.
2010-07-08  Sebastian Pop  <sebastian.pop@amd.com>

	* common.opt (ftree-loop-if-convert): New flag.
	* doc/invoke.texi (ftree-loop-if-convert): Documented.
	* tree-if-conv.c (gate_tree_if_conversion): Enable if-conversion
	when flag_tree_loop_if_convert is set.

From-SVN: r161963
2010-07-08 16:37:49 +00:00
Sebastian Pop 5c8b27d7da Do not insert statements computing the true predicate.
2010-06-25  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (insert_gimplified_predicates): Do not insert
	statements computing the true predicate.

From-SVN: r161398
2010-06-25 18:38:25 +00:00
Sebastian Pop 29caa68aa5 Use reset_bb_predicate whenever the predicate of a BB should be reset to true.
2010-06-25  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (init_bb_predicate): Initialize the predicate
	to boolean_true_node.
	(reset_bb_predicate): New.
	(predicate_bbs): Call reset_bb_predicate.

From-SVN: r161397
2010-06-25 18:38:14 +00:00
Sebastian Pop 0f741287d6 Call cleanup_tree_cfg after if-conversion.
2010-06-25  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (combine_blocks): Remove FIXME comment.
	(tree_if_conversion): Returns true when something has been changed.
	(main_tree_if_conversion): Return TODO_cleanup_cfg when if-conversion
	changed something.

From-SVN: r161396
2010-06-25 18:38:04 +00:00
Sebastian Pop 53aa40a821 Add a debug counter for the tree-ssa level if-conversion.
2010-06-25  Sebastian Pop  <sebastian.pop@amd.com>

	* Makefile.in (tree-if-conv.o): Depends on DBGCNT_H.
	* dbgcnt.def (if_conversion_tree): New DEBUG_COUNTER.
	* tree-if-conv.c: Include dbgcnt.h.
	(tree_if_conversion): Use if_conversion_tree to count the number of
	if-convertible loops.

From-SVN: r161395
2010-06-25 18:37:50 +00:00
Sebastian Pop 7b14477e38 Fix PR44483: incrementally gimplify BB predicates to avoid redundant computations.
2010-06-11  Sebastian Pop  <sebastian.pop@amd.com>

	PR middle-end/44483
	* tree-if-conv.c (bb_predicate_s): New struct.
	(bb_predicate_p): New.
	(bb_has_predicate): New.
	(bb_predicate): New.
	(set_bb_predicate): New.
	(bb_predicate_gimplified_stmts): New.
	(set_bb_predicate_gimplified_stmts): New.
	(add_bb_predicate_gimplified_stmts): New.
	(init_bb_predicate): New.
	(free_bb_predicate): New.
	(is_predicated): Use bb_predicate.
	(add_to_predicate_list): Use bb_predicate and set_bb_predicate.
	(predicate_bbs): Same.  Gimplify the condition of the basic blocks
	before processing their successors.
	(clean_predicate_lists): Removed.
	(find_phi_replacement_condition): Use bb_predicate.
	(process_phi_nodes): Renamed ifconvert_phi_nodes.  Avoid useless
	computations.
	(insert_gimplified_predicates): New.
	(combine_blocks): Call insert_gimplified_predicates.
	(tree_if_conversion): Call free_bb_predicate instead of
	clean_predicate_lists.

	* gcc.dg/tree-ssa/pr44483.c: New.

From-SVN: r160625
2010-06-11 18:28:17 +00:00
Sebastian Pop 718d3588b0 Only reset the GIMPLE_DEBUG information in the code gen of if-conversion.
2010-06-02  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (predicate_bbs): Do not reset the GIMPLE_DEBUG
	information.
	(remove_conditions_and_labels): Reset the GIMPLE_DEBUG information.

From-SVN: r160164
2010-06-02 16:39:37 +00:00
Sebastian Pop 5521cae9c2 Fix PR44363: don't abort when the ifcvt analysis fails to recognize a Gimple stmt.
2010-06-02  Sebastian Pop  <sebastian.pop@amd.com>

	PR middle-end/44363
	* tree-if-conv.c (predicate_bbs): Do not call gcc_unreachable,
	return false instead.

From-SVN: r160163
2010-06-02 16:39:26 +00:00
Steven Bosscher 2eb79bbbb3 gimplify.c: Do not include except.h and optabs.h.
* gimplify.c: Do not include except.h and optabs.h.
	(gimplify_body): Do not initialize RTL profiling.
	* gimple-low.c: Do not include rtl.h, diagnostic.h, langhooks.h,
	langhooks-def.h, timevar.h, except.h, hashtab.h, and expr.h.
	* gimple-fold.c: Do not include rtl.h, tm_p.h, ggc.h, basic-block.h,
	output.h, expr.h, diagnostic.h, timevar.h, value-prof.h, and
	langhooks.h.

	* tree-pretty-print.h: Include pretty-print.h.
	* gimple-pretty-print.h: Include pretty-print.h.

	* tree-pretty-print.c: Do not include diagnostic.h.
	* tree-vrp.c: Likewise.
	* tree-tailcall.c: Likewise
	* tree-scalar-evolution.c: Likewise
	* tree-ssa-dse.c: Likewise
	* tree-chrec.c: Likewise
	* tree-ssa-sccvn.c: Likewise
	* tree-ssa-copyrename.c: Likewise
	* tree-nomudflap.c: Likewise
	* tree-call-cdce.c: Likewise
	* tree-stdarg.c: Likewise
	* tree-ssa-math-opts.c: Likewise
	* tree-nrv.c: Likewise
	* tree-ssa-sink.c: Likewise
	* tree-browser.c: Likewise
	* tree-ssa-loop-ivcanon.c: Likewise
	* tree-ssa-loop.c: Likewise
	* tree-parloops.c: Likewise
	* tree-ssa-address.c: Likewise
	* tree-ssa-ifcombine.c: Likewise
	* tree-if-conv.c: Likewise
	* tree-data-ref.c: Likewise
	* tree-affine.c: Likewise
	* tree-ssa-phiopt.c: Likewise
	* tree-ssa-coalesce.c: Likewise
	* tree-ssa-pre.c: Likewise
	* tree-ssa-live.c: Likewise
	* tree-predcom.c: Likewise
	* tree-ssa-forwprop.c: Likewise
	* tree-ssa-dce.c: Likewise
	* tree-ssa-ter.c: Likewise
	* tree-ssa-loop-prefetch.c: Likewise
	* tree-optimize.c: Likewise
	* tree-ssa-phiprop.c: Likewise
	* tree-object-size.c: Likewise
	* tree-outof-ssa.c: Likewise
	* tree-ssa-structalias.c: Likewise
	* tree-switch-conversion.c: Likewise
	* tree-ssa-reassoc.c: Likewise
	* tree-ssa-operands.c: Likewise
	* tree-vectorizer.c: Likewise
	* tree-vect-data-refs.c: Likewise
	* tree-vect-generic.c: Likewise
	* tree-vect-stmts.c: Likewise
	* tree-vect-patterns.c: Likewise
	* tree-vect-slp.c: Likewise
	* tree-vect-loop.c: Likewise
	* tree-ssa-loop-ivopts.c: Likewise
	* tree-ssa-loop-im.c: Likewise
	* tree-ssa-loop-niter.c: Likewise
	* tree-ssa-loop-unswitch.c: Likewise
	* tree-ssa-loop-manip.c: Likewise
	* tree-ssa-loop-ch.c: Likewise
	* tree-dump.c: Likewise
	* tree-complex.c: Likewise

	* tree-into-ssa.c: Do not include diagnostic.h and expr.h.
	* tree-ssa-uninit.c: Likewise
	* tree-ssa-threadupdate.c: Likewise
	* tree-ssa-uncprop.c: Likewise
	* tree-ssa-ccp.c: Likewise
	* tree-ssa-dom.c: Likewise
	* tree-ssa-propagate.c: Likewise
	* tree-ssa-alias.c: Likewise
	* tree-dfa.c: Likewise
	* tree-cfgcleanup.c: Likewise
	* tree-sra.c: Likewise
	* tree-ssa-copy.c: Likewise
	* tree-ssa.c: Likewise
	* tree-profile.c: Likewise
	* tree-cfg.c: Likewise
	* tree-ssa-threadedge.c: Likewise
	* tree-vect-loop-manip.c: Likewise

	* tree-inline.c: Do not include diagnostic.h and expr.h.
	Include rtl.h.
	(copy_decl_for_dup_finish): Do not use NULL_RTX.

	* tree-loop-linear.c: Do not include diagnostic.h, expr.h,
	and optabs.h.
	* tree-loop-distribution.c: Likewise.

From-SVN: r160125
2010-06-01 22:00:56 +00:00
Sebastian Pop 0247298c28 Don't use unshare_expr when not necessary.
2010-05-29  Sebastian Pop  <sebastian.pop@amd.com>

	PR middle-end/44306
	* gcc.dg/tree-ssa/pr44306.c: New.

	* tree-if-conv.c (is_true_predicate): New.
	(is_predicated): Use is_true_predicate.
	(add_to_predicate_list): Same.  Do not use unshare_expr.
	(add_to_dst_predicate_list): Same.

From-SVN: r160031
2010-05-29 17:14:31 +00:00
Sebastian Pop 32ccbfacd1 Do not use annotations on edges in if-conversion.
2010-05-29  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (add_to_dst_predicate_list): Do not use the ->aux
	field on edges.
	(predicate_bbs): Same.
	(clean_predicate_lists): Same.
	(find_phi_replacement_condition): Do not AND the predicate from
	edge->aux.

From-SVN: r160030
2010-05-29 17:14:17 +00:00
Sebastian Pop e7cb8957bf Don't generate COND_EXPRs for degenerate_phi_result.
2010-05-28  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (replace_phi_with_cond_gimple_assign_stmt): Don't
	generate COND_EXPRs for degenerate_phi_result.

From-SVN: r159991
2010-05-28 18:42:06 +00:00
Sebastian Pop d10e857ebb Check the if-convertibility of phi nodes in non predicated BBs.
2010-05-28  Sebastian Pop  <sebastian.pop@amd.com>

	PR middle-end/44293
	* tree-if-conv.c (if_convertible_loop_p): Check the
	if-convertibility of phi nodes in non predicated BBs.

From-SVN: r159990
2010-05-28 18:38:06 +00:00
Sebastian Pop 4204425f00 Do not check the if-convertibility of statements that are not predicated.
2010-05-26  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (if_convertible_gimple_assign_stmt_p): Do not
	special case loop->header.
	(is_predicated): New.
	(if_convertible_loop_p): Call it.

From-SVN: r159887
2010-05-26 16:47:08 +00:00
Sebastian Pop e1449456c0 Reorganize the analysis of basic block predication.
2010-05-26  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (add_to_dst_predicate_list): Do not pass a statemet
	iterator in parameter.  Do not generate code during the analysis.
	(tree_if_convert_cond_stmt): Removed.
	(tree_if_convert_stmt): Removed.
	(predicate_bbs): New.
	(if_convertible_loop_p): Call predicate_bbs.
	(tree_if_conversion): Simplify the top-level logic as predicate_bbs
	now contains all the analysis part.

From-SVN: r159886
2010-05-26 16:46:59 +00:00
Sebastian Pop 76b8477663 Remove conditions in the code generation of if-conversion.
2010-05-26  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (tree_if_convert_cond_stmt): Do not remove
	statements in the analysis part.
	(tree_if_convert_stmt): Update comment.
	(remove_conditions_and_labels): New.
	(combine_blocks): Call remove_conditions_and_labels.
	(tree_if_conversion): Update comment.

From-SVN: r159885
2010-05-26 16:46:49 +00:00
Sebastian Pop bc447143dc Don't handle BBs with more than 2 preds or succs.
2010-05-26  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (if_convertible_bb_p): Don't handle BBs with more
	than 2 predecessors or more than 2 successors.

From-SVN: r159884
2010-05-26 16:46:39 +00:00
Sebastian Pop 6d7950341a Avoid if-conversion of loops in which the data dependence analysis fails.
2010-05-26  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (if_convertible_loop_p): Avoid if-conversion
	of loops in which the data dependence analysis fails.

From-SVN: r159883
2010-05-26 16:46:25 +00:00
Sebastian Pop d730961859 Do not compute/free CDI_POST_DOMINATORS.
2010-05-26  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (if_convertible_loop_p): Do not compute/free
	CDI_POST_DOMINATORS.
	(tree_if_conversion): Same.

From-SVN: r159882
2010-05-26 16:46:12 +00:00
Sebastian Pop 7b371e73d8 Make tree_if_conversion not return a bool.
2010-05-26  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c (tree_if_conversion): Do not return a bool.

From-SVN: r159881
2010-05-26 16:45:56 +00:00
Sebastian Pop 4ab719737c Fix comments.
2010-05-26  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c: Update copyright years.  Fix comments.
	Fix indentation.

From-SVN: r159880
2010-05-26 16:45:47 +00:00
Joseph Myers cf8358387d diagnostic.c: Don't include tm.h, tree.h, tm_p.h, langhooks.h or langhooks-def.h.
* diagnostic.c: Don't include tm.h, tree.h, tm_p.h, langhooks.h or
	langhooks-def.h.
	(diagnostic_initialize): Initialize x_data not last_function.
	(diagnostic_report_current_function): Move to tree-diagnostic.c.
	(default_diagnostic_starter): Call
	diagnostic_report_current_module not
	diagnostic_report_current_function.
	(diagnostic_report_diagnostic): Initialize x_data not
	abstract_origin.
	(verbatim): Likewise.
	* diagnostic.h (struct diagnostic_info): Change abstract_origin to
	x_data.
	(struct diagnostic_context): Change last_function to x_data.
	(diagnostic_auxiliary_data): Replace with
	diagnostic_context_auxiliary_data and
	diagnostic_info_auxiliary_data.
	(diagnostic_last_function_changed, diagnostic_set_last_function,
	diagnostic_report_current_function): Move to tree-diagnostic.h.
	(print_declaration, dump_generic_node, print_generic_stmt,
	print_generic_stmt_indented, print_generic_expr,
	print_generic_decl, debug_c_tree, dump_omp_clauses,
	print_call_name, debug_generic_expr, debug_generic_stmt,
	debug_tree_chain, default_tree_printer): Move to
	tree-pretty-print.h.
	(debug_gimple_stmt, debug_gimple_seq, print_gimple_seq,
	print_gimple_stmt, print_gimple_expr, dump_gimple_stmt): Move to
	gimple-pretty-print.h.
	* pretty-print.c: Don't include tree.h
	(pp_base_format): Don't handle %K here.
	(pp_base_tree_identifier): Move to tree-pretty-print.c.
	* pretty-print.h (text_info): Change abstract_origin to x_data.
	(pp_tree_identifier, pp_unsupported_tree,
	pp_base_tree_identifier): Move to tree-pretty-print.h.
	* gimple-pretty-print.h, tree-diagnostic.c, tree-diagnostic.h,
	tree-pretty-print.h: New files.
	* tree-pretty-print.c: Include tree-pretty-print.h.
	(percent_K_format): New.  Moved from pretty-print.c.
	(pp_base_tree_identifier): Move from pretty-print.c.
	* c-objc-common.c: Include tree-pretty-print.h.
	(c_tree_printer): Handle %K here.
	* langhooks.c: Include tree-diagnostic.h.
	(lhd_print_error_function): Use diagnostic_abstract_origin macro.
	* toplev.c: Include tree-diagnostic.h and tree-pretty-print.h.
	(default_tree_printer): Handle %K using percent_K_format.
	(general_init): Use default_tree_diagnostic_starter.
	* tree.c: Include tree-diagnostic.h and tree-pretty-print.h.
	(free_lang_data): Use default_tree_diagnostic_starter.
	* c-pretty-print.c: Include tree-pretty-print.h.
	* cfgexpand.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* cgraphunit.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* dwarf2out.c: Include tree-pretty-print.h.
	* except.c: Include tree-pretty-print.h.
	* gimple-pretty-print.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* gimplify.c: Include tree-pretty-print.h.
	* graphite-poly.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* ipa-cp.c: Include tree-pretty-print.h.
	* ipa-inline.c: Include gimple-pretty-print.h.
	* ipa-prop.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* ipa-pure-const.c: Include gimple-pretty-print.h.
	* ipa-struct-reorg.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* ipa-type-escape.c: Include tree-pretty-print.h.
	* print-rtl.c: Include tree-pretty-print.h.
	* print-tree.c: Include gimple-pretty-print.h.
	* sese.c: Include tree-pretty-print.h.
	* tree-affine.c: Include tree-pretty-print.h.
	* tree-browser.c: Include tree-pretty-print.h.
	* tree-call-cdce.c: Include gimple-pretty-print.h.
	* tree-cfg.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-chrec.c: Include tree-pretty-print.h.
	* tree-data-ref.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-dfa.c: Include tree-pretty-print.h.
	* tree-if-conv.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-inline.c: Include tree-pretty-print.h.
	* tree-into-ssa.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-nrv.c: Include tree-pretty-print.h.
	* tree-object-size.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-outof-ssa.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-parloops.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-predcom.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-scalar-evolution.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-sra.c: Include tree-pretty-print.h.
	* tree-ssa-address.c: Include tree-pretty-print.h.
	* tree-ssa-alias.c: Include tree-pretty-print.h.
	* tree-ssa-ccp.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-coalesce.c: Include tree-pretty-print.h.
	* tree-ssa-copy.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-copyrename.c: Include tree-pretty-print.h.
	* tree-ssa-dce.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-dom.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-dse.c: Include gimple-pretty-print.h.
	* tree-ssa-forwprop.c: Include tree-pretty-print.h.
	* tree-ssa-ifcombine.c: Include tree-pretty-print.h.
	* tree-ssa-live.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-loop-im.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-loop-ivcanon.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-loop-ivopts.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-loop-niter.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-loop-prefetch.c: Include tree-pretty-print.h.
	* tree-ssa-math-opts.c: Include gimple-pretty-print.h.
	* tree-ssa-operands.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-phiprop.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-pre.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-propagate.c: Include gimple-pretty-print.h.
	* tree-ssa-reassoc.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-sccvn.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-sink.c: Include gimple-pretty-print.h.
	* tree-ssa-ter.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-ssa-uninit.c: Include gimple-pretty-print.h.
	* tree-ssa.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-stdarg.c: Include gimple-pretty-print.h.
	* tree-switch-conversion.c: Include gimple-pretty-print.h.
	* tree-tailcall.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-vect-data-refs.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-vect-loop-manip.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-vect-loop.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-vect-patterns.c: Include gimple-pretty-print.h.
	* tree-vect-slp.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-vect-stmts.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* tree-vectorizer.c: Include tree-pretty-print.h.
	* tree-vrp.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* value-prof.c: Include tree-pretty-print.h and
	gimple-pretty-print.h.
	* var-tracking.c: Include tree-pretty-print.h.
	* Makefile.in (OBJS-common): Add tree-diagnostic.o.
	(tree-diagnostic.o): New dependencies.
	(c-objc-common.o, c-pretty-print.o, langhooks.o, tree.o,
	tree-inline.o, print-tree.o, stor-layout.o, tree-ssa-uninit.o,
	tree-ssa.o, tree-into-ssa.o, tree-ssa-ter.o, tree-ssa-coalesce.o,
	tree-outof-ssa.o, tree-ssa-forwprop.o, tree-ssa-phiprop.o,
	tree-ssa-ifcombine.o, tree-nrv.o, tree-ssa-copy.o,
	tree-ssa-propagate.o, tree-ssa-dom.o, tree-ssa-uncprop.o,
	tree-ssa-live.o, tree-ssa-copyrename.o, tree-ssa-pre.o,
	tree-ssa-sccvn.o, tree-vrp.o, tree-cfg.o, tree-tailcall.o,
	tree-ssa-sink.o, tree-if-conv.o, tree-dfa.o, tree-ssa-operands.o,
	tree-ssa-address.o, tree-ssa-loop-niter.o,
	tree-ssa-loop-ivcanon.o, tree-ssa-loop-prefetch.o, tree-predcom.o,
	tree-ssa-loop-ivopts.o, tree-affine.o, tree-ssa-loop-im.o,
	tree-ssa-math-opts.o, tree-ssa-alias.o, tree-ssa-reassoc.o,
	gimplify.o, tree-browser.o, tree-chrec.o, tree-scalar-evolution.o,
	tree-data-ref.o, sese.o, graphite-poly.o, tree-vect-loop.o,
	tree-vect-loop-manip.o, tree-vect-patterns.o, tree-vect-slp.o,
	tree-vect-stmts.o, tree-vect-data-refs.o, tree-vectorizer.o,
	tree-parloops.o, tree-stdarg.o, tree-object-size.o,
	gimple-pretty-print.o, tree-pretty-print.o, diagnostic.o,
	toplev.o, print-rtl.o, except.o, dwarf2out.o, cgraphunit.o,
	ipa-prop.o, ipa-cp.o, ipa-inline.o, ipa-pure-const.o,
	ipa-type-escape.o, ipa-struct-reorg.o, tree-ssa-dce.o,
	tree-call-cdce.o, tree-ssa-ccp.o, tree-sra.o,
	tree-switch-conversion.o, var-tracking.o, value-prof.o,
	cfgexpand.o, pretty-print.o): Update dependencies.

cp:
	* error.c: Include tree-diagnostic.h and tree-pretty-print.h.
	(cp_print_error_function): Use diagnostic_abstract_origin macro.
	(cp_printer): Handle %K here using percent_K_format.
	* cxx-pretty-print.c: Include tree-pretty-print.h.
	* Make-lang.in (cp/error.o, cp/cxx-pretty-print.o): Update
	dependencies.

From-SVN: r159685
2010-05-21 23:34:26 +01:00
Steven Bosscher 40013784db tree.h: Include real.h and fixed-value.h as basic datatypes.
gcc/ChangeLog:
	* tree.h: Include real.h and fixed-value.h as basic datatypes.
	* dfp.c, convert.c, reload1.c, reginfo.c, tree-flow.h,
	tree-ssa-threadedge.c, tree-ssanames.c, tree-loop-linear.c,
	tree-into-ssa.c, tree-vect-generic.c, tree-ssa-structalias.c,
	tree-ssa-loop-im.c, tree-dump.c, tree-complex.c, tree-ssa-uninit.c,
	genrecog.c, tree-ssa-threadupdate.c, tree-ssa-loop-niter.c,
	tree-pretty-print.c, tree-loop-distribution.c,
	tree-ssa-loop-unswitch.c, c-lex.c, optabs.c, postreload-gcse.c,
	tree-ssa-loop-manip.c, postreload.c, tree-ssa-loop-ch.c,
	tree-tailcall.c, tree.c, reload.c, tree-scalar-evolution.c, rtlanal.c,
	tree-phinodes.c, builtins.c, final.c, genoutput.c, fold-const.c,
	tree-ssa-dse.c, genautomata.c, tree-ssa-uncprop.c, toplev.c,
	tree-chrec.c, genemit.c, c-cppbuiltin.c, tree-ssa-sccvn.c,
	tree-ssa-ccp.c, tree-ssa-loop-ivopts.c, mode-switching.c,
	tree-call-cdce.c, cse.c, genpeep.c, tree-ssa-math-opts.c,
	tree-ssa-dom.c, tree-nrv.c, tree-ssa-propagate.c, tree-ssa-alias.c,
	tree-ssa-sink.c, jump.c, ifcvt.c, dwarf2out.c, expr.c, genattrtab.c,
	genconditions.c, tree-ssa-loop-ivcanon.c, tree-ssa-loop.c,
	tree-parloops.c, recog.c, tree-ssa-address.c, lcm.c, tree-eh.c,
	gimple-pretty-print.c, c-pretty-print.c, print-rtl.c, gcse.c,
	tree-if-conv.c, tree-data-ref.c, tree-affine.c, gimplify.c,
	tree-ssa-phiopt.c, implicit-zee.c, expmed.c, tree-dfa.c, emit-rtl.c,
	store-motion.c, cselib.c, tree-cfgcleanup.c, simplify-rtx.c,
	tree-ssa-pre.c, genpreds.c, tree-mudflap.c, print-tree.c,
	tree-ssa-copy.c, tree-ssa-forwprop.c, tree-ssa-dce.c, varasm.c,
	tree-nested.c, tree-ssa.c, tree-ssa-loop-prefetch.c, rtl.c,
	tree-inline.c, integrate.c, tree-optimize.c, tree-ssa-phiprop.c,
	fixed-value.c, combine.c, tree-profile.c, c-common.c, sched-vis.c,
	tree-cfg.c, passes.c, tree-ssa-reassoc.c, config/alpha/alpha.c,
	config/frv/frv.c, config/s390/s390.c, config/m32c/m32c.c,
	config/spu/spu.c, config/sparc/sparc.c, config/mep/mep.c,
	config/m32r/m32r.c, config/rx/rx.c, config/i386/i386.c,
	config/sh/sh.c, config/pdp11/pdp11.c, config/avr/avr.c,
	config/crx/crx.c, config/xtensa/xtensa.c, config/stormy16/stormy16.c,
	config/fr30/fr30.c, config/lm32/lm32.c, config/moxie/moxie.c,
	config/m68hc11/m68hc11.c, config/cris/cris.c, config/iq2000/iq2000.c,
	config/mn10300/mn10300.c, config/ia64/ia64.c, config/m68k/m68k.c,
	config/rs6000/rs6000.c, config/picochip/picochip.c, config/darwin.c,
	config/arc/arc.c, config/mcore/mcore.c, config/score/score3.c,
	config/score/score7.c, config/score/score.c, config/arm/arm.c,
	config/pa/pa.c, config/mips/mips.c, config/vax/vax.c,
	config/h8300/h8300.c, config/v850/v850.c, config/mmix/mmix.c,
	config/bfin/bfin.c:
	Clean up redundant includes.
	* Makefile.in: Update accordingly.

java/ChangeLog:
	* typeck.c, decl.c, jcf-parse.c, except.c, expr.c:

cp/Changelog:
	* error.c, tree.c, typeck2.c, cxx-pretty-print.c, mangle.c:
	Clean up redundant includes.

fortran/ChangeLog:
	* trans-const.c, trans-types.c, trans-intrinsic.c:
	Clean up redundant includes.

From-SVN: r159663
2010-05-21 13:53:22 +00:00
Steven Bosscher 9aae8d16dd toplev.c: Include varray.h for statistics dumping.
gcc/ChangeLog:
	* toplev.c: Include varray.h for statistics dumping.
	* tree.h: Do not declare varray_head_tag.
	* tree-into-ssa.c, tree-ssa-uninit.c, tree-phinodes.c, omega.c,
	regs.h, lto-cgraph.c, tree-ssa-loop-ivopts.c, tree-nomudflap.c,
	c-objc-common.c, lto-streamer-out.c, tree-ssa-propagate.c,
	gimple-low.c, c-semantics.c, dwarf2out.c, lto-streamer-in.c,
	lto-section-in.c, alias.c, tree-if-conv.c, gimplify.c, ggc-zone.c,
	tree-ssa.c, tree-ssa-loop-prefetch.c, integrate.h, c-gimplify.c,
	c-common.c, c-common.h, reg-stack.c, basic-block.h,
	tree-ssa-structalias.c, lto-section-out.c, tree-ssanames.c: Do not
	include varray.h.
	* Makefile.in: Update for abovementioned changes.

objc/ChangeLog:
	* objc-act.c: Do not include varray.h.

objcp/ChangeLog:
	* objcp-decl.c: Do not include varray.h.

cp/ChangeLog:
	* optimize.c, parser.c,mangle.c, cp-tree.h: DO not include varray.h.
	* Make-lang.in: Don't include varray.h dependency in CXX_TREE_H.

From-SVN: r158933
2010-04-30 11:58:49 +00:00
Sebastian Pop 98c07c54a0 Fix comments, simplify logic.
2010-04-08  Sebastian Pop  <sebastian.pop@amd.com>

	* tree-if-conv.c: Fix comments and simplify logic.

From-SVN: r158136
2010-04-08 17:32:23 +00:00