Age | Commit message (Collapse) | Author | Files | Lines |
|
* basic-block.h, bb-reorder.c, c-gimplify.c, config/darwin.c,
config/rs6000/rs6000-c.c, dominance.c, gimple-low.c, gimplify.c,
lambda-code.c, lambda-trans.c, tree-browser.c, tree-cfg.c,
tree-chrec.c, tree-data-ref.c, tree-dfa.c, tree-eh.c,
tree-if-conv.c, tree-into-ssa.c, tree-loop-linear.c,
tree-mudflap.c, tree-nomudflap.c, tree-outof-ssa.c,
tree-pretty-print.c, tree-scalar-evolution.c, tree-sra.c,
tree-ssa-ccp.c, tree-ssa-copy.c, tree-ssa-dce.c, tree-ssa-dom.c,
tree-ssa-dse.c, tree-ssa-forwprop.c, tree-ssa-live.c,
tree-ssa-operands.c, tree-ssa-phiopt.c, tree-ssa-pre.c,
tree-ssa-propagate.c, tree-ssa-sink.c, tree-ssa-threadupdate.c,
tree-ssa-uncprop.c, tree-ssa.c, tree-vect-analyze.c,
tree-vect-transform.c, tree-vectorizer.c, vec.c: Don't include
errors.h and include toplev.h if necessary.
* rtl.c, varray.c: If we're compiling as a GENERATOR_FILE, include
errors.h otherwise include toplev.h.
* Makefile.in: Update dependencies.
ada:
* misc.c: Don't include errors.h.
fortran:
* fortran/trans-decl.c: Don't include errors.h.
* fortran/Make-lang.in: Updates dependencies.
java:
* java/verify-glue.c: Don't include errors.h and include toplev.h.
* java/Make-lang.in: Updates dependencies.
treelang:
* treelang/lex.l, treelang/parse.y: Don't include errors.h and
include toplev.h.
* treelang/Make-lang.in: Updates dependencies.
From-SVN: r100420
|
|
2005-05-30 Daniel Berlin <dberlin@dberlin.org>
* c-objc-common.c (c_tree_printer): Check flag before hashtable.
Use DECL_DEBUG_EXPR and SET_DECL_DEBUG_EXPR.
* dwarf2out.c (dwarf2out_var_location): Ditto.
* toplev.c (default_tree_printer): Ditto.
* tree-outof-ssa.c (create_temp): Ditto.
* tree-sra.c (instantiate_element): Ditto.
* var-tracking.c (track_expr_p): Ditto.
* tree.c (struct tree_map): New structure.
(debug_expr_for_decl): New.
(tree_map_eq): New function.
(tree_map_hash): Ditto.
(tree_map_marked_p): Ditto.
(print_debug_expr_statistics): Ditto.
(decl_debug_expr_lookup): Ditto.
(decl_debug_expr_insert): Ditto.
(dump_tree_statistics): Dump debug_expr hashtable stats.
* tree.h (DECL_DEBUG_EXPR): Change
(SET_DECL_DEBUG_EXPR): Add.
From-SVN: r100417
|
|
2005-05-03 Andrew MacLeod <amacleod@redhat.com>
* lambda-code.c (gcc_loop_to_lambda_loop,
lambda_loopnest_to_gcc_loopnest, phi_loop_edge_uses_def,
stmt_is_bumper_for_loop, perfect_nest_p, replace_uses_of_x_with_y): Use
generic operand interface.
* tree-data-ref.c (find_data_references_in_loop): Use generic interface.
* tree-dfa.c (collect_dfa_stats_r, mark_new_vars_to_rename): Use
generic operand interface.
* tree-flow-inline.h (delink_imm_use, link_imm_use_to_list,
link_imm_use, link_imm_use_stmt, relink_imm_use, relink_imm_use_stmt,
next_safe_imm_use, has_zero_uses, has_single_use, single_imm_use,
num_imm_uses): Use ssa_use_operand_t.
(get_def_ops, get_use_ops, get_v_may_def_ops, get_vuse_ops,
get_v_must_def_ops): Delete.
(get_def_from_ptr, get_phi_result_ptr): Get def directly now.
(get_use_op_ptr, get_def_op_ptr, get_v_may_def_result_ptr,
get_v_may_def_op_ptr, get_vuse_op_ptr, get_v_must_def_result_ptr,
get_v_must_def_kill_ptr): Delete.
(delink_stmt_imm_use): Move and use new operand interface.
(op_iter_next_use, op_iter_next_def, op_iter_next_tree, op_iter_init,
op_iter_next_tree): Use new operand implementation.
(clear_and_done_ssa_iter): New. Initialize a blank operand iterator.
(op_iter_init_use, op_iter_init_def, op_iter_init_tree): Add iterator
type check.
(op_iter_next_mustdef, op_iter_next_maydef,
op_iter_next_must_and_may_def): Delete. Replace with...
(op_iter_next_maymustdef): New. Combine must and may next operations.
(op_iter_init_maydef, op_iter_init_mustdef,
op_iter_init_must_and_may_def): Use new interface.
(single_ssa_tree_operand ): New. Process single operands only as trees.
(single_ssa_use_operand): New. Process single operands only as uses.
(single_ssa_def_operand): New. Process single operands only as defs.
(zero_ssa_operands): New. Return TRUE if there are zero operands of the
specified types.
(num_ssa_operands): New. Count the number of specified operands.
(compare_ssa_operands_equal): New. Compare two statements' operands.
(single_phi_def): New. Return true if PHI has one def of the specified
operand type.
(op_iter_init_phiuse): New. Initialize the iterator for PHI arguments.
(op_iter_init_phidef): New. Initialize the iterator for the PHI def.
* tree-flow.h (struct immediate_use_iterator_d): Use ssa_use_operand_t.
(struct stmt_ann_d): Operands field no longer require GTY().
(vn_compute, vn_lookup_or_add, vn_add, vn_lookup): Change prototype.
* tree-into-ssa.c (mark_def_sites): Use SSA_OP_VMUSTKILL.
* tree-outof-ssa.c (check_replaceable, find_replaceable_in_bb,
dump_replaceable_exprs, rewrite_trees): Use generic interface.
* tree-phinodes.c (make_phi_node, release_phi_node, resize_phi_node):
Use use_operand_p instead of ssa_imm_use_t *.
* tree-pretty-print.c (dump_vops): check if operands are active before
dumping virtual operands.
* tree-sra.c (sra_walk_function): Use ZERO_SSA_OPERANDS.
* tree-ssa-ccp.c (likely_value): Use ZERO_SSA_OPERANDS.
(ccp_fold): Use new interface.
(ccp_visit_stmt): Remove unused variables and code.
(convert_to_gimple_builtin): Insert statements before calling
mark_new_vars_to_rename.
* tree-ssa-copy.c (stmt_may_generate_copy): Use ZERO_SSA_OPERANDS.
(copy_prop_visit_cond_stmt): Use generic interface.
* tree-ssa-dom.c (struct expr_hash_elt): Use stmt pointer, not the
annotation in table.
(thread_across_edge): Use generic interface.
(initialize_hash_element): Initialzie with stmt, not annotation.
(eliminate_redundant_computations): Use generic interface.
(record_equivalences_from_stmt): Pass stmt, not annotation.
(avail_expr_hash, real_avail_expr_hash, avail_expr_eq): Use generic
interface.
* tree-ssa-dse.c (dse_optimize_stmt): Use ZERO_SSA_OPERANDS.
* tree-ssa-loop-ivopts.c (find_invariants_stmt,
find_interesting_uses_stmt, protect_loop_closed_ssa_form_use): Use
generic operand interface.
* tree-ssa-loop-niter.c (chain_of_csts_start, get_val_for): Use generic
interface.
* tree-ssa-loop-unswitch.c (tree_may_unswitch_on): Use Generic operand
Interface.
* tree-ssa-operands.c (struct opbuild_list_d): New. Operand build type.
(build_defs, build_uses, build_v_may_defs, build_vuses,
build_v_must_defs): Change type to struct opbuild_list_d.
(ops_active): New. Operands active boolean.
(operand_memory, operand_memory_index): New. Operand memory managers.
(allocate_def_optype, allocate_use_optype, allocate_v_may_def_optype,
allocate_vuse_optype, allocate_v_must_def_optype): Delete.
(free_uses, free_defs, free_vuses, free_v_may_defs, free_v_must_defs):
Change from functions to static variable list heads.
(opbuild_initialize_virtual): New. Initialize a virtual build list.
(opbuild_initialize_real): New. Initialize a virtual build list.
(opbuild_free): New. Free a build list.
(opbuild_num_elems): New. Number of items in a list.
(opbuild_append_real): New. Add a real (tree *) operand.
(opbuild_append_virtual): New. Add and sort a virtual (tree) operand.
(opbuild_first): New. Return first element index in a list.
(opbuild_next): New. Return next element in a list.
(opbuild_elem_real): New. Return real element.
(opbuild_elem_virtual): New. Return virtual element.
(opbuild_elem_uid): New. Return UID of virtual element.
(opbuild_clear): New. Reset an operand list.
(opbuild_remove_elem): New. Remove an element form a list.
(ssa_operands_active): New. Return true if operand cache is active.
(init_ssa_operands, fini_ssa_operands): Initialize new implementation.
(ssa_operand_alloc): New. Allocate memory from an operand chunk.
(correct_use_link): Use use_operand_p.
(finalize_ssa_uses, finalize_ssa_v_may_defs, finalize_ssa_defs,
finalize_ssa_vuses, finalize_ssa_v_must_defs): New implmentation.
(cleanup_v_may_defs): Use new implmentation.
(finalize_ssa_stmt_operands, start_ssa_stmt_operands): New
implementation.
(append_def, append_use, append_v_may_def, append_vuse,
append_v_must_def): Call opbuild_append routine instead of using varray.
(build_ssa_operands): Simplify to simply use stmt, don't maintain a
global parse_old_ops variable.
(free_ssa_operands): New implementation.
(update_stmt_operands): Move. Change argument to build_ssa_operands.
(copy_virtual_operands): Move. New generic implementation.
(create_ssa_artficial_load_stmt): Move. New implementation.
(swap_tree_operands): Update for new implementation.
(get_expr_operands): Add stmt parameter to calls to swap_tree_operands.
(add_call_clobber_ops, add_call_read_ops): Initialize opbuild list
rather than a varray.
(verify_imm_links): Use use_operand_p.
(dump_immediate_uses_for): If the immediate use variable is a virtual
variable, show the virtual ops in the stmt.
* tree-ssa-operands.h (def_operand_p): No longer a structure.
(NULL_DEF_OPERAND_P): Now a #define.
(def_optype_d, use_optype_d, v_def_use_operand_type, v_may_def_optype_d,
vuse_operand_type, vuse_optype_d, v_must_def_optype_d): Delete.
(def_optype_d, use_optype_d, maydef_optype_d, vuse_optype_d,
mustdef_optype_d): New. Use Linked list representation.
(SSA_OPERAND_MEMORY_SIZE): New. Size of operand memory chunk.
(struct ssa_operand_memory_d): New. Allocated Chunk node.
(struct stmt_operands_d): Change to new pointers that are not GTY.
(STMT_USE_OPS, NUM_USES, SET_USE_OP, STMT_DEF_OPS, NUM_DEFS, SET_DEF_OP,
STMT_V_MAY_DEF_OPS, NUM_V_MAY_DEFS, SET_V_MAY_DEF_RESULT,
SET_V_MAY_DEF_OP, STMT_VUSE_OPS, NUM_VUSES, SET_VUSE_OP,
STMT_V_MUST_DEF_OPS, NUM_V_MUST_DEFS, SET_V_MUST_DEF_RESULT,
SET_V_MUST_DEF_KILL): Delete.
(V_MAY_DEF_OPS, V_MAY_DEF_RESULT_PTR, V_MAY_DEF_RESULT,
V_MAY_DEF_OP_PTR, V_MAY_DEF_OP): Rename to MAYDEF_*.
(V_MUST_DEF_OPS, V_MUST_DEF_RESULT_PTR, V_MUST_DEF_RESULT,
V_MUST_DEF_KILL_PTR, V_MUST_DEF_KILL): Rename to MUSTDEF_*.
(enum ssa_op_iter_type): Operand iterator typechecking values.
(struct ssa_operand_iterator_d): Use linked lists of operands.
(SSA_OP_VMUSTDEFKILL): Rename to SSA_OP_VMUSTKILL.
(FOR_EACH_SSA_MAYDEF_OPERAND, FOR_EACH_SSA_MUSTDEF_OPERAND,
FOR_EACH_SSA_MUST_AND_MAY_DEF_OPERAND): Use op_iter_next_maymustdef.
(FOR_EACH_PHI_ARG): New. Iterate over PHI arguments.
(FOR_EACH_PHI_OR_STMT_USE): New. Iterate over PHI or stmt uses.
(FOR_EACH_PHI_OR_STMT_DEF): New. Iterate over PHI or stmt defs.
(SINGLE_SSA_TREE_OPERAND, SINGLE_SSA_USE_OPERAND,
SINGLE_SSA_DEF_OPERAND, ZERO_SSA_OPERANDS, NUM_SSA_OPERANDS): New.
* tree-ssa-opfinalize.h: New. Function templates for expansion.
(FINALIZE_ALLOC): Expands into alloc_def, alloc_use, alloc_maydef,
alloc_vuse, and alloc_mustdef.
(FINALIZE_FUNC): Expands into finalize_ssa_def_ops,
finalize_ssa_use_ops, finalize_ssa_v_may_def_ops, finalize_ssa_vuse_ops,
and finalize_ssa_v_must_def_ops.
* tree-ssa-pre.c (add_to_sets): Pass tree to vn_add.
(create_value_expr_from): Use stmt not vuse_optype as a parameter. Pass
stmt around.
(compute_avail): Use generic iterator interface.
* tree-ssa-propagate.c (first_vdef): Use generic operand interface.
(stmt_makes_single_load, stmt_makes_single_store): Use
ZERO_SSA_OPERANDS.
* tree-ssa-sink.c (is_hidden_global_store): Use ZERO_SSA_OPERANDS.
(statement_sink_location): Use generic interface.
* tree-ssa.c (verify_ssa): Use %p in fprintf. Use generic interface.
(delete_tree_ssa): Don't call release_defs. Call release_ssa_name and
reset the immediate use link nodes.
(stmt_references_memory_p): Use ZERO_SSA_OPERANDS.
* tree-ssanames.c (make_ssa_name): Use use_operand_p.
* tree-tailcall.c (find_tail_calls): Use ZERO_SSA_OPERANDS.
(eliminate_tail_call): Use generic operand interface.
* tree-vect-analyze.c (vect_analyze_data_refs): Use ZERO_SSA_OPERANDS.
(vect_mark_relevant, vect_mark_stmts_to_be_vectorized): Use generic
interface.
* tree-vect-transform.c (update_vuses_to_preheader): Use generic
interface.
* tree-vectorizer.c (rename_variables_in_bb): Use generic interface.
* tree-vn.c (struct val_expr_pair_d): Cache statment pointer instead of
vuse_optype.
(vn_compute, val_expr_pair_hash, vn_add, vn_lookup, vn_lookup_or_add):
Use statement pointer instead of vuse_optype. Use generic interface.
* tree-vrp.c (maybe_add_assert_expr): Use generic interface.
(stmt_interesting_for_vrp, vrp_visit_stmt): Use ZERO_SSA_OPERANDS.
* tree.h (struct ssa_imm_use_d): Renamed to ssa_use_operand_d.
(tree_ssa_name, phi_arg_d): Use ssa_use_operand_d.
* doc/tree-ssa.texi: Update documentation for operand interface.
From-SVN: r99155
|
|
exposed symbols.
Merge from tree-cleanup-branch: VRP, store CCP, store
copy-prop, incremental SSA updating of FUD chains and
newly exposed symbols.
* Makefile.in (tree-ssa-copy.o): Depend on tree-ssa-propagate.h.
(OBJS-common): Add tree-vrp.o.
(tree-vrp.o): New rule.
* basic-block.h (nearest_common_dominator_for_set): Declare.
* common.opt (ftree-store-ccp): New flag.
(ftree-copy-prop): New flag.
(ftree-vrp): New flag.
(ftree-store-copy-prop): New flag.
* dominance.c (nearest_common_dominator_for_set): New.
* domwalk.c (walk_dominator_tree): Only traverse
statements in blocks marked in walk_data->interesting_blocks.
* domwalk.h (struct dom_walk_data): Add field interesting_blocks.
* fold-const.c (fold): Handle ASSERT_EXPR.
* opts.c (decode_options): Set flag_tree_copy_prop at -O1.
Set flag_tree_store_ccp, flag_tree_store_copy_prop and
flag_tree_vrp at -O2.
* timevar.def (TV_TREE_VRP): Define.
(TV_TREE_COPY_PROP): Define.
(TV_TREE_STORE_COPY_PROP): Define.
(TV_TREE_SSA_INCREMENTAL): Define.
(TV_TREE_STORE_CCP): Define.
* tree-cfg.c (tree_can_merge_blocks_p): Remove reference
to kill_redundant_phi_nodes from comment.
(verify_expr): Handle ASSERT_EXPR.
* tree-dfa.c (mark_new_vars_to_rename): Remove second
argument. Update all users.
(mark_call_clobbered_vars_to_rename): Remove. Update all
users.
* tree-flow-inline.h (unmodifiable_var_p): New.
* tree-flow.h (enum value_range_type): Declare.
(struct value_range_def): Declare.
(value_range): Declare.
(remove_all_phi_nodes_for): Remove. Update all users.
(find_phi_node_for): Declare.
(add_type_alias): Declare.
(count_uses_and_derefs): Declare.
(kill_redundant_phi_nodes): Remove.
(rewrite_into_ssa): Remove.
(rewrite_def_def_chains): Remove.
(update_ssa, register_new_name_mapping, create_new_def_for,
need_ssa_update_p, name_registered_for_update_p,
release_ssa_name_after_update_ssa, dump_repl_tbl,
debug_repl_tbl, dump_names_replaced_by,
debug_names_replaced_by, mark_sym_for_renaming,
mark_set_for_renaming, get_current_def, set_current_def,
get_value_range, dump_value_range, debug_value_range,
dump_all_value_ranges, debug_all_value_ranges,
expr_computes_nonzero, loop_depth_of_name,
unmodifiable_var_p): Declare.
* tree-gimple.c (is_gimple_formal_tmp_rhs): Handle
ASSERT_EXPR.
* tree-into-ssa.c (block_defs_stack): Update comment.
(old_ssa_names, new_ssa_names, old_virtual_ssa_names,
syms_to_rename, names_to_release, repl_tbl,
need_to_initialize_update_ssa_p, need_to_update_vops_p,
need_to_replace_names_p): New locals.
(NAME_SETS_GROWTH_FACTOR): Define.
(struct repl_map_d): Declare.
(struct mark_def_sites_global_data): Add field
interesting_blocks.
(enum rewrite_mode): Declare.
(REGISTER_DEFS_IN_THIS_STMT): Define.
(compute_global_livein): Use last_basic_block instead of
n_basic_blocks.
(set_def_block): Remove last argument. Update all callers.
(prepare_use_operand_for_rename): Remove. Update all callers.
(prepare_def_operand_for_rename): Remove. Update all callers.
(symbol_marked_for_renaming): New.
(is_old_name): New.
(is_new_name): New.
(repl_map_hash): New.
(repl_map_eq): New.
(repl_map_free): New.
(names_replaced_by): New.
(add_to_repl_tbl): New.
(add_new_name_mapping): New.
(mark_def_sites): Assume that all the operands in the
statement are in normal form.
(find_idf): Assert that the block in the stack is valid.
(get_default_def_for): New.
(insert_phi_nodes_for): Add new argument 'update_p'.
Add documentation.
If update_p is true, add a new mapping between the LHS of
each new PHI and the name that it replaces.
(insert_phi_nodes_1): Only call find_idf if needed.
(get_reaching_def): Call get_default_def_for.
(rewrite_operand): Remove.
(rewrite_stmt): Do nothing if REGISTER_DEFS_IN_THIS_STMT
and REWRITE_THIS_STMT are false.
Assume that all the operands in the statement are in
normal form.
(rewrite_add_phi_arguments): Don't use PHI_REWRITTEN.
(rewrite_virtual_phi_arguments): Remove.
(invalidate_name_tags): Remove.
(register_new_update_single, register_new_update_set,
rewrite_update_init_block, replace_use,
rewrite_update_fini_block, rewrite_update_stmt,
rewrite_update_phi_arguments): New.
rewrite_blocks): Remove argument 'fix_virtual_phis'.
Add arguments 'entry', 'what' and 'blocks'.
Initialize the dominator walker according to 'what' and
'blocks'.
Start the dominator walk at 'entry'.
(mark_def_site_blocks): Add argument 'interesting_blocks'.
Use it to configure the dominator walker.
(rewrite_into_ssa): Remove argument 'all'.
Make internal.
(rewrite_all_into_ssa): Remove.
(rewrite_def_def_chains): Remove.
(mark_def_interesting, mark_use_interesting,
prepare_phi_args_for_update, prepare_block_for_update,
prepare_def_site_for, prepare_def_sites,
dump_names_replaced_by, debug_names_replaced_by,
dump_repl_tbl, debug_repl_tbl, init_update_ssa,
delete_update_ssa, create_new_def_for,
register_new_name_mapping, mark_sym_for_renaming,
mark_set_for_renaming, need_ssa_update_p,
name_registered_for_update_p, ssa_names_to_replace,
release_ssa_name_after_update_ssa,
insert_updated_phi_nodes_for, update_ssa): New.
* tree-loop-linear.c (linear_transform_loops): Call
update_ssa instead of rewrite_into_ssa.
* tree-optimize.c (vars_to_rename): Remove.
Update all users.
(init_tree_optimization_passes): Replace
pass_redundant_phi with pass_copy_prop.
Add pass_vrp.
Replace pass_ccp with pass_store_ccp.
Add pass_store_copy_prop after pass_store_ccp.
(execute_todo): If the TODO_ flags don't include updating
the SSA form, assert that it does not need to be updated.
Call update_ssa instead of rewrite_into_ssa and
rewrite_def_def_chains.
If TODO_verify_loops is set, call verify_loop_closed_ssa.
(tree_rest_of_compilation):
* tree-pass.h (TODO_dump_func, TODO_ggc_collect,
TODO_verify_ssa, TODO_verify_flow, TODO_verify_stmts,
TODO_cleanup_cfg): Renumber.
(TODO_verify_loops, TODO_update_ssa,
TODO_update_ssa_no_phi, TODO_update_ssa_full_phi,
TODO_update_ssa_only_virtuals): Define.
(pass_copy_prop, pass_store_ccp, pass_store_copy_prop, pass_vrp):
Declare.
* tree-phinodes.c (make_phi_node): Update documentation.
(remove_all_phi_nodes_for): Remove.
(find_phi_node_for): New.
* tree-pretty-print.c (dump_generic_node): Handle ASSERT_EXPR.
* tree-scalar-evolution.c (follow_ssa_edge_in_rhs): Likewise.
(interpret_rhs_modify_expr): Likewise.
* tree-sra.c (decide_instantiations): Mark all symbols in
SRA_CANDIDATES for renaming.
(mark_all_v_defs_1): Rename from mark_all_v_defs.
(mark_all_v_defs): New function. Update all users to call it
with the whole list of scalarized statements, not just the
first one.
* tree-ssa-alias.c (count_ptr_derefs): Make extern.
(compute_flow_insensitive_aliasing): If the tag is
unmodifiable and the variable isn't or vice-versa, don't
make them alias of each other.
(setup_pointers_and_addressables): If the type tag for
VAR is about to change, mark the old one for renaming.
(add_type_alias): New.
* tree-ssa-ccp.c: Document SSA-CCP and STORE-CCP.
(ccp_lattice_t): Rename from latticevalue.
(value): Remove. Update all users.
(const_val): New local variable.
(do_store_ccp): New local variable.
(dump_lattice_value): Handle UNINITIALIZED.
(debug_lattice_value): New.
(get_default_value): Re-write.
(set_lattice_value): Re-write.
(def_to_varying): Remove. Update all users.
(likely_value): Return VARYING for statements that make
stores when STORE_CCP is false.
Return VARYING for any statement other than MODIFY_EXPR,
COND_EXPR and SWITCH_EXPR.
(ccp_initialize): Re-write.
(replace_uses_in, replace_vuse_in, substitute_and_fold):
Move to tree-ssa-propagate.c.
(ccp_lattice_meet): Handle memory stores when
DO_STORE_CCP is true.
(ccp_visit_phi_node): Likewise.
(ccp_fold): Likewise.
(evaluate_stmt): Likewise.
(visit_assignment): Likewise.
(ccp_visit_stmt): Likewise.
(execute_ssa_ccp): Add argument 'store_ccp'. Copy it
into DO_STORE_CCP.
(do_ssa_ccp): New.
(pass_ccp): Use it.
(do_ssa_store_ccp): New.
(gate_store_ccp): New.
(pass_store_ccp): Declare.
* tree-ssa-copy.c: Include tree-ssa-propagate.h.
(may_propagate_copy): Reformat.
Don't abort if ORIG is a virtual and DEST isn't.
If NEW does not have alias information but DEST does,
copy it.
(copy_of, cached_last_copy_of, do_store_copy_prop, enum
copy_prop_kind, which_copy_prop): Declare.
(stmt_may_generate_copy, get_copy_of_val,
get_last_copy_of, set_copy_of_val, dump_copy_of,
copy_prop_visit_assignment, copy_prop_visit_cond_stmt,
copy_prop_visit_stmt, copy_prop_visit_phi_node,
init_copy_prop, fini_copy_prop, execute_copy_prop,
gate_copy_prop, do_copy_prop, gate_store_copy_prop,
store_copy_prop): New.
(pass_copy_prop, pass_store_copy_prop): Declare.
* tree-ssa-dom.c (struct opt_stats_d): Add fields
'num_const_prop' and 'num_copy_prop'.
(cprop_operand): Update them.
(dump_dominator_optimization_stats): Dump them.
(tree_ssa_dominator_optimize): Call update_ssa instead of
rewrite_into_ssa.
(loop_depth_of_name): Declare extern.
(simplify_cond_and_lookup_avail_expr): Guard against NULL
values for LOW or HIGH.
(cprop_into_successor_phis): Only propagate if NEW != ORIG.
(record_equivalences_from_stmt): Call expr_computes_nonzero.
(cprop_operand): Only propagate if VAL != OP.
* tree-ssa-dse.c (dse_optimize_stmt): Mark symbols in removed
statement for renaming.
* tree-ssa-loop-im.c (move_computations): Call update_ssa.
* tree-ssa-loop-ivopts.c (rewrite_address_base): Call
add_type_alias if necessary.
Call mark_new_vars_to_rename.
(tree_ssa_iv_optimize): If new symbols need to be renamed,
mark every statement updated, call update_ssa and
rewrite_into_loop_closed_ssa.
* tree-ssa-loop-manip.c (add_exit_phis): Do not remove DEF_BB
from LIVEIN if VAR is a virtual.
* tree-ssa-loop.c (tree_loop_optimizer_init): Call update_ssa.
* tree-ssa-operands.c (get_expr_operands): Handle ASSERT_EXPR.
(get_call_expr_operands): Reformat statement.
(add_stmt_operand): Don't create V_MAY_DEFs for read-only
symbols.
* tree-ssa-propagate.c (ssa_prop_init): Initialize
SSA_NAME_VALUE for every name.
(first_vdef, stmt_makes_single_load, stmt_makes_single_store,
get_value_loaded_by): New.
(replace_uses_in, replace_vuses_in, replace_phi_args_in,
substitute_and_fold): Move from tree-ssa-ccp.c.
* tree-ssa-propagate.h (struct prop_value_d, prop_value_t,
first_vdef, stmt_makes_single_load, stmt_makes_single_store,
get_value_loaded_by, replace_uses_in, substitute_and_fold):
Declare.
* tree-ssa.c (verify_use): Fix error message.
(propagate_into_addr, replace_immediate_uses, get_eq_name,
check_phi_redundancy, kill_redundant_phi_nodes,
pass_redundant_phi): Remove. Update all users.
* tree-vect-transform.c (vect_create_data_ref_ptr): Call
add_type_alias, if necessary.
* tree-vectorizer.h (struct _stmt_vect_info): Update
documentation for field 'memtag'.
* tree-vrp.c: New file.
* tree.def (ASSERT_EXPR): Define.
* tree.h (ASSERT_EXPR_VAR): Define.
(ASSERT_EXPR_COND): Define.
(SSA_NAME_VALUE_RANGE): Define.
(struct tree_ssa_name): Add field 'value_range'.
(PHI_REWRITTEN): Remove.
(struct tree_phi_node): Remove field 'rewritten'.
* doc/invoke.texi (-fdump-tree-storeccp, -ftree-copy-prop,
-ftree-store-copy-prop): Document.
* doc/tree-ssa.texi: Remove broken link to McCAT's compiler.
Document usage of update_ssa.
testsuite/ChangeLog
* g++.dg/tree-ssa/pr18178.C: New test.
* gcc.c-torture/execute/20030216-1.x: Ignore at -O1.
* gcc.c-torture/execute/20041019-1.c: New test.
* gcc.dg/tree-ssa/20041008-1.c: New test.
* gcc.dg/tree-ssa/ssa-ccp-12.c: New test.
* gcc.dg/tree-ssa/20030731-2.c: Update to use -fdump-tree-store_ccp.
* gcc.dg/tree-ssa/20030917-1.c: Likewise.
* gcc.dg/tree-ssa/20030917-3.c: Likewise.
* gcc.dg/tree-ssa/20040721-1.c: Likewise.
* gcc.dg/tree-ssa/ssa-ccp-1.c: Likewise.
* gcc.dg/tree-ssa/ssa-ccp-2.c: Likewise.
* gcc.dg/tree-ssa/ssa-ccp-3.c: Likewise.
* gcc.dg/tree-ssa/ssa-ccp-7.c: Likewise.
* gcc.dg/tree-ssa/ssa-ccp-9.c: Likewise.
From-SVN: r97884
|
|
2005-04-05 Andrew MacLeod <amacleod@redhat.com>
* lambda-code.c (lambda_loopnest_to_gcc_loopnest): Use update_stmt.
Use immediate use iterator.
(stmt_is_bumper_for_loop): Use immediate use iterator.
* predict.c (strip_builtin_expect): Use update_stmt.
* tree-cfg.c (update_modified_stmts): New. Call update_stmt_if_modified
on all elements of a STATEMENT_LIST.
(bsi_insert_before, bsi_insert_after): Call update_modified_stmts.
(bsi_remove): Remove imm_use links and mark the stmt as modified.
(bsi_replace): Mark stmt as modified and the update it.
* tree-complex.c (update_complex_assignment): Call mark_stmt_modified.
(expand_complex_libcal): Call update_stmt.
(expand_complex_comparison): Call mark_stmt_modified.
(expand_complex_operations_1): Call update_stmt_if_modified.
(expand_vector_operations_1): Call mark_stmt_modified.
* tree-dfa.c (compute_immediate_uses, free_df_for_stmt, free_df,
compute_immediate_uses_for_phi, compute_immediate_uses_for_stmt,
add_immediate_use, redirect_immediate_use,
redirect_immediate_uses, dump_immediate_uses, debug_immediate_uses,
dump_immediate_uses_for, debug_immediate_uses_for): Delete.
(mark_new_vars_to_rename): Call update_stmt.
* tree-dump.c (dump_option_value_in): Add "stmtaddr".
* tree-flow-inline.h (modify_stmt): Rename to mark_stmt_modified.
Ignore PHI nodes.
(unmodify_stmt): Delete.
(update_stmt): New. Force an update of a stmt.
(update_stmt_if_modified): update a stmt if it is out of date.
(get_stmt_operands): Verify stmt is NOT modified.
(stmt_modified_p): Update comment.
(delink_imm_use): Remove a use node from its immuse list.
(link_imm_use_to_list): Link a use node to a specific list.
(link_imm_use): Link a node to the correct list.
(set_ssa_use_from_ptr): Set a use node to a specific value, and insert
it in the correct list, if appropriate.
(link_imm_use_stmt): Link a use node, and set the stmt pointer.
(relink_imm_use): Link a use node in place of another node in a list.
(relink_imm_use_stmt): LInk a node in place of another node, and set
the stmt pointer.
(end_safe_imm_use_traverse): New. Terminate a safe immuse iterator.
(end_safe_imm_use_p): New. Check for the end of a safe immuse iterator.
(first_safe_imm_use): New. Initialize a safe immuse iterator.
(next_safe_imm_use): New. Proceed to next safe immuse iterator value.
(end_readonly_imm_use_p): New. Check for end of a fast immuse iterator.
(first_readonly_imm_use): New. Initialize a fast immuse iterator.
(next_readonly_imm_use): New. Get the next fast immuse iterator value.
(has_zero_uses): New. Return true if there are no uses of a var.
(has_single_use): New. Return true if there is only a single use of a
variable.
(single_imm_use): New. Return the simgle immediate use.
(num_imm_uses): New. Return the number of immediate uses.
(get_v_must_def_ops): Use is now a pointer.
(use_operand_p, get_v_may_def_op_ptr, get_vuse_op_ptr,
get_v_must_def_kill_ptr, get_phi_arg_def_ptr): Return the address of
the use node.
(get_immediate_uses, num_immediate_uses, immediate_use): Delete.
(delink_stmt_imm_use): Delink all immuses from a stmt.
(phi_arg_index_from_use): New. Return a phi arg index for a use.
* tree-flow.h (struct dataflow_d): Delete.
(immediate_use_iterator_d): New. Immediate use iterator struct.
(FOR_EACH_IMM_USE_FAST): New. Macro for read only immuse iteration.
(FOR_EACH_IMM_USE_SAFE): New. Macro for write-safe immuse iteration.
(BREAK_FROM_SAFE_IMM_USE): New. Macro for earlyu exit from write-safe
iteration.
(struct stmt_ann_d): Remove dataflow_t from struct.
* tree-if-conv.c (tree_if_conversion). Don't call free_df.
(if_convertible_phi_p): Use FAST immuse iterator.
(if_convertible_loop_p): Don't call compute_immediate_uses.
(replace_phi_with_cond_modify_expr): Call update_stmt.
* tree-into-ssa.c (mark_def_sites, ssa_mark_def_sites): Call
update_stmt_if_modified.
(rewrite_all_into_ssa): Initialize ssa operands.
* tree-loop-linear.c (linear_transform_loops): Don't call free_df or
compute_immediate_uses.
* tree-optimize.c (execute_todo): Call verify_ssa whenever the
ssa_property is available.
(execute_one_pass): Change parameters passed to execute_todo.
* tree-outof-ssa.c (rewrite_trees): Don't call modify_stmt.
(remove_ssa_form): Call fini_ssa_operands.
(insert_backedge_copies): Delete call to modify_stmt.
* tree-phinodes.c (make_phi_node): Initialize use nodes.
(release_phi_node): Delink any use nodes before releasing.
(resize_phi_node): Relink any use nodes.
(remove_phi_arg_num): Delink the use node.
(remove_phi_node): Release the ssa_name AFTER releasing the phi node.
(remove_all_phi_nodes_for): Release phi node first.
* tree-pretty-print.c (dump_generic_node): Print stmt address.
* tree-sra.c (mark_all_v_defs): Call update_stmt_if_modified.
(scalarize_use, scalarize_copy): Call update_stmt.
* tree-ssa-alias.c (compute_may_aliases): Update all modified stmts.
(compute_points_to_and_addr_escape): Call mark_stmt_modified.
* tree-ssa-cpp.c (need_imm_uses_for): Delete.
(ccp_initialize): Remove call to compute_immediate_uses.
(substitute_and_fold, execute_fold_all_builtins): Call update_stmt.
* tree-ssa-dom.c (tree_ssa_dominator_optimize): Update all modified
stmts.
(simplify_cond_and_lookup_avail_expr): Call mark_stmt_modified.
(simplify_switch_and_lookup_avail_expr): Call mark_stmt_modified.
(eliminate_redundant_computations): Call mark_stmt_modified.
(cprop_operand): Call mark_stmt_modified.
(optimize_stmt): Call update_stmt_if_modified and mark_stmt_modified.
* tree-ssa-dse.c (fix_phi_uses, fix_stmt_v_may_defs): Delete.
(dse_optimize_stmt): Use new immuse interface.
(tree_ssa_dse): Remove calls to compute_immediate_uses and free_df.
* tree-ssa-forwprop.c (need_imm_uses_for): Delete.
(substitute_single_use_vars): Use new immuse interface.
(tree_ssa_forward_propagate_single_use_vars): Remove calls to free_df
and compute_immediate_uses.
* tree-ssa-loop-im.c (single_reachable_address): Use new immuse
interface.
(rewrite_mem_refs): Call update_stmt.
(determine_lsm): Remove call to compute_imm_uses and free_df.
* tree-ssa-loop-ivcanon.c (create_canonical_iv): Call update_stmt.
(try_unroll_loop_completely): Call update_stmt.
* tree-ssa-loop-ivopts.c (rewrite_address_base): Call update_stmt.
(rewrite_use_compare): Call update_stmt.
(compute_phi_arg_on_exit): Insert each stmt before trying to process.
(rewrite_use) : Call update_stmt.
* tree-ssa-loop-manip.c (verify_loop_closed_ssa): Add arg to call.
* tree-ssa-loop-unswitch.c (tree_unswitch_single_loop): Call
update_stmt.
* tree-ssa-operands.c (NULL_USE_OPERAND_P): Remove declaration.
(allocate_use_optype, allocate_vuse_optype): Adjust allocation size.
(free_uses, free_vuses, free_v_may_defs, free_v_must_defs): Delink
use nodes.
(initialize_vuse_operand): New. Initialize a vuse operand.
(initialize_v_may_def_operand): New. Initialize a maydef operand.
(initialize_v_must_def_operand): New. Initialize a mustdef operand.
(finalize_ssa_defs): Use stmt parameter.
(correct_use_link): Ensure a use node is in the correct list, and has
the correct stmt pointer.
(finalize_ssa_uses, finalize_ssa_v_may_defs, finalize_ssa_vuses,
finalize_ssa_v_must_defs): Also initialize use nodes.
(finalize_ssa_stmt_operands): Pass extra stmt operands.
(build_ssa_operands): Seperate parsing from final operand construction.
(parse_ssa_operands): New. Parse entry point for operand building.
(swap_tree_operands): New. Swap 2 tree operands.
(update_stmt_operands): Ranamed from get_stmt_operands. Always builds
operands.
(get_expr_operands): Call swap_tree_operands when needed.
(copy_virtual_operands): Use initialize routines for virtual use ops.
(create_ssa_artficial_load_stmt): Add extra stmt parameter.
(verify_abort): New. Issue imm_use error.
(verify_imm_links): New Verify imm_use links for a var.
(dump_immediate_uses_for): New. Dump imm_uses for a var to file.
(dump_immediate_uses): New. Dump imm_uses for all vars to file.
(debug_immediate_uses): New. Dump imm_uses for all vars to stderr.
(debug_immediate_uses_for): New. Dump imm_uses for a var to stderr.
* tree-ssa-operands.h (struct use_operand_ptr): Delete.
(NULL_USE_OPERAND_P) Define.
(use_optype_d, v_def_use_operand_type, vuse_optype_d): Add immediate
use node.
(struct vuse_operand_type): New struct.
(SET_USE): Call set_ssa_use_from_ptr.
(USE_STMT): Define.
(PHI_ARG_INDEX_FROM_USE): Define.
* tree-ssa-phiopt.c (replace_phi_edge_with_variable): Set the phi
argument via SET_USE, not PHI_ARG_DEF_TREE.
* tree-ssa-pre.c (eliminate): Call update_stmt.
* tree-ssa-propagate.c (cfg_blocks_get): Use imm_use iterators. Don't
call free_df.
* tree-ssa-sink.c (all_immediate_uses_same_place): Use imm_use iterator.
(nearest_common_dominator_of_uses): Use imm_use iterator.
(statement_sink_location): Use imm_use iterator and interface.
(execute_sink_code): Don't call compute_immediate_uses or free-df.
* tree-ssa-threadupdate.c (create_edge_and_update_destination_phis): Use
PHI_ARG_DEF, not PHI_ARG_DEF_TREE.
* tree-ssa.c (verify_use, verify_phi_args): Verify some imm_use info.
(verify_ssa): Ensure no stmt is marked modify after optimization pass
if new parameter is true.
(init_tree_ssa): Don't initialize operand cache here.
(delete_tree_ssa): Don't destroy operand cache here.
(propagate_into_addr): Pass in a use pointer, return true if anything
was changed.
(replace_immediate_uses): Use imm_use iterator, call update_stmt.
(check_phi_redundancy): Use imm_use iterator.
(kill_redundant_phi_nodes): Don't call compute_immediate_uses or
free_df.
* tree-ssanames.c (make_ssa_name): Initialize imm_use node.
(release_ssa_name): Delink node and all elements in its imm_use list.
* tree-tailcall.c (adjust_return_value): Call update_stmt.
* tree-vect-analyze.c (vect_stmt_relevant_p): Use imm_use iterator.
* tree-vectorizer.c (need_imm_uses_for): Delete.
(vectorize_loops): Dont call compute_immediate_uses or free_df.
* tree.h (struct ssa_imm_use_d): Define.
(SSA_NAME_IMM_USE_NODE): Define.
(struct tree_ssa_name): Add imm_use node.
(PHI_DF): Delete.
(PHI_ARG_IMM_USE_NODE): Define.
(struct phi_arg_d): Add imm_use node.
(struct tree_phi_node): Remove struct dataflow_d element.
(TDF_STMTADDR): Define.
From-SVN: r97648
|
|
* tree-sra.c (decide_block_copy): Disable scalarization of sub-elements.
* g++.dg/tree-sra/ssa-sra-3.C: New test.
From-SVN: r97301
|
|
PR tree-opt/19108
* tree-sra.c (generate_element_init_1): Handle RANGE_EXPR.
From-SVN: r97211
|
|
From-SVN: r96187
|
|
PR tree-opt/20127
* tree-sra.c (instantiate_element): Copy TREE_THIS_VOLATILE from
the type.
From-SVN: r95530
|
|
* bitmap.h (BITMAP_XMALLOC, BITMAP_XFREE): Remove.
* bb-reorder.c (duplicate_computed_gotos): Use BITMAP_ALLOC and
BITMAP_FREE.
* bt-load.c (btr_def_live_range, combine_btr_defs,
migrate_btr_def, migrate_btr_defs): Likewise.
* cfgcleanup.c (thread_jump): Likewise.
* cfgloop.c (get_loop_body_in_bfs_order): Likewise.
* df.c (df_insn_table_realloc, df_bitmaps_alloc, df_bitmaps_free,
df_alloc, df_free, df_du_chain_create, df_bb_rd_local_compute,
df_rd_local_compute, df_reg_info_compute): Likewise.
* dominance.c (init_dom_info, free_dom_info): Likewise.
* flow.c (init_propagate_block_info,
free_propagate_block_info): Likewise.
* gcse.c (alloc_gcse_mem, free_gcse_mem): Likewise.
* global.c (allocate_bb_info, free_bb_info, calculate_reg_pav,
modify_reg_pav): Likewise.
* loop-invariant.c (find_defs, find_invariant_insn,
find_invariants, free_inv_motion_data): Likewise.
* predict.c (tree_predict_by_opcode,
estimate_bb_frequencies): Likewise.
* stmt.c (expand_case): Likewise.
* tree-cfg.c (tree_duplicate_sese_region): Likewise.
* tree-dfa.c (mark_new_vars_to_rename): Likewise.
* tree-if-conv.c (get_loop_body_in_if_conv_order): Likewise.
* tree-into-ssa.c (insert_phi_nodes_for, def_blocks_free,
get_def_blocks_for, mark_def_site_blocks, rewrite_into_ssa,
rewrite_ssa_into_ssa): Likewise.
* tree-optimize.c (tree_rest_of_compilation): Likewise.
* tree-outof-ssa.c (new_temp_expr_table, free_temp_expr_table,
analyze_edges_for_bb, perform_edge_inserts): Likewise.
* tree-scalar-evolution.c (scev_initialize, scev_finalize): Likewise.
* tree-sra.c (tree_sra): Likewise.
* tree-ssa-alias.c (init_alias_info, delete_alias_info): Likewise.
* tree-ssa-ccp.c (ccp_fold_builtin): Likewise.
* tree-ssa-dce.c (tree_dce_init, tree_dce_done): Likewise.
* tree-ssa-dom.c (tree_ssa_dominator_optimize): Likewise.
* tree-ssa-dse.c (tree_ssa_dse): Likewise.
* tree-ssa-forwprop.c (tree_ssa_forward_propagate_single_use_var):
Likewise.
* tree-ssa-live.c (new_tree_live_info, delete_tree_live_info,
calculate_live_on_entry, calculate_live_on_exit,
build_tree_conflict_graph): Likewise.
* tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_init, record_use,
record_important_candidates, set_use_iv_cost, find_depends,
determine_use_iv_costs, iv_ca_new, iv_ca_free, free_loop_data,
tree_ssa_iv_optimize_finalize): Likewise.
* tree-ssa-loop-manip.c (add_exit_phis_var, get_loops_exit,
find_uses_to_rename_use, rewrite_into_loop_closed_ssa,
tree_duplicate_loop_to_header_edge): Likewise.
* tree-ssa-pre.c (init_pre, fini_pre): Likewise.
* tree-ssa.c (verify_flow_insensitive_alias_info,
verify_name_tags, verify_ssa, init_tree_ssa,
delete_tree_ssa): Likewise.
* tree-ssanames.c (marked_ssa_names, init_ssanames,
fini_ssanames): Likewise.
* tree-vectorizer.c (slpeel_tree_peel_loop_to_edge): Likewise.
From-SVN: r95172
|
|
used uninitialized)
PR tree-opt/14329
* tree.h (struct tree_decl): Add debug_expr_is_from.
(DECL_DEBUG_EXPR_IS_FROM): New.
(DECL_DEBUG_EXPR): Rename from DECL_DEBUG_ALIAS_OF.
* dwarf2out.c (dwarf2out_var_location): Update to match.
* tree-outof-ssa.c (create_temp): Likewise.
* var-tracking.c (track_expr_p): Likewise.
* tree-sra.c (instantiate_element): Set DECL_DEBUG_EXPR.
* c-objc-common.c (c_tree_printer) <'D'>: Handle DECL_DEBUG_EXPR.
* toplev.c (default_tree_printer): Likewise.
From-SVN: r94317
|
|
GNAT tools)
2005-01-04 Richard Henderson <rth@redhat.com>
PR tree-opt/19158
* tree-sra.c (generate_one_element_init): Just
call gimplify_and_add.
(generate_element_init): Record the
new referenced variables and mark them for renaming
and split out to ...
(generate_element_init_1): This.
(scalarize_init): Don't call push_gimplify_context/
pop_gimplify_context.
From-SVN: r92911
|
|
PR tree-opt/19042
* tree-sra.c (decide_block_copy): Force use_block_copy false
for complex values.
From-SVN: r92782
|
|
From-SVN: r92494
|
|
* tree-into-ssa.c (REWRITE_THIS_STMT): Define.
(mark_def_sites): Clear REWRITE_THIS_STMT for statements that
don't need any operands rewritten.
(rewrite_stmt): Ignore statements that don't need to be
rewritten.
(rewrite_operand): Validate that an existing SSA_NAME is
identical to the current reaching definition of the operand.
* tree-dfa.c (mark_call_clobbered_vars_to_rename): New function.
* tree-vectorizer.c (vectorizable_load): Call it.
* tree-flow.h (mark_call_clobbered_vars_to_rename): Declare.
* tree-sra.c (mark_all_v_defs): Also mark VUSEs for renaming.
From-SVN: r92010
|
|
From-SVN: r91193
|
|
2004-11-22 Andrew Pinski <pinskia@physics.uc.edu>
PR tree-opt/18572
* tree-sra.c (scalarize_init): Unshare the rhs before gimplifying
it.
From-SVN: r91024
|
|
* bitmap.h (struct bitmap_obstack): New obstack type.
(struct bitmap_head_def): Replace using_obstack with obstack
pointer.
(bitmap_default_obstack): New.
(bitmap_initialize): Make inline, does not do allocation.
(bitmap_release_memory): Remove.
(bitmap_obstack_initialize, bitmap_obstack_release): Declare.
(bitmap_obstack_alloc, bitmap_malloc_alloc, bitmap_gc_alloc,
bitmap_obstack_free, bitmap_malloc_free): Declare.
(BITMAP_OBSTACK_ALLOC, BITMAP_GGC_ALLOC, BITMAP_XMALLOC): Adjust.
(BITMAP_FREE): Replace with ...
(BITMAP_OBSTACK_FREE): ... this.
(BITMAP_XFREE): Adjust.
(BITMAP_INIT_ONCE): Remove.
* bitmap.c (bitmap_obstack, bitmap_obstack_init, bitmap_free: Remove.
(bitmap_default_obstack): New.
(bitmap_elem_to_freelist): Adjust.
(bitmap_element_allocate): Adjust. Break initialization into ...
(bitmap_obstack_initialize): ... here.
(bitmap_release_memory): Replace with ...
(bitmap_obstack_release): ... this.
(bitmap_obstack_alloc, bitmap_malloc_alloc, bitmap_gc_alloc,
bitmap_obstack_free, bitmap_malloc_free): New.
(bitmap_ior_and_compl, bitmap_ior_and_compl_into): Use
bitmap_initialize.
(bitmap_initialize): Move to bitmap.h.
* gengtype.c (open_base_files): Add obstack.h to ifiles.
* Makefile.in (BASIC_BLOCK_H, REGS_H): Add obstack.h.
* basic-block.h (INIT_REG_SET): Allocate from reg_obstack.
(INITIALIZE_REG_SET): Remove.
(FREE_REG_SET): Use BITMAP_OBSTACK_FREE.
(INIT_ONCE_REG_SET, MAX_REGNO_REG_SET): Remove.
(flow_obstack): Do not declare.
(reg_obstack): Declare.
* regs.h: Include obstack.h.
* tree-optimize.c (tree_rest_of_compilation): Initialize and
release bitmap obstack here.
* bb-reorder.c: #include regs, not basic-block.
(fix_crossing_conditional_branches): Allocate regsets from
reg_obstack.
* bt-load.c: Do not inlude bitmap.h, sbitmap.h, basic-block.h or
obstack.h.
* caller-save.c: Include regs.h earlier.
* cfg.c: Do not include basic-block.h or obstack.h.
(reg_obstack): Define.
* cfganal.c: Include obstack.h
* cfgcleanyp.c: Do not include basic-block.h. Include regs.h
earlier.
* cfglayout.c: Do not include obstack.h.
(flow_obstack): Remove declaration.
(cfg_layout_duplicate_bb): Use reg_obstack.
* cfgloop.c, cfgloopanal.c, cfgloopmanip.c: Include obstack.h.
* cfgrtl.c (rtl_split_block): Use reg_obstack.
(force_nonfallthru_and_redirect, rtl_split_edge): Likewise.
(safe_insert_insn_on_edge): Use OBSTACK_ALLOC_REG_SET, adjust.
(cfg_layout_split_edge): Use reg_obstack.
* cse.c: Include regs.h earlier.
* ddg.c: Do not include basic-block.h.
* dominance.c: Inlude obstack.h.
* flow.c (update_life_info): Use OBSTACK_ALLOC_REG_SET, adjust.
(calculate_global_regs_live): Likewise.
(allocate_bb_life_data): Use reg_obstack.
(init_propagate_block_info): Use OBSTACK_ALLOC_REGSET.
* global.c: Do not include basic-block.h.
(build_insn_chain): Use OBSTACK_ALLOC_REG_SET, adjust.
* graph.c: Include obstack.h.
* haifa-sched.c: Do not include basic-block.h.
* ifcvt.c: Use OBSTACK_ALLOC_REG_SET, adjust.
* local-alloc.c: Do not include basic-block.h.
* loop-init.c, loop-invariant.c: Include obstack.h.
* loop-iv.c: Likewise.
(simplify_using_initial_values): Use OBSTACK_ALLOC_REG_SET,
adjust.
* loop-unroll.c, loop-unswitch.c: Inlude obstack.h.
* modulo-sched.c: Do not include basic-block.h.
* passes.c (rest_of_handle_final): Do not call
regset_release_memory.
* ra-debug.c: Include regs.h earlier. Do not include
basic-block.h.
* recog.c (peephole2_optimize): Use OBSTACK_ALLOC_REG_SET, adjust.
* regclass.c (init_reg_sets): Do not call INIT_ONCE_REG_SET.
(allocate_reg_info): Do not call MAX_REGNO_REG_SET.
(regset_release_memory): Remove.
* resource.c: Do not include basic-block.h.
* rtlanal.c: Do not include basic-block.h.
* sbitmap.c: Include obstack.h.
* sched-deps.c: Do not include basic-block.h.
(reg_pending_sets_head, reg_pending_clobbers_head,
reg_pending_uses_head): Remove.
(init_deps_global): Use OBSTACK_ALLOC_REG_SET.
* sched-ebb.c: Do not include basic-block.h.
* sched-rgn.c: Likewise.
* tree-if-conv.c (get_loop_body_in_if_conv_order): Use
BITMAP_XFREE.
* tree-outof-ssa.c (perform_edge_inserts): Use BITMAP_XFREE.
* tree-sra.c (decide_instantiations): Adjust bitmap
initialization.
* tree-ssa-dce.c: Include obstack.h.
* tree-ssa-pre.c (grand_bitmap_obstack): Make a bitmap_obstack.
(value_insert_into_set_bitmap): Remove useless bitmap_clear.
(bitmap_set_new): Likewise.
(init_pre): Initialize bitmap obstack.
(fini_pre): Release bitmap obstack.
* tree-ssanames.c (ssa_names_to_rewrite): Make static.
(marked_for_rewrite_p): ssa_names_to_rewrite is never NULL.
(mark_for_rewrite, unmark_for_rewrite): Likewise.
(marked_ssa_names): Likewise.
(init_ssanames): Use BITMAP_XMALLOC.
(fini_ssanames): Use BITMAP_XFREE.
* web.c: Include obstack.h
From-SVN: r91009
|
|
* tree-cfg.c (bsi_commit_edge_inserts): Remove an argument.
(tree_flow_call_edges_add): Update the call to
bsi_commit_edge_inserts.
* lambda-code.c (lambda_loopnest_to_gcc_loopnest): Likewise.
* profile.c (branch_prob): Likewise.
* tree-mudflap.c (mf_decl_cache_locals): Likewise.
* tree-sra.c (scalarize_function): Likewise.
* tree-ssa-loop-im.c (loop_commit_inserts): Likewise.
* tree-ssa-pre.c (fini_pre): Likewise.
* tree-flow.h: Update the prototype for
bsi_commit_edge_inserts.
From-SVN: r90704
|
|
* c-cppbuiltin.c, cgraph.c, domwalk.h, except.c, gimplify.c,
lambda-code.c, postreload.c, predict.c, tree-sra.c,
tree-ssa-loop-manip.c, tree.c: Fix comment typos.
From-SVN: r90596
|
|
* bitmap.c (bitmap_print): Make bitno unsigned.
* bt-load.c (clear_btr_from_live_range,
btr_def_live_range): Likewise.
* caller-save.c (save_call_clobbered_regs): Likewise.
* cfganal.c (compute_dominance_frontiers_1): Likewise.
* cfgcleanup.c (thread_jump): Likewise.
* cfgrtl.c (safe_insert_insn_on_edge): Likewise.
* conflict.c (conflict_graph_compute): Likewise.
* ddg.c (add_deps_for_use): Likewise.
* df.c (df_refs_update): Likewise.
* except.c (remove_eh_handler): Likewise.
* flow.c (verify_local_live_at_start, update_life_info,
initialize_uninitialized_subregs, propagate_one_insn,
free_propagate_block_info, propagate_block, find_use_as_address,
reg_set_to_hard_reg_set): Likewise.
* gcse.c (clear_modify_mem_tables): Likewise.
* global.c (global_conflicts, build_insn_chain): Likewise.
* ifcvt.c (dead_or_predicable): Likewise.
* local-alloc.c (update_equiv_regs): Likewise.
* loop.c (load_mems): Likewise.
* ra-build.c (livethrough_conflicts_bb, conflicts_between_webs):
Likewise.
* ra-rewrite.c (reloads_to_loads, rewrite_program2, actual_spill):
Likewise.
* reload1.c (order_regs_for_reload, finish_spills): Likewise.
* sched-deps.c (sched_analyze_insn, free_deps): Likewise.
* sched-rgn.c (propagate_deps
* tree-cfg.c (tree_purge_all_dead_eh_edges): Likewise.
* tree-dfa.c (dump_dfa_stats
tree-into-ssa.c (compute_global_livein, insert_phi_nodes,
insert_phi_nodes_for, debug_def_blocks_r, invalidate_name_tags):
Likewise.
* tree-outof-ssa.c (coalesce_ssa_name, coalesce_vars,
free_temp_expr_table, find_replaceable_exprs): Likewise.
* tree-sra.c (scan_function, scalarize_parms): Likewise.
* tree-ssa-alias.c (init_alias_info,
compute_points_to_and_addr_escape,
compute_flow_sensitive_aliasing, maybe_create_global_var): Likewise.
* tree-ssa-dce.c (mark_control_dependent_edges_necessary): Likewise.
* tree-ssa-live.c (new_tree_live_info, live_worklist,
calculate_live_on_entry, calculate_live_on_exit, compare_pairs,
sort_coalesce_list, build_tree_conflict_graph, dump_live_info
tree-ssa-loop-manip.c (add_exit_phis_var): Likewise.
tree-ssa-operands.c (get_asm_expr_operands, add_call_clobber_ops,
add_call_read_ops): Likewise.
* tree-ssa-pre.c (bitmap_print_value_set, insert_aux): Likewise.
* tree-ssa-live.h (num_var_partitions): Return unsigned.
From-SVN: r90053
|
|
* bitmap.h (bitmap_empty_p): New.
(bitmap_and, bitmap_and_into, bitmap_and_compl,
bitmap_and_compl_into, bitmap_ior, bitmap_ior_into,
bitmap_ior_compl, bitmap_xor, bitmap_xor_into): New bitmap
operation macros.
(bitmap_ior_and_compl): Rename to ...
(bitmap_ior_and_compl_into): ... here.
* bitmap.c (bitmap_equal_p): Use bitmap_xor.
(bitmap_ior_and_compl): Rename to ...
(bitmap_ior_and_compl_into): ... here. Adjust. Return changed
flag.
(bitmap_union_of_diff): Use renamed bitmap functions.
* basic-block.h (AND_REG_SET, AND_COMPL_REG_SET, IOR_REG_SET,
XOR_REG_SET, IOR_AND_COMPL_REG_SET): Likewise.
* cfgrtl.c (safe_insert_insn_on_edge): Likewise.
* df.c (df_bb_rd_local_compute)
* flow.c (calculate_global_regs_live,
init_propagate_block_info): Likewise.
* ifcvt.c (find_if_case_1, find_if_case_2,
dead_or_predicable): Likewise.
* ra-build.c (union_web_part_roots, livethrough_conflicts_bb,
reset_conflicts, conflicts_between_webs): Likewise.
* ra-rewrite.c (reloads_to_loads, rewrite_program2,
detect_web_parts_to_rebuild): Likewise.
* sched-ebb.c (compute_jump_reg_dependencies): Likewise.
* tree-int-ssa.c (insert_phi_nodes_for, rewrite_into_ssa): Likewise.
* tree-sra.c (decide_instantiations): Likewise.
* tree-ssa-alias.c (create_name_tags,
merge_pointed_to_info): Likewise.
* tree-ssa-dom.c (tree_ssa_dominator_optimize): Likewise.
* tree-ssa-loop-im.c (move_computations): Likewise.
* tree-ssa-operands.c (get_call_expr_operands): Likewise.
* tree-ssa-pre.c (fini_pre): Likewise.
* tree-ssa.c (verify_flow_sensitive_alias_info): Likewise.
* tree-ssanames.c (any_marked_for_rewrite_p): Likewise.
* tree-vectorizer.c (vectorize_loops): Likewise.
From-SVN: r89827
|
|
* params.def (PARAM_SRA_MAX_STRUCTURE_SIZE): New.
(PARAM_SRA_FIELD_STRUCTURE_RATIO): Likewise.
* params.h (SRA_MAX_STRUCTURE_SIZE): New.
(SRA_FIELD_STRUCTURE_RATIO): Likewise.
* tree-sra.c: Include "params.h".
(decide_block_copy): Use new parameters.
* doc/invoke.texi (Optimize Options): Document new SRA pass
parameters sra-max-structure-size and sra-field-structure-ratio.
[testsuite]
* gcc.dg/tree-ssa/sra-1.c: Pass --param sra-max-structure-size.
From-SVN: r89711
|
|
From-SVN: r89356
|
|
2004-09-24 Ben Elliston <bje@au.ibm.com>
Steven Bosscher <stevenb@suse.de>
Andrew Pinski <pinskia@physics.uc.edu>
Merge from edge-vector-branch:
* basic-block.h: Include vec.h, errors.h. Instantiate a VEC(edge).
(struct edge_def): Remove pred_next, succ_next members.
(struct basic_block_def): Remove pred, succ members. Add preds
and succs members of type VEC(edge).
(FALLTHRU_EDGE): Redefine using EDGE_SUCC.
(BRANCH_EDGE): Likewise.
(EDGE_CRITICAL_P): Redefine using EDGE_COUNT.
(EDGE_COUNT, EDGE_I, EDGE_PRED, EDGE_SUCC): New.
(edge_iterator): New.
(ei_start, ei_last, ei_end_p, ei_one_before_end_p): New.
(ei_next, ei_prev, ei_edge, ei_safe_edge): Likewise.
(FOR_EACH_EDGE): New.
* bb-reorder.c (find_traces): Use FOR_EACH_EDGE and EDGE_* macros
where applicable.
(rotate_loop): Likewise.
(find_traces_1_route): Likewise.
(bb_to_key): Likewise.
(connect_traces): Likewise.
(copy_bb_p): Likewise.
(find_rarely_executed_basic_blocks_and_crossing_edges): Likewise.
(add_labels_and_missing_jumps): Likewise.
(fix_up_fall_thru_edges): Likewise.
(find_jump_block): Likewise.
(fix_crossing_conditional_branches): Likewise.
(fix_crossing_unconditional_branches): Likewise.
(add_reg_crossing_jump_notes): Likewise.
* bt-load.c (augment_live_range): Likewise.
* cfg.c (clear_edges): Likewise.
(unchecked_make_edge): Likewise.
(cached_make_edge): Likewise.
(make_single_succ_edge): Likewise.
(remove_edge): Likewise.
(redirect_edge_succ_nodup): Likewise.
(check_bb_profile): Likewise.
(dump_flow_info): Likewise.
(alloc_aux_for_edges): Likewise.
(clear_aux_for_edges): Likewise.
(dump_cfg_bb_info): Likewise.
* cfganal.c (forwarder_block_p): Likewise.
(can_fallthru): Likewise.
(could_fall_through): Likewise.
(mark_dfs_back_edges): Likewise.
(set_edge_can_fallthru_flag): Likewise.
(find_unreachable_blocks): Likewise.
(create_edge_list): Likewise.
(verify_edge_list): Likewise.
(add_noreturn_fake_exit_edges): Likewise.
(connect_infinite_loops_to_exit): Likewise.
(flow_reverse_top_sort_order_compute): Likewise.
(flow_depth_first_order_compute): Likewise.
(flow_preorder_transversal_compute): Likewise.
(flow_dfs_compute_reverse_execute): Likewise.
(dfs_enumerate_from): Likewise.
(compute_dominance_frontiers_1): Likewise.
* cfgbuild.c (make_edges): Likewise.
(compute_outgoing_frequencies): Likewise.
(find_many_sub_basic_blocks): Likewise.
(find_sub_basic_blocks): Likewise.
* cfgcleanup.c (try_simplify_condjump): Likewise.
(thread_jump): Likewise.
(try_forward_edges): Likewise.
(merge_blocks_move): Likewise.
(outgoing_edges_match): Likewise.
(try_crossjump_to_edge): Likewise.
(try_crossjump_bb): Likewise.
(try_optimize_cfg): Likewise.
(merge_seq_blocks): Likewise.
* cfgexpand.c (expand_gimple_tailcall): Likewise.
(expand_gimple_basic_block): Likewise.
(construct_init_block): Likewise.
(construct_exit_block): Likewise.
* cfghooks.c (verify_flow_info): Likewise.
(dump_bb): Likewise.
(delete_basic_block): Likewise.
(split_edge): Likewise.
(merge_blocks): Likewise.
(make_forwarder_block): Likewise.
(tidy_fallthru_edges): Likewise.
(can_duplicate_block_p): Likewise.
(duplicate_block): Likewise.
* cfglayout.c (fixup_reorder_chain): Likewise.
(fixup_fallthru_exit_predecessor): Likewise.
(can_copy_bbs_p): Likewise.
(copy_bbs): Likewise.
* cfgloop.c (flow_loops_cfg_dump): Likewise.
(flow_loop_entry_edges_find): Likewise.
(flow_loop_exit_edges_find): Likewise.
(flow_loop_nodes_find): Likewise.
(mark_single_exit_loops): Likewise.
(flow_loop_pre_header_scan): Likewise.
(flow_loop_pre_header_find): Likewise.
(update_latch_info): Likewise.
(canonicalize_loop_headers): Likewise.
(flow_loops_find): Likewise.
(get_loop_body_in_bfs_order): Likewise.
(get_loop_exit_edges): Likewise.
(num_loop_branches): Likewise.
(verify_loop_structure): Likewise.
(loop_latch_edge): Likewise.
(loop_preheader_edge): Likewise.
* cfgloopanal.c (mark_irreducible_loops): Likewise.
(expected_loop_iterations): Likewise.
* cfgloopmanip.c (remove_bbs): Likewise.
(fix_bb_placement): Likewise.
(fix_irreducible_loops): Likewise.
(remove_path): Likewise.
(scale_bbs_frequencies): Likewise.
(loopify): Likewise.
(unloop): Likewise.
(fix_loop_placement): Likewise.
(loop_delete_branch_edge): Likewise.
(duplicate_loop_to_header_edge): Likewise.
(mfb_keep_just): Likewise.
(create_preheader): Likewise.
(force_single_succ_latches): Likewise.
(loop_split_edge_with): Likewise.
(create_loop_notes): Likewise.
* cfgrtl.c (rtl_split_block): Likewise.
(rtl_merge_blocks): Likewise.
(rtl_can_merge_blocks): Likewise.
(try_redirect_by_replacing_jump): Likewise.
(force_nonfallthru_and_redirect): Likewise.
(rtl_tidy_fallthru_edge): Likewise.
(commit_one_edge_insertion): Likewise.
(commit_edge_insertions): Likewise.
(commit_edge_insertions_watch_calls): Likewise.
(rtl_verify_flow_info_1): Likewise.
(rtl_verify_flow_info): Likewise.
(purge_dead_edges): Likewise.
(cfg_layout_redirect_edge_and_branch): Likewise.
(cfg_layout_can_merge_blocks_p): Likewise.
(rtl_flow_call_edges_add): Likewise.
* cse.c (cse_cc_succs): Likewise.
* df.c (hybrid_search): Likewise.
* dominance.c (calc_dfs_tree_nonrec): Likewise.
(calc_dfs_tree): Likewise.
(calc_idoms): Likewise.
(recount_dominator): Likewise.
* domwalk.c (walk_dominator_tree): Likewise.
* except.c (emit_to_new_bb_before): Likewise.
(connect_post_landing_pads): Likewise.
(sjlj_emit_function_enter): Likewise.
(sjlj_emit_function_exit): Likewise.
(finish_eh_generation): Likewise.
* final.c (compute_alignments): Likewise.
* flow.c (calculate_global_regs_live): Likewise.
(initialize_uninitialized_subregs): Likewise.
(init_propagate_block_info): Likewise.
* function.c (thread_prologue_and_epilogue_insns): Likewise.
* gcse.c (find_implicit_sets): Likewise.
(bypass_block): Likewise.
(bypass_conditional_jumps): Likewise.
(compute_pre_data): Likewise.
(insert_insn_end_bb): Likewise.
(insert_store): Likewise.
(remove_reachable_equiv_notes): Likewise.
* global.c (global_conflicts): Likewise.
(calculate_reg_pav): Likewise.
* graph.c (print_rtl_graph_with_bb): Likewise.
* ifcvt.c (mark_loop_exit_edges): Likewise.
(merge_if_block): Likewise.
(find_if_header): Likewise.
(block_jumps_and_fallthru_p): Likewise.
(find_if_block): Likewise.
(find_cond_trap): Likewise.
(block_has_only_trap): Likewise.
(find_if_case1): Likewise.
(find_if_case_2): Likewise.
* lambda-code.c (lambda_loopnest_to_gcc_loopnest): Likewise.
(perfect_nestify): Likewise.
* lcm.c (compute_antinout_edge): Likewise.
(compute_laterin): Likewise.
(compute_available): Likewise.
(compute_nearerout): Likewise.
* loop-doloop.c (doloop_modify): Likewise.
* loop-init.c (loop_optimizer_init): Likewise.
* loop-invariant.c (find_exits): Likewise.
* loop-iv.c (simplify_using_initial_values): Likewise.
(check_simple_exit): Likewise.
(find_simple_exit): Likewise.
* loop-unroll.c (peel_loop_completely): Likewise.
(unroll_loop_constant_iterations): Likewise.
(unroll_loop_runtime_iterations): Likewise.
* loop-unswitch.c (may_unswitch_on): Likewise.
(unswitch_loop): Likewise.
* modulo-sched.c (generate_prolog_epilog): Likewise.
(sms_schedule): Likewise.
* postreload-gcse.c (eliminate_partially_redundant_load):
Likewise.
* predict.c (can_predict_insn_p): Likewise.
(set_even_probabilities): Likewise.
(combine_predictions_for_bb): Likewise.
(predict_loops): Likewise.
(estimate_probability): Likewise.
(tree_predict_by_opcode): Likewise.
(tree_estimate_probability): Likewise.
(last_basic_block_p): Likewise.
(propagate_freq): Likewise.
(estimate_loops_at_level): Likewise.
(estimate_bb_frequencies): Likewise.
* profile.c (instrument_edges): Likewise.
(get_exec_counts): Likewise.
(compute_branch_probabilities): Likewise.
(branch_prob): Likewise.
* ra-build.c (live_in): Likewise.
* ra-rewrite.c (rewrite_program2): Likewise.
* ra.c (reg_alloc): Likewise.
* reg-stack.c (reg_to_stack): Likewise.
(convert_regs_entry): Likewise.
(compensate_edge): Likewise.
(convert_regs_1): Likewise,
(convert_regs_2): Likewise.
(convert_regs): Likewise.
* regrename.c (copyprop_hardreg_forward): Likewise.
* reload1.c (fixup_abnormal_edges): Likewise.
* sbitmap.c (sbitmap_intersection_of_succs): Likewise.
(sbitmap_insersection_of_preds): Likewise.
(sbitmap_union_of_succs): Likewise.
(sbitmap_union_of_preds): Likewise.
* sched-ebb.c (compute_jump_reg_dependencies): Likewise.
(fix_basic_block_boundaries): Likewise.
(sched_ebbs): Likewise.
* sched-rgn.c (build_control_flow): Likewise.
(find_rgns): Likewise.
* tracer.c (find_best_successor): Likewise.
(find_best_predecessor): Likewise.
(tail_duplicate): Likewise.
* tree-cfg.c (make_edges): Likewise.
(make_ctrl_stmt_edges): Likewise.
(make_goto_expr_edges): Likewise.
(tree_can_merge_blocks_p): Likewise.
(tree_merge_blocks): Likewise.
(cfg_remove_useless_stmts_bb): Likewise.
(remove_phi_nodes_and_edges_for_unreachable_block): Likewise.
(tree_block_forwards_to): Likewise.
(cleanup_control_expr_graph): Likewise.
(find_taken_edge): Likewise.
(dump_cfg_stats): Likewise.
(tree_cfg2vcg): Likewise.
(disband_implicit_edges): Likewise.
(tree_find_edge_insert_loc): Likewise.
(bsi_commit_edge_inserts): Likewise.
(tree_split_edge): Likewise.
(tree_verify_flow_info): Likewise.
(tree_make_forwarder_block): Likewise.
(tree_forwarder_block_p): Likewise.
(thread_jumps): Likewise.
(tree_try_redirect_by_replacing_jump): Likewise.
(tree_split_block): Likewise.
(add_phi_args_after_copy_bb): Likewise.
(rewrite_to_new_ssa_names_bb): Likewise.
(dump_function_to_file): Likewise.
(print_pred_bbs): Likewise.
(print_loop): Likewise.
(tree_flow_call_edges_add): Likewise.
(split_critical_edges): Likewise.
(execute_warn_function_return): Likewise.
(extract_true_false_edges_from_block): Likewise.
* tree-if-conv.c (tree_if_conversion): Likewise.
(if_convertable_bb_p): Likewise.
(find_phi_replacement_condition): Likewise.
(combine_blocks): Likewise.
* tree-into-ssa.c (compute_global_livein): Likewise.
(ssa_mark_phi_uses): Likewise.
(ssa_rewrite_initialize_block): Likewise.
(rewrite_add_phi_arguments): Likewise.
(ssa_rewrite_phi_arguments): Likewise.
(insert_phi_nodes_for): Likewise.
(rewrite_into_ssa): Likewise.
(rewrite_ssa_into_ssa): Likewise.
* tree-mudflap.c (mf_build_check_statement_for): Likewise.
* tree-outof-ssa.c (coalesce_abnormal_edges): Likewise.
(rewrite_trees): Likewise.
* tree-pretty-print.c (dump_bb_header): Likewise.
(dump_implicit_edges): Likewise.
* tree-sra.c (insert_edge_copies): Likewise.
(find_obviously_necessary_stmts): Likewise.
(remove_data_stmt): Likewise.
* tree-ssa-dom.c (thread_across_edge): Likewise.
(dom_opt_finalize_block): Likewise.
(single_incoming_edge_ignoring_loop_edges): Likewise.
(record_equivalences_from_incoming_edges): Likewise.
(cprop_into_successor_phis): Likewise.
* tree-ssa-live.c (live_worklist): Likewise.
(calculate_live_on_entry): Likewise.
(calculate_live_on_exit): Likewise.
* tree-ssa-loop-ch.c (should_duplicate_loop_header_p): Likewise.
(copy_loop_headers): Likewise.
* tree-ssa-loop-im.c (loop_commit_inserts): Likewise.
(fill_always_executed_in): Likewise.
* tree-ssa-loop-ivcanon.c (create_canonical_iv): Likewise.
* tree-ssa-loop-ivopts.c (find_interesting_uses): Likewise.
(compute_phi_arg_on_exit): Likewise.
* tree-ssa-loop-manip.c (add_exit_phis_edge): Likewise.
(get_loops_exit): Likewise.
(split_loop_exit_edge): Likewise.
(ip_normal_pos): Likewise.
* tree-ssa-loop-niter.c (simplify_using_initial_conditions):
Likewise.
* tree-ssa-phiopt.c (candidate_bb_for_phi_optimization): Likewise.
(replace_phi_with_stmt): Likewise.
(value_replacement): Likewise.
* tree-ssa-pre.c (compute_antic_aux): Likewise.
(insert_aux): Likewise.
(init_pre): Likewise.
* tree-ssa-propagate.c (simulate_stmt): Likewise.
(simulate_block): Likewise.
(ssa_prop_init): Likewise.
* tree-ssa-threadupdate.c (thread_block): Likewise.
(create_block_for_threading): Likewise.
(remove_last_stmt_and_useless_edges): Likewise.
* tree-ssa.c (verify_phi_args): Likewise.
(verify_ssa): Likewise.
* tree_tailcall.c (independent_of_stmt_p): Likewise.
(find_tail_calls): Likewise.
(eliminate_tail_call): Likewise.
(tree_optimize_tail_calls_1): Likewise.
* tree-vectorizer.c (vect_transform_loop): Likewise.
* var-tracking.c (prologue_stack_adjust): Likewise.
(vt_stack_adjustments): Likewise.
(vt_find_locations): Likewise.
* config/frv/frv.c (frv_ifcvt_modify_tests): Likewise.
* config/i386/i386.c (ix86_pad_returns): Likewise.
* config/ia64/ia64.c (ia64_expand_prologue): Likewise.
* config/rs6000/rs6000.c (rs6000_emit_prologue): Likewise.
Co-Authored-By: Andrew Pinski <pinskia@physics.uc.edu>
Co-Authored-By: Steven Bosscher <stevenb@suse.de>
From-SVN: r88222
|
|
* bitmap.h (EXECUTE_IF_SET_IN_BITMAP, EXECUTE_IF_AND_COMPL_IN_BITMAP,
EXECUTE_IF_AND_IN_BITMAP): Changed to iterator style.
(bitmap_iterator): New type.
(bmp_iter_common_next_1, bmp_iter_single_next_1, bmp_iter_single_init,
bmp_iter_end_p, bmp_iter_single_next, bmp_iter_and_not_next_1,
bmp_iter_and_not_init, bmp_iter_and_not_next, bmp_iter_and_next_1,
bmp_iter_and_init, bmp_iter_and_next): New functions.
* basic-block.h (EXECUTE_IF_SET_IN_REG_SET,
EXECUTE_IF_AND_COMPL_IN_REG_SET, EXECUTE_IF_AND_IN_REG_SET): Changed to
use iterator-style EXECUTE_IF_IN_BITMAP macros.
* bitmap.c (bitmap_print): Ditto.
* bt-load.c (clear_btr_from_live_range, add_btr_to_live_range,
btr_def_live_range): Ditto.
* cfganal.c (compute_dominance_frontiers_1) Ditto.
* cgraphunit.c (convert_UIDs_in_bitmap, cgraph_characterize_statics):
Ditto.
* ddg.c (build_inter_loop_deps): Ditto.
* df.c (FOR_EACH_BB_IN_BITMAP, df_bb_reg_info_compute, df_refs_update):
Ditto.
* except.c (remove_eh_handler): Ditto.
* flow.c (reg_set_to_hard_reg_set): Ditto.
* gcse.c (clear_modify_mem_tables): Ditto.
* global.c (build_insn_chain): Ditto.
* ifcvt.c (dead_or_predicable): Ditto.
* loop-invariant.c (get_inv_cost, set_move_mark, move_invariant_reg):
Ditto.
* ra-build.c (livethrough_conflicts_bb, conflicts_between_webs): Ditto.
* ra-rewrite.c (reloads_to_loads, rewrite_program2,
detect_web_parts_to_rebuild, delete_useless_defs, actual_spill): Ditto.
* tree-cfg.c (allocate_ssa_names, tree_duplicate_sese_region,
tree_purge_all_dead_eh_edges): Ditto.
* tree-into-ssa.c (compute_global_livein, insert_phi_nodes,
insert_phi_nodes_for, debug_def_blocks_r, invalidate_name_tags,
rewrite_ssa_into_ssa): Ditto.
* tree-outof-ssa.c (find_replaceable_exprs): Ditto.
* tree-sra.c (scan_function, decide_instantiations, scalarize_parms):
Ditto.
* tree-ssa-alias.c (init_alias_info, compute_points_to_and_addr_escape,
compute_flow_sensitive_aliasing, maybe_create_global_var,
dump_points_to_info_for): Ditto.
* tree-ssa-dce.c (EXECUTE_IF_CONTROL_DEPENDENT): Ditto.
* tree-ssa-dse.c (dse_finalize_block): Ditto.
* tree-ssa-live.c (live_worklist, calculate_live_on_entry,
calculate_live_on_exit, build_tree_conflict_graph, dump_live_info):
Ditto.
* tree-ssa-loop-ivopts.c (find_induction_variables,
find_interesting_uses, add_old_ivs_candidates, alloc_use_cost_map,
determine_use_iv_costs, determine_set_costs, find_best_candidate,
set_cost_up_to, create_new_ivs, remove_unused_ivs, free_loop_data):
Ditto.
* tree-ssa-loop-manip.c (add_exit_phis_var, add_exit_phis): Ditto.
* tree-ssa-operands.c (get_asm_expr_operands, add_call_clobber_ops,
add_call_read_ops): Ditto.
* tree-ssa-pre.c (bitmap_print_value_set, insert_aux): Ditto.
From-SVN: r88145
|
|
2004-09-23 Diego Novillo <dnovillo@redhat.com>
Jakub Jelinek <jakub@redhat.com>
* tree-flow.h (find_new_referenced_vars): Add prototype.
* tree-sra.c (find_new_referenced_vars_1, find_new_referenced_vars):
Move to...
* tree-dfa.c (find_new_referenced_vars_1, find_new_referenced_vars):
... here.
(mark_new_vars_to_rename): Walk through all operands.
* tree-ssa-ccp.c (convert_to_gimple_builtin): New function.
(execute_fold_all_builtins): Use it.
(pass_fold_builtins): Add TODO_rename_vars to todo_flags_finish.
* gcc.c-torture/execute/builtins/strcpy-2.c: New test.
* gcc.c-torture/execute/builtins/strcpy-2-lib.c: New.
From-SVN: r87983
|
|
2004-09-17 Jeffrey D. Oldham <oldham@codesourcery.com>
Zack Weinberg <zack@codesourcery.com>
* alias.c (find_base_decl): Remove unreachable case '3' block.
* expr.c (safe_from_p): Abort if passed a type.
* tree-gimple.c (recalculate_side_effects): Abort if passed
anything other than an expression.
* tree-ssa-pre.c (phi_translate): Return expr immediately if
is_gimple_min_invariant is true for it. Reorder cases for clarity.
Abort on un-handled tree classes.
(valid_in_set): Likewise.
* tree.c (tree_code_class_strings): New static data.
* tree.h (enum tree_code_class): New.
(tree_code_class_strings): Declare.
(TREE_CODE_CLASS_STRING, EXCEPTIONAL_CLASS_P, CONSTANT_CLASS_P)
(REFERENCE_CLASS_P, COMPARISON_CLASS_P, UNARY_CLASS_P, BINARY_CLASS_P)
(STATEMENT_CLASS_P, EXPRESSION_CLASS_P, IS_TYPE_OR_DECL_P): New macros.
(TYPE_P, DECL_P, IS_NON_TYPE_CODE_CLASS, IS_EXPR_CODE_CLASS)
(checking macros, EXPR_LOCATION, SET_EXPR_LOCATION, EXPR_LOCUS): Update.
* tree.def, c-common.def, objc/objc-tree.def: Use
tree_code_class enumeration constants instead of code letters.
* alias.c, builtins.c, c-common.c, c-format.c, c-lang.c, c-pragma.c
* c-typeck.c, cgraphunit.c, convert.c, dbxout.c, dwarf2out.c
* emit-rtl.c expr.c, fold-const.c, gimplify.c, lambda-code.c
* langhooks.c, langhooks.h, predict.c, print-tree.c, reload1.c, stmt.c
* tree-browser.c, tree-cfg.c, tree-chrec.c, tree-complex.c, tree-dfa.c
* tree-dump.c, tree-eh.c, tree-gimple.c, tree-inline.c, tree-nested.c
* tree-outof-ssa.c, tree-pretty-print.c, tree-sra.c, tree-ssa-ccp.c
* tree-ssa-dce.c, tree-ssa-dom.c, tree-ssa-forwprop.c, tree-ssa-live.c
* tree-ssa-loop-im.c, tree-ssa-loop-ivopts.c, tree-ssa-operands.c
* tree-ssa-phiopt.c, tree-ssa-pre.c, tree-ssa-propagate.c
* tree-ssa.c, tree-ssanames.c, tree-tailcall.c, tree.c, varasm.c
* config/sol2-c.c, config/arm/arm.c, config/i386/winnt.c
* config/pa/pa.c, config/pa/pa.h, config/sh/sh.c, objc/objc-lang.c
Update to match.
* LANGUAGES: Add note about change.
ada:
* ada-tree.def: Use tree_code_class enumeration constants
instead of code letters.
* ada-tree.h, decl.c, misc.c, trans.c, utils.c, utils2.c:
Update for new tree-class enumeration constants.
cp:
* cp-tree.def: Use tree_code_class enumeration constants
instead of code letters.
* call.c, class.c, cp-gimplify.c, cp-lang.c, cxx-pretty-print.c
* mangle.c, pt.c, semantics.c, tree.c, typeck.c:
Update for new tree-class enumeration constants.
fortran:
* f95-lang.c, trans-expr.c, trans.c: Update for new tree-class
enumeration constants.
java:
* java-tree.def: Use tree_code_class enumeration constants
instead of code letters.
* java-gimplify.c, jcf-write.c, lang.c, parse.y: Update for
new tree-class enumeration constants.
treelang:
* treetree.c: Update for new tree-class enumeration constants.
From-SVN: r87675
|
|
* basic-block.h, c-decl.c, c-parse.in, cgraphunit.c, ddg.c,
gimplify.c, lambda-code.c, optabs.c, predict.c,
tree-scalar-evolution.c, tree-sra.c, tree-ssa-loop-ch.c,
tree-ssa.c, vec.h: Fix comment typos. Follow spelling
conventions.
From-SVN: r87637
|
|
* cgraph.h, cgraphunit.c, fold-const.c, lambda-mat.c,
lambda.h, profile.c, tree-optimize.c, tree-sra.c, vec.h: Fix
comment typos. Follow spelling conventions.
From-SVN: r87490
|
|
PR middle-end/17411
* tree-sra.c (generate_element_zero): Revert recent build_int_cst
change. elt->type may be a floating point type, so use fold_convert.
* g++.dg/opt/pr17411-1.C: New test case.
From-SVN: r87377
|
|
internal_error instead of abort.
* targhooks.c (default_unwind_emit, default_scalar_mode_supported_p):
Use gcc_assert, gcc_unreachable & internal_error instead of abort.
* timevar.c (timevar_push, timevar_pop, timevar_start,
timevar_stop): Likewise.
* toplev.c (default_pch_valid_p): Likewise.
* tracer.c (tail_duplicate): Likewise.
* tree-alias-common.c (get_alias_var_decl,
get_values_from_constructor, create_alias_var, delete_alias_vars,
empty_points_to_set, same_points_to_set, ptr_may_alias_var):
Likewise.
* tree.c (tree_size, make_node_stat, copy_node_stat,
build_int_cst_wide, integer_all_onesp, list_length, chainon,
tree_node_structure, type_contains_placeholder_p, substitute_in_expr,
substitute_placeholder_in_expr, tabilize_reference_1, build0_stat,
build1_stat, build2_stat, build3_stat, build4_stat, is_attribute_p,
lookup_attribute, type_hash_canon, host_integerp, iterative_hash_expr,
build_method_type_directly, decl_type_context, get_callee_fndecl,
get_set_constructor_bits, build_vector_type_for_mode, int_cst_value,
tree_fold_gcd): Likewise.
* tree-cfg.c (create_bb, make_ctrl_stmt_edges, make_exit_edges,
make_cond_expr_edges, group_case_labels, tree_merge_blocks,
cleanup_control_expr_graph, find_taken_edge,
find_taken_edge_switch_expr, phi_alternatives_equal,
is_ctrl_altering_stmt, disband_implicit_edges, set_bb_for_stmt,
stmt_for_bsi, tree_find_edge_insert_loc, bsi_insert_on_edge_immediate,
tree_split_edge, tree_verify_flow_info, thread_jumps,
tree_redirect_edge_and_branch, tree_flow_call_edges_add): Likewise.
* tree-chrec.c (chrec_fold_poly_cst, chrec_fold_plus_poly_poly,
chrec_fold_multiply_poly_poly): Likewise.
* tree-complex.c (extract_component, expand_complex_division,
expand_complex_comparison, expand_complex_operations_1,
build_replicated_const, expand_vector_operations_1): Likewise.
* tree-data-ref.c (tree_fold_bezout, build_classic_dist_vector,
build_classic_dir_vector): Likewise.
* tree-dfa.c (compute_immediate_uses_for_phi,
compute_immediate_uses_for_stmt, create_var_ann, create_stmt_ann,
create_tree_ann, collect_dfa_stats, get_virtual_var): Likewise.
* tree-dump.c (dequeue_and_dump): Likewise.
* tree-eh.c (record_stmt_eh_region, add_stmt_to_eh_region,
record_in_finally_tree, replace_goto_queue_1,
maybe_record_in_goto_queue, verify_norecord_switch_expr,
do_return_redirection): Likewise.
* tree-if-conv.c (tree_if_convert_stmt, tree_if_convert_cond_expr,
add_to_dst_predicate_list, find_phi_replacement_condition,
replace_phi_with_cond_modify_expr, get_loop_body_in_if_conv_order):
Likewise.
* tree-inline.c (remap_decl, remap_type, remap_decls, copy_body_r,
initialize_inlined_parameters, declare_return_variable,
estimate_num_insns_1, expand_call_inline, expand_calls_inline,
optimize_inline_calls, copy_tree_r): Likewise.
* tree-into-ssa.c (rewrite_initialize_block_local_data, rewrite_stmt,
ssa_rewrite_stmt, rewrite_into_ssa): Likewise.
* tree-iterator.c (alloc_stmt_list, tsi_link_before, tsi_link_after,
tsi_split_statement_list_after, tsi_split_statement_list_before):
Likewise.
* tree-mudflap.c (mf_varname_tree): Likewise.
* tree-nested.c (create_tmp_var_for, lookup_field_for_decl,
lookup_tramp_for_decl, convert_all_function_calls): Likewise.
* tree-optimize.c (tree_rest_of_compilation): Likewise.
* tree-outof-ssa.c (create_temp, eliminate_build, eliminate_phi,
coalesce_abnormal_edges, coalesce_ssa_name, eliminate_virtual_phis,
free_temp_expr_table, add_dependance, finish_expr, rewrite_trees):
Likewise.
* tree-phinodes.c (resize_phi_node, add_phi_arg,
remove_all_phi_nodes_for): Likewise.
* tree-pretty-print.c (op_prio, print_call_name): Likewise.
* tree-profile.c (tree_gen_interval_profiler, tree_gen_pow2_profiler,
tree_gen_one_value_profiler, tree_gen_const_delta_profiler): Likewise.
* tree-sra.c (type_can_instantiate_all_elements, sra_hash_tree,
sra_elt_eq, sra_walk_expr, instantiate_missing_elements,
generate_one_element_ref, generate_element_copy,
generate_element_zero, scalarize_copy, scalarize_init,
scalarize_ldst): Likewise.
* tree-ssa-alias.c (delete_alias_info, group_aliases, may_alias_p,
add_may_alias, add_pointed_to_expr, add_pointed_to_var,
collect_points_to_info_r, get_tmt_for, get_ptr_info): Likewise.
* tree-ssa.c (walk_use_def_chains, check_phi_redundancy): Likewise.
* tree-ssa-ccp.c (dump_lattice_value, get_default_value, get_value,
set_lattice_value, likely_value, ccp_visit_phi_node, visit_assignment,
widen_bitfield, ccp_fold_builtin): Likewise.
* tree-ssa-copy.c (may_propagate_copy, merge_alias_info,
replace_exp_1, propagate_tree_value): Likewise.
* tree-ssa-copyrename.c (copy_rename_partition_coalesce): Likewise.
* tree-ssa-dce.c (set_control_dependence_map_bit,
find_control_dependence, find_pdom, mark_operand_necessary,
mark_stmt_if_obviously_necessary,
mark_control_dependent_edges_necessary, remove_dead_stmt): Likewise.
* tree-ssa-dom.c (dom_opt_initialize_block_local_data,
simplify_switch_and_lookup_avail_expr, cprop_into_successor_phis,
eliminate_redundant_computations, avail_expr_eq): Likewise.
* tree-ssa-dse.c (fix_stmt_v_may_defs): Likewise.
* tree-ssa-loop-ch.c (should_duplicate_loop_header_p,
duplicate_blocks): Likewise.
* tree-ssa-loop-im.c (for_each_index, set_level,
is_call_clobbered_ref): Likewise.
* tree-ssa-loop-ivopts.c (dump_use, divide, stmt_after_ip_normal_pos,
stmt_after_increment, set_iv, contains_abnormal_ssa_name_p,
find_interesting_uses_outer_or_nonlin, add_derived_ivs_candidates,
peel_address, ptr_difference_cost, may_replace_final_value,
determine_use_iv_cost, rewrite_use_nonlinear_expr, rewrite_use_outer,
rewrite_use, rewrite_uses): Likewise.
* tree-ssa-loop-manip.c (rewrite_into_loop_closed_ssa,
check_loop_closed_ssa_use): Likewise.
* tree-ssanames.c (make_ssa_name): Likewise.
* tree-ssa-operands.c (finalize_ssa_defs, finalize_ssa_uses,
finalize_ssa_v_must_defs, finalize_ssa_stmt_operands,
get_stmt_operands, get_expr_operands, get_asm_expr_operands,
get_indirect_ref_operands, add_stmt_operand): Likewise.
* tree-ssa-pre.c (value_exists_in_set_bitmap,
value_remove_from_set_bitmap, bitmap_insert_into_set, insert_into_set,
phi_translate, valid_in_set, compute_antic,
find_or_generate_expression, create_expression_by_pieces, insert_aux,
create_value_expr_from, eliminate): Likewise.
* tree-ssa-propagate.c (cfg_blocks_get): Likewise.
* tree-ssa-threadupdate.c (remove_last_stmt_and_useless_edges):
Likewise.
* tree-tailcall.c (independent_of_stmt_p, adjust_return_value,
eliminate_tail_call): Likewise.
* tree-vectorizer.c (vect_create_index_for_array_ref,
vect_align_data_ref, vect_create_data_ref,
vect_create_destination_var, vect_get_vec_def_for_operand,
vect_finish_stmt_generation, vect_transform_stmt,
vect_transform_loop_bound, vect_transform_loop,
vect_analyze_operations): Likewise.
* tree-vn.c (vn_compute, set_value_handle, get_value_handle):
Likewise.
* tree-flow-inline.h (var_ann, get_var_ann, get_def_from_ptr,
get_use_op_ptr, immediate_use, phi_ssa_name_p, bsi_start,
bsi_after_labels, bsi_last): Likewise.
* tree-ssa-live.c (var_union, change_partition_var,
create_ssa_var_map, calculate_live_on_entry, root_var_init,
type_var_init, add_coalesce, sort_coalesce_list, pop_best_coalesce):
Likewise.
* tree-ssa-live.h (partition_is_global, live_entry_blocks,
tpa_find_tree): Likewise.
(register_ssa_partition_check): Declare.
(register_ssa_partition): use it.
* tree-ssa-live.c: Include errors.h.
(register_ssa_partition_check): New.
* tree-ssa-operands.c: Include errors.h.
* Makefile.in (tree-ssa-operands.o): Depend on errors.h.
Co-Authored-By: Nathan Sidwell <nathan@codesourcery.com>
From-SVN: r87223
|
|
* builtins.c (fold_builtin_strchr): Use build_int_cst, not
fold_convert.
(fold_builtin_strpbrk): Likewise.
* expr.c (array_ref_low_bound): Likewise.
* tree-scalar-evolution.c (chrec_is_positive, add_to_evolution_1,
interpret_rhs_modify_expr, number_of_iterations_in_loop): Likewise.
* tree-sra.c (generate_element_zero): Likewise.
* tree-ssa-dom.c (simplify_rhs_and_lookup_avail_expr): Likewise.
* tree-ssa-loop-ivopts.c (determine_biv_step, idx_find_step,
add_old_iv_candidates, add_iv_candidates): Likewise.
* tree-tailcall.c (tree_optimize_tail_calls_1): Likewise.
From-SVN: r87141
|
|
2004-09-06 Paolo Bonzini <bonzini@gnu.org>
Unify the management of RTL and tree-level dump files.
* cfgexpand.c (tree_expand_cfg): Fix incorrect comment.
Don't print function name to the dump file, the pass manager
would do this for us. Add code from the top of
rest_of_compilation, up to the initial RTL dump.
* passes.c (rest_of_handle_jump): Call fixup_tail_calls and
close the DFI_sibling dump file.
(rest_of_compilation): Don't do that here. Remove code up to the
initial RTL dump.
(init_optimization_passes): Remove.
(pass_rest_of_compilation): Change pass name to NULL.
* toplev.c (lang_dependent_init): Do not use an empty dump file prefix.
Do not call init_optimization_passes.
* toplev.h (init_optimization_passes): Remove.
* graph.c (print_rtl_graph_with_bb, clean_graph_dump_file,
finish_graph_dump_file): Remove SUFFIX parameter.
* graph.h (print_rtl_graph_with_bb, clean_graph_dump_file,
finish_graph_dump_file): Likewise.
* tree-pass.h (struct tree_opt_pass): Add `letter' field.
* cfgexpand.c (pass_expand): Adjust.
* gimple-low.c (pass_lower_cf, pass_remove_useless_vars): Adjust.
* passes.c (pass_rest_of_compilation): Adjust.
* predict.c (pass_profile): Adjust.
* tree-alias-common.c (pass_build_pta, pass_del_pta): Adjust.
* tree-cfg.c (pass_build_cfg, pass_remove_useless_stmts,
pass_split_crit_edges, pass_warn_function_return): Adjust.
* tree-complex.c (pass_lower_vector_ssa, pass_pre_expand): Adjust.
* tree-dfa.c (pass_referenced_vars): Adjust.
* tree-eh.c (pass_lower_eh): Adjust.
* tree-if-conv.c (pass_build_ssa): Adjust.
* tree-into-ssa.c (pass_build_ssa): Adjust.
* tree-mudflap.c (pass_mudflap_1, pass_mudflap_2): Adjust.
* tree-nomudflap.c (pass_mudflap_1, pass_mudflap_2): Adjust.
* tree-nrv.c (pass_nrv): Adjust.
* tree-optimize.c (pass_gimple, pass_all_optimizations,
pass_cleanup_cfg_post_optimizing, pass_free_datastructures,
pass_init_datastructures): Adjust.
* tree-outof-ssa.c (pass_del_ssa): Adjust.
* tree-profile.c (pass_tree_profile): Adjust.
* tree-sra.c (pass_sra): Adjust.
* tree-ssa-alias.c (pass_may_alias): Adjust.
* tree-ssa-ccp.c (pass_ccp, pass_fold_builtins): Adjust.
* tree-ssa-copyrename.c (pass_rename_ssa_copies): Adjust.
* tree-ssa-dce.c (pass_dce, pass_cd_dce): Adjust.
* tree-ssa-dom.c (pass_dominator): Adjust.
* tree-ssa-dse.c (pass_dse): Adjust.
* tree-ssa-forwprop.c (pass_forwprop): Adjust.
* tree-ssa-if-conv.c (pass_if_conversion): Adjust.
* tree-ssa-loop-ch.c (pass_ch): Adjust.
* tree-ssa-loop.c (pass_loop, pass_loop_init, pass_lim,
pass_loop_done, pass_complete_unroll, pass_iv_canon,
pass_iv_optimize, pass_vectorize): Adjust.
* tree-ssa-phiopt.c (pass_phiopt): Adjust.
* tree-ssa-pre.c (pass_pre, pass_fre): Adjust.
* tree-ssa.c (pass_redundant_phi, pass_early_warn_uninitialized,
pass_late_warn_uninnitialized): Adjust.
* tree-tailcall.c (pass_tail_recursion, pass_tail_calls): Adjust.
* Makefile.in (tree-dump.o): Add new dependencies.
* cgraph.c (cgraph_remove_node): TDF_all -> TDF_tree_all.
* cgraphunit.c (cgraph_preserve_function_body_p, cgraph_optimize):
Likewise.
* toplev.c (dump_file_name): New.
* tree-dump.c (dump_enable_all): Add LETTER parameter.
(struct dump_file_info): Add NUM and LETTER fields.
(dump_files): Adjust and add RTL dump files.
(dump_register): Add NUM and LETTER fields.
(get_dump_file_name, dump_initialized_p, enable_rtl_dump_file): New.
(dump_begin): Use get_dump_file_name.
(dump_switch_p_1): Adjust call to dump_enable_all.
* tree-dump.h (dump_register): Adjust prototype.
* tree-optimize.c (register_one_dump_file): Take dump file index.
Support flags for RTL dumps.
(register_dump_files): Fill in NUM field of struct dump_file_info.
Track properties both when the gate is executed and when it is not.
(execute_todo): Dump RTL. Add PROPERTIES parameter.
(execute_one_pass): Pass properties to execute_todo. Handle VCG
dumps of RTL.
* tree-pass.h (dump_file_name): New.
* tree.h (TDF_TREE, TDF_RTL, get_dump_file_name, dump_initialized_p):
New.
* Makefile.in (passes.o): Add new dependencies.
* passes.c (struct dump_file_info, enum dump_file_index,
dump_file_tbl, init_optimization_passes): Remove.
(open_dump_file, close_dump_file): Use tree-dumping infrastructure.
(rest_of_handle_new_regalloc, rest_of_handle_old_regalloc): Use
dump_enabled_p.
(finish_optimization_passes): Update finish_graph_dump_file loop.
(enable_rtl_dump_file): Remove.
* tree-dump.c (dump_files): Adjust and add RTL dump files.
(enable_rtl_dump_file): Add here.
* tree.h (enum tree_dump_index): Add RTL dump file indices.
* doc/invoke.texi (Debugging options): Document new RTL debugging
options. Update.
From-SVN: r87113
|
|
* c-common.c, cfgexpand.c, cgraphunit.c, defaults.h,
et-forest.c, expr.c, gimplify.c, global.c, gthr-lynx.h,
hard-reg-set.h, modulo-sched.c, optabs.c, postreload-gcse.c,
tree-data-ref.c, tree-flow.h, tree-if-conv.c, tree-inline.c,
tree-sra.c, tree-ssa-loop-im.c, tree-ssa-loop-ivopts.c,
tree-ssa-loop-niter.c, tree-ssa-operands.c,
tree-ssa-operands.h, tree-ssa-propagate.c,
tree-ssa-propagate.h, tree-ssa-threadupdate.c, value-prof.c,
vec.c, vec.h: Fix comment typos. Follow spelling conventions.
From-SVN: r87104
|
|
2004-08-25 Andrew MacLeod <amacleod@redhat.com>
* tree-ssa-operands.h (struct ssa_operand_iterator_d): New. SSA operand
iterator controlling structure.
(SSA_OP_USE, SSA_OP_DEF, SSA_OP_VUSE, SSA_OP_VMAYUSE, SSA_OP_VMAYDEF,
SSA_OP_VMUSTDEF, SSA_OP_VIRTUAL_USES, SSA_OP_VIRTUAL_DEFS,
SSA_OP_ALL_USES, SSA_OP_ALL_DEFS, SSA_OP_ALL_OPERANDS): New. Operand
iterator flags.
(FOR_EACH_SSA_TREE_OPERAND): New. Iterate over operands as trees.
(FOR_EACH_SSA_USE_OPERAND): New. Iterate over operands as uses.
(FOR_EACH_SSA_DEF_OPERAND): New. Iterate over operands as defs.
(FOR_EACH_SSA_MAYDEF_OPERAND): New. Iterate over V_MAY_DEFs.
* tree-ssa-operands.c (NULL_DEF_OPERAND_P, NULL_USE_OPERAND_P): New.
Empty operand pointers.
* tree-flow-inline.h (op_iter_done): New. Return true if finished.
(op_iter_next_use): New. Return next use_operand_p.
(op_iter_next_def): New. Return next def_operand_p.
(op_iter_next_tree): New. Return next operands as a tree.
(op_iter_init): New. Initialize an iterator structure.
(op_iter_init_use): New. Initialize structure and get the first use.
(op_iter_init_def): New. Initialize structure and get the first def.
(op_iter_init_tree): New. Initialize structure and get the first tree.
(op_iter_next_maydef): New. Return next V_MAY_DEF operands.
(op_iter_init_maydef): New. Initialize structure and get the first
V_MAY_DEF operands.
* tree-cfg.c (tree_duplicate_bb): Use new operand iterator.
* tree-dfa.c (compute_immediate_uses_for_stmt,
redirect_immediate_uses): Use new operand iterator.
(v_may_defs_disappeared_p, v_must_defs_disappeared_p): Delete.
(mark_new_vars_to_rename): Use new operand iterator. Count virtual
operands instead of using *_disappeared_p routines.
* tree-into-ssa.c (mark_def_sites, ssa_mark_def_sites, rewrite_stmt,
ssa_rewrite_stmt): Use new operand iterator.
* tree-outof-ssa.c (check_replaceable, find_replaceable_in_bb,
rewrite_trees): Use new operand iterator.
* tree-pretty-print.c (dump_vops): Use new operand iterator.
* tree-sra.c (mark_all_v_defs): Use new operand iterator.
* tree-ssa-alias.c (compute_points_to_and_addr_escape,
dump_points_to_info): Use new operand iterator.
* tree-ssa-ccp.c (cp_lattice_meet, visit_stmt, initialize,
replace_uses_in, replace_vuse_in, likely_value, set_rhs): Use new
operand iterator.
* tree-ssa-dce.c (mark_stmt_if_obviously_necessary,
propagate_necessity): Use new operand iterator.
* tree-ssa-dom.c (cprop_into_stmt, optimize_stmt): Use operand iterator.
(register_definitions_for_stmt): Use new operand iterator. Take stmt as
a parameter instead of a stmt_ann_t.
* tree-ssa-live.c (create_ssa_var_map, calculate_live_on_entry,
build_tree_conflict_graph): Use new operand iterator.
* tree-ssa-loop-im.c (determine_max_movement, single_reachable_address,
rewrite_mem_refs): Use new operand iterator.
* tree-ssa-loop-manip.c (find_uses_to_rename_stmt,
check_loop_closed_ssa_use): Use new operand iterator.
* tree-ssa.c (verify_ssa, replace_immediate_uses): Use operand iterator.
* tree-ssanames.c (release_defs): Use new operand iterator.
* tree-vectorizer.c (vect_create_data_ref): Use new operand iterator.
From-SVN: r86583
|
|
2004-08-19 Eric Christopher <echristo@redhat.com>
* langhooks-def.h (LANG_HOOKS_UNSAVE_EXPR_NOW): Remove.
* langhooks.h (unsave_expr_now): Ditto.
* tree.h (unsave_expr_1): Remove prototype.
(lhd_unsave_expr_now): Rename to unsave_expr_now.
* tree-inline.c (unsave_expr_1): Move here
from tree.c. Make static.
(unsave_expr_now): Rename from lhd_unsave_expr_now.
* tree-sra.c: Fix up for rename.
* tree-ssa-copy.c: Ditto.
* tree-eh.c: Ditto.
* tree.c (unsave_expr_1): Move to tree-inline.c.
2004-08-19 Eric Christopher <echristo@redhat.com>
* cp-tree.h (cxx_unsave_expr_now): Delete prototype.
* tree.c (cxx_unsave_expr_now): Delete.
(cp_unsave_r): Ditto.
From-SVN: r86277
|
|
failed.for SSA_NAME: l_addr<D8610>_650)
PR 17051
* tree-sra.c (scalarize_use): Mark all v_defs for !is_output too.
From-SVN: r86158
|
|
right after the program is renamed into SSA.
* tree-optimize.c (init_tree_optimization_passes): Schedule
pass_may_alias right after the program is renamed into SSA.
* tree-pass.h (PROP_alias): Define.
* tree-outof-ssa.c (pass_del_ssa): Require PROP_alias.
* tree-sra.c (pass_sra): Likewise.
* tree-ssa-ccp.c (pass_ccp): Likewise.
* tree-ssa-copyrename.c (pass_rename_ssa_ccp): Likewise.
* tree-ssa-dce.c (pass_dce): Likewise.
* tree-ssa-dom.c (pass_dominator): Likewise.
* tree-ssa-dse.c (pass_dse): Likewise.
* tree-ssa-forwprop.c (pass_forwprop): Likewise.
* tree-ssa-loop-ch.c (pass_ch): Likewise.
* tree-ssa-phiopt.c (pass_phiopt): Likewise.
* tree-ssa-pre.c (pass_pre): Likewise.
* tree-tailcall.c (pass_tail_recursion): Likewise.
* tree-ssa.c (pass_redundant_phi): Likewise.
* tree-ssa-alias.c (aliases_computed_p): Remove.
Update all users.
(init_alias_info): Do not mark all type tags for renaming
unconditionally.
Clear may_aliases from every symbol.
(setup_pointers_and_addressables): If a pointer has not been
dereferenced and it had a type tag, clear it and mark the old
tag for renaming.
testsuite/ChangeLog
* gcc.dg/tree-ssa/20030714-2.c: Adjust number of expected
conditionals.
* gcc.dg/tree-ssa/20031022-1.c: Adjust number of expected
loads.
* gcc.dg/tree-ssa/ssa-dom-cse-1.c: Expect optimization in
DOM1.
From-SVN: r85255
|
|
* gimplify.c (is_gimple_addr_expr_arg_or_indirect): Remove.
(gimplify_modify_expr, gimplify_addr_expr, gimplify_expr): Use
is_gimple_addressable.
* tree-gimple.c (is_gimple_addressable): Rename from
is_gimple_addr_expr_arg; accept INDIRECT_REF.
(is_gimple_lvalue): Don't test INDIRECT_REF directly.
* tree-gimple.h, tree-sra.c, tree-ssa-loop-im.c: Update for
rename to is_gimple_addressable.
From-SVN: r85243
|
|
* tree-def (WITH_SIZE_EXPR): New.
* explow.c (expr_size, int_expr_size): Handle WITH_SIZE_EXPR.
* expr.c (expand_expr_real_1): Likewise.
* gimplify.c (maybe_with_size_expr): New.
(gimplify_arg, gimplify_modify_expr): Use it.
(gimplify_modify_expr_to_memcpy): Take size parameter.
(gimplify_modify_expr_to_memset): Likewise.
(gimplify_expr): Handle WITH_SIZE_EXPR.
* tree-alias-common.c (find_func_aliases): Likewise.
* tree-eh.c (tree_could_trap_p): Likewise.
(tree_could_throw_p): Likewise.
* tree-gimple.c (is_gimple_lvalue): Likewise.
(get_call_expr_in): Likewise.
* tree-inline.c (estimate_num_insns_1): Likewise.
(expand_calls_inline): Likewise.
* tree-nested.c (convert_call_expr): Likewise.
* tree-pretty-print.c (dump_generic_node): Likewise.
* tree-sra.c (sra_walk_expr): Likewise.
* tree-ssa-alias.c (add_pointed_to_expr): Likewise.
* tree-ssa-ccp.c (get_rhs, set_rhs): Likewise.
* tree-ssa-operands.c (get_expr_operands): Likewise.
* tree-tailcall.c (find_tail_calls): Likewise.
* calls.c (expand_call): Reset old_stack_allocated after
calling emit_stack_restore.
* gcc.c-torture/compile/20020210-1.c: Remove XFAIL.
From-SVN: r84833
|
|
generate_element_copy, at tree-sra.c:1466)
PR tree-opt/16383
* tree-ssa-ccp.c (fold_stmt_r): Split out...
* tree.c (fields_compatible_p, find_compatible_field): ... new.
* tree.h (fields_compatible_p, find_compatible_field): Declare.
* tree-sra.c (sra_hash_tree): Hash fields by offset.
(sra_elt_eq): Use fields_compatible_p.
(generate_one_element_ref): Use find_compatible_field.
From-SVN: r84524
|
|
PR tree-opt/16422
* tree-sra.c (generate_one_element_init): New.
(generate_element_init): Use it.
(scalarize_init): Push/pop gimplify context around it.
(find_new_referenced_vars_1, find_new_referenced_vars): New.
* gimplify.c (gimplify_expr): Allow SSA_NAME.
From-SVN: r84523
|
|
* tree-cfg.c (make_exit_edges): Use get_call_expr_in.
(remove_useless_stmts_1, is_ctrl_altering_stmt): Likewise.
(tree_block_ends_with_call_p, need_fake_edge_p): Likewise.
* tree-eh.c (lower_eh_constructs_1): Likewise.
* tree-sra.c (sra_walk_modify_expr): Likewise.
* tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
(eliminate_unnecessary_stmts): Likewise.
* tree-ssa-dse.c (dse_optimize_stmt): Likewise.
* tree-tailcall.c (optimize_tail_call): Likewise.
* tree-ssa-ccp.c (get_rhs, set_rhs): Reorg to use switch.
From-SVN: r84298
|
|
* tree-sra.c (struct sra_walk_fns): Revert 2004-07-05 change.
(sra_walk_modify_expr, scan_init): Likewise.
(generate_element_zero): Check visited before scanning children.
(generate_element_init): Set visited on error.
(scalarize_init): Handle generate_element_init failure similar
to use_block_copy.
From-SVN: r84177
|
|
* tree-sra.c (struct sra_walk_fns): Init function now returns bool.
(sra_walk_modify_expr): Allow init function to fail.
(scan_init): Now returns bool.
(generate_element_init): If can't understand INIT, return false.
(scalarize_init): Return false if generate_element_init does.
From-SVN: r84120
|
|
comparision failure)
PR tree-optimization/16341
* tree-sra.c (sra_walk_function): Increment to next stmt before
processing the current stmt.
(sra_insert_after): Always use BSI_SAME_STMT.
From-SVN: r84070
|
|
From-SVN: r84057
|
|
* ifcvt.c, modulo-sched.c, tree-alias-common.c, tree-sra.c,
tree-ssa-copy.c, tree-ssa-dom.c, tree-ssa-pre.c: Fix comment
typos.
From-SVN: r84008
|
|
disable scalarization.
* tree-sra.c (sra_walk_expr): Don't maybe_lookup_element_for_expr
in order to disable scalarization. Instead set a flag and wait
for a candidate decl.
From-SVN: r84001
|