1. 11 Nov, 2008 1 commit
  2. 11 Oct, 2008 1 commit
    • re PR middle-end/37448 (cannot compile big function) · 57512f53
      2008-10-11  Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	PR rtl-optimization/37448
      	* df.h: (df_ref_class): New enum.
      	(DF_REF_TYPE_NAMES, df_ref_extract): Removed.
      	(struct df_ref): Replaced with union df_ref_d.
      	(df_base_ref, df_artificial_ref, df_regular_ref, df_extract_ref):
      	New members of df_ref_d union.
      	(DF_REF_REAL_REG, DF_REF_REGNO, DF_REF_REAL_LOC, DF_REF_REG,
      	DF_REF_LOC, DF_REF_BB, DF_REF_INSN_INFO, DF_REF_INSN,
      	DF_REF_CLASS, DF_REF_TYPE, DF_REF_CHAIN, DF_REF_ID, DF_REF_FLAGS,
      	DF_REF_ORDER, DF_REF_IS_ARTIFICIAL, DF_REF_NEXT_REG,
      	DF_REF_PREV_REG, DF_REF_EXTRACT_WIDTH, DF_REF_EXTRACT_OFFSET,
      	DF_REF_EXTRACT_MODE): Replaced definition to access union
      	df_ref_d.
             	(DF_MWS_REG_DEF_P, DF_MWS_REG_USE_P, DF_MWS_TYPE): New macros.
      	(df_scan_bb_info, df_bb_regno_first_def_find,
      	df_bb_regno_last_def_find, df_find_def, df_find_use,
      	df_refs_chain_dump, df_regs_chain_dump, df_ref_debug,
      	debug_df_ref, df_chain_create, df_chain_unlink, df_chain_copy,
      	df_ref_create, df_ref_remove, df_compute_accessed_bytes,
      	df_get_artificial_defs, df_get_artificial_uses, union_defs)
      	Replaced struct df_ref * with df_ref.
      	* df-scan.c (df_collection_rec, df_null_ref_rec,
      	df_ref_chain_delete_du_chain, df_ref_chain_delete, df_install_ref,
      	df_grow_ref_info, df_ref_create, df_reg_chain_unlink,
      	df_ref_compress_rec, df_ref_remove, df_ref_chain_delete_du_chain,
      	df_ref_chain_delete, df_free_collection_rec, df_insn_rescan,
      	df_reorganize_refs_by_reg_by_reg,
      	df_reorganize_refs_by_reg_by_insn, df_reorganize_refs_by_reg,
      	df_ref_change_reg_with_loc_1, df_notes_rescan, df_swap_refs,
      	df_sort_and_compress_refs, df_install_ref, df_install_refs,
      	df_ref_record, df_get_conditional_uses, df_get_call_refs,
      	df_bb_refs_record, df_exit_block_uses_collect,
      	df_record_exit_block_uses, df_reg_chain_mark,
      	df_reg_chain_verify_unmarked, df_refs_verify): Replaced struct
      	df_ref * with df_ref.
      	(df_ref_record, df_uses_record, df_ref_create_structure): Added
      	df_ref_class parameter.
      	(df_scan_problem_data): Added new pools for different types of
      	refs.
      	(df_scan_free_internal, df_scan_alloc, df_free_ref,
      	df_ref_create_structure): Processed new ref pools.
      	(df_scan_start_dump): Added counts of refs and insns.
      	(df_ref_create, df_notes_rescan, df_def_record_1, df_uses_record,
      	df_get_call_refs, df_insn_refs_collect, df_bb_refs_collect,
      	df_entry_block_defs_collect, df_exit_block_uses_collect): Added
      	code to pass df_ref_class down to ref creation functions.
      	(df_reg_chain_unlink, df_ref_remove, df_ref_change_reg_with_loc_1,
      	df_reg_chain_mark): Use macros to hide references to df_refs.
      	(df_ref_chain_change_bb): Removed.
      	(df_insn_change_bb): Remove calls to df_ref_insn_change_bb.
      	(df_ref_equal_p, df_ref_compare, df_ref_create_structure):
      	Enhanced to understand df_ref union structure.
      	* fwprop.c (local_ref_killed_between_p, use_killed_between,
      	all_uses_available_at, update_df, try_fwprop_subst,
      	forward_propagate_subreg, forward_propagate_and_simplify,
      	forward_propagate_into, fwprop, fwprop_addr): Replaced struct
      	df_ref * with df_ref.
      	(use_killed_between, all_uses_available_at): Use macros to hide
      	references to df_refs.
      	* regstat.c (regstat_bb_compute_ri,
      	regstat_bb_compute_calls_crossed): Replaced struct df_ref * with
      	df_ref.
      	* see.c (see_handle_relevant_defs, see_handle_relevant_uses,
      	see_handle_relevant_refs, see_analyze_one_def,
      	see_update_relevancy, see_propagate_extensions_to_uses): Replaced
      	struct df_ref * with df_ref.
      	* ra-conflict.c (record_one_conflict, clear_reg_in_live,
      	global_conflicts): Replaced struct df_ref * with df_ref.
      	* ddg.c (create_ddg_dep_from_intra_loop_link,
      	add_cross_iteration_register_deps, build_inter_loop_deps):
      	Replaced struct df_ref * with df_ref.
      	(create_ddg_dep_from_intra_loop_link,
      	add_cross_iteration_register_deps): Use macros to hide references
      	to df_refs.
      	* auto-inc-dec.c (find_inc, merge_in_block): Replaced struct
      	df_ref * with df_ref.
      	* df-core.c (df_bb_regno_first_def_find,
      	df_bb_regno_last_def_find, df_find_def, df_find_use,
      	df_refs_chain_dump, df_regs_chain_dump, df_ref_debug,
      	debug_df_ref): Replaced struct df_ref * with df_ref.
      	(df_mws_dump, df_ref_debug): Use macros to hide references to
      	df_refs.
      	* cse.c (cse_extended_basic_block): Replaced struct df_ref * with
      	df_ref.
      	* web.c (union_defs, entry_register, replace_ref, web_main):
      	Replaced struct df_ref * with df_ref.
      	(union_defs, replace_ref): Use macros to hide references to
      	df_refs.
      	* global.c (compute_regs_asm_clobbered, build_insn_chain):
      	Replaced struct df_ref * with df_ref.
      	* ifcvt.c (dead_or_predicable): Replaced struct df_ref * with
      	df_ref.
      	* sel-sched-ir.c (maybe_downgrade_id_to_use, setup_id_reg_sets, ):
      	Replaced struct df_ref * with df_ref.
      	* ira-lives.c (mark_ref_live, def_conflicts_with_inputs_p,
      	mark_ref_dead, process_bb_node_lives): Replaced struct df_ref *
      	with df_ref.
      	* local-alloc.c (block_alloc): Replaced struct df_ref * with
      	df_ref.
      	* df-byte-scan.c (df_compute_accessed_bytes_extract,
      	df_compute_accessed_bytes_strict_low_part,
      	df_compute_accessed_bytes_subreg, df_compute_accessed_bytes):
      	Replaced struct df_ref * with df_ref.
      	(df_compute_accessed_bytes): Use macros to hide references to
      	df_refs.
      	* init-regs.c (initialize_uninitialized_regs): Replaced struct
      	df_ref * with df_ref.
      	* loop-invariant.c (invariant_for_use, hash_invariant_expr_1,
      	check_dependency, check_dependencies, record_uses): Replaced
      	struct df_ref * with df_ref.
      	(invariant_for_use, check_dependency): Use macros to hide
      	references to df_refs.
      	* loop-iv.c (iv_analysis_loop_init, iv_get_reaching_def,
      	get_biv_step_1, get_biv_step, record_iv, iv_analyze_def,
      	iv_analyze, biv_p): Replaced struct df_ref * with df_ref.
      	(iv_analysis_loop_init, iv_get_reaching_def): Use macros to hide
      	references to df_refs.
      	* ira.c (compute_regs_asm_clobbered): Replaced struct df_ref * with df_ref.
      	* combine.c (create_log_links): Replaced struct df_ref * with df_ref.
      	* df-problems.c (df_rd_bb_local_compute_process_def,
      	df_lr_bb_local_compute, df_live_bb_local_compute, df_chain_create,
      	df_chain_unlink_1, df_chain_unlink, df_chain_copy,
      	df_chain_remove_problem, df_chain_create_bb_process_use,
      	df_chain_create_bb, df_chain_top_dump, df_chain_bottom_dump,
      	df_byte_lr_check_regs, df_byte_lr_bb_local_compute,
      	df_byte_lr_simulate_defs, df_byte_lr_simulate_uses,
      	df_byte_lr_simulate_artificial_refs_at_top,
      	df_byte_lr_simulate_artificial_refs_at_end, df_create_unused_note,
      	df_note_bb_compute, df_note_add_problem, df_simulate_defs,
      	df_simulate_uses, df_simulate_artificial_refs_at_end,
      	df_simulate_artificial_refs_at_top): Replaced struct df_ref * with df_ref.
      	(df_chain_dump): Use macros to hide
      	references to df_refs.
      	* config/mips/mips.c (r10k_simplify_address): Replaced struct
      	df_ref * with df_ref.
      	* dce.c (mark_nonreg_stores, delete_corresponding_reg_eq_notes,
      	mark_artificial_uses, mark_reg_dependencies,
      	byte_dce_process_block): Replaced struct df_ref * with df_ref.
      
      From-SVN: r141067
      Kenneth Zadeck committed
  3. 08 Oct, 2008 1 commit
  4. 13 Sep, 2008 1 commit
  5. 01 Sep, 2008 1 commit
    • sel-sched.h, [...]: New files. · e855c69d
      2008-08-31  Andrey Belevantsev  <abel@ispras.ru>
              Dmitry Melnik  <dm@ispras.ru>
              Dmitry Zhurikhin  <zhur@ispras.ru>
              Alexander Monakov  <amonakov@ispras.ru>
              Maxim Kuvyrkov  <maxim@codesourcery.com>
      
      	* sel-sched.h, sel-sched-dump.h, sel-sched-ir.h, sel-sched.c,
      	sel-sched-dump.c, sel-sched-ir.c: New files.
      	* Makefile.in (OBJS-common): Add selective scheduling object
      	files.
      	(sel-sched.o, sel-sched-dump.o, sel-sched-ir.o): New entries.
      	(SEL_SCHED_IR_H, SEL_SCHED_DUMP_H): New entries.
      	(sched-vis.o): Add dependency on $(INSN_ATTR_H).
      	* cfghooks.h (get_cfg_hooks, set_cfg_hooks): New prototypes.
      	* cfghooks.c (get_cfg_hooks, set_cfg_hooks): New functions.
      	(make_forwarder_block): Update loop latch if we have redirected
      	the loop latch edge.
      	* cfgloop.c (get_loop_body_in_custom_order): New function.
      	* cfgloop.h (LOOPS_HAVE_FALLTHRU_PREHEADERS): New enum field.
      	(CP_FALLTHRU_PREHEADERS): Likewise.
      	(get_loop_body_in_custom_order): Declare.
      	* cfgloopmanip.c (has_preds_from_loop): New.
      	(create_preheader): Honor CP_FALLTHRU_PREHEADERS.
      	Assert that the preheader edge will be fall thru when it is set.
      	* common.opt (fsel-sched-bookkeeping, fsel-sched-pipelining,
      	fsel-sched-pipelining-outer-loops, fsel-sched-renaming,
      	fsel-sched-substitution, fselective-scheduling): New flags.
          	* cse.c (hash_rtx_cb): New.
      	(hash_rtx): Use it.
      	* dbgcnt.def (sel_sched_cnt, sel_sched_region_cnt,
      	sel_sched_insn_cnt): New counters. 
      	* final.c (compute_alignments): Export.  Free dominance info after loop_optimizer_finalize.
      	* genattr.c (main): Output maximal_insn_latency prototype.
      	* genautomata.c (output_default_latencies): New. Factor its code from ...
      	(output_internal_insn_latency_func): ... here.
      	(output_internal_maximal_insn_latency_func): New.
      	(output_maximal_insn_latency_func): New.
      	* hard-reg-set.h (UHOST_BITS_PER_WIDE_INT): Define unconditionally.
      	(struct hard_reg_set_iterator): New.
      	(hard_reg_set_iter_init, hard_reg_set_iter_set,
      	hard_reg_set_iter_next): New functions.
      	(EXECUTE_IF_SET_IN_HARD_REG_SET): New macro.
      	* lists.c (remove_free_INSN_LIST_node,
      	remove_free_EXPR_LIST_node): New functions.
      	* loop-init.c (loop_optimizer_init): When LOOPS_HAVE_FALLTHRU_PREHEADERS,
      	set CP_FALLTHRU_PREHEADERS when calling create_preheaders.
      	(loop_optimizer_finalize): Do not verify flow info after reload.
      	* recog.c (validate_replace_rtx_1): New parameter simplify.
      	Default it to true.  Update all uses.  Factor out simplifying
      	code to ...
      	(simplify_while_replacing): ... this new function.
      	(validate_replace_rtx_part,
      	validate_replace_rtx_part_nosimplify): New.
      	* recog.h (validate_replace_rtx_part,
      	validate_replace_rtx_part_nosimplify): Declare.
      	* rtl.c (rtx_equal_p_cb): New.
      	(rtx_equal_p): Use it.
      	* rtl.h (rtx_equal_p_cb, hash_rtx_cb): Declare.
      	(remove_free_INSN_LIST_NODE, remove_free_EXPR_LIST_node,
      	debug_bb_n_slim, debug_bb_slim,    print_rtl_slim): Likewise.
      	* vecprim.h: Add a vector type for unsigned int. 
      	* haifa-sched.c: Include vecprim.h and cfgloop.h.
      	(issue_rate, sched_verbose_param, note_list, dfa_state_size,
      	ready_try, cycle_issued_insns, spec_info): Make global.
      	(readyp): Initialize.
      	(dfa_lookahead): New global variable.
      	(old_max_uid, old_last_basic_block): Remove.
      	(h_i_d): Make it a vector.
      	(INSN_TICK, INTER_TICK, QUEUE_INDEX, INSN_COST): Make them work
      	through HID macro.
      	(after_recovery, adding_bb_to_current_region_p):
      	New variables to handle correct insertion of the recovery code.
      	(struct ready_list): Move declaration to sched-int.h.
      	(rgn_n_insns): Removed.
      	(rtx_vec_t): Move to sched-int.h.
      	(find_insn_reg_weight): Remove.
      	(find_insn_reg_weight1): Rename to find_insn_reg_weight.
      	(haifa_init_h_i_d, haifa_finish_h_i_d):
      	New functions to initialize / finalize haifa instruction data.
      	(extend_h_i_d, init_h_i_d): Rewrite.
      	(unlink_other_notes): Move logic to add_to_note_list.  Handle
      	selective scheduler.
      	(ready_lastpos, ready_element, ready_sort, reemit_notes,
      	find_fallthru_edge): Make global, remove static prototypes.
      	(max_issue): Make global.  Add privileged_n and state parameters.  Use
      	them.  
      	(extend_global, extend_all): Removed.
      	(init_before_recovery): Add new param.  Fix the handling of the case
      	when we insert a recovery code before the EXIT which has a predecessor
      	with a fallthrough edge to it.
      	(create_recovery_block): Make global.  Rename to
      	sched_create_recovery_block.  Update.
      	(change_pattern): Rename to sched_change_pattern.  Make global.
      	(speculate_insn): Rename to sched_speculate_insn.  Make global.
      	Split haifa-specific functionality into ...
      	(haifa_change_pattern): New static function.
      	(sched_extend_bb): New static function.
      	(sched_init_bbs): New function.
      	(current_sched_info): Change type to struct haifa_sched_info.
      	(insn_cost): Adjust for selective scheduling.
      	(dep_cost_1): New function.  Move logic from ...
      	(dep_cost): ... here.
      	(dep_cost): Use dep_cost_1.
      	(contributes_to_priority_p): Use sched_deps_info instead of
      	current_sched_info.
      	(priority): Adjust to work with selective scheduling.  Process the
      	corner case when all dependencies don't contribute to priority.
      	(rank_for_schedule): Use ds_weak instead of dep_weak.
      	(advance_state): New function.  Move logic from ...
      	(advance_one_cycle): ... here.
      	(add_to_note_list, concat_note_lists): New functions.
      	(rm_other_notes): Make static.  Adjust for selective scheduling.
      	(remove_notes, restore_other_notes): New functions.
      	(move_insn): Add two arguments.  Update assert.  Don't call
      	reemit_notes.
      	(choose_ready): Remove lookahead variable, use dfa_lookahead.
      	Remove more_issue, max_points.  Move the code to initialize
      	max_lookahead_tries to max_issue.
      	(schedule_block): Remove rgn_n_insns1 parameter.  Don't allocate
      	ready.  Adjust use of move_insn.  Call restore_other_notes.
      	(luid): Remove.
      	(sched_init, sched_finish): Move Haifa-specific initialization/
      	finalization to ...
      	(haifa_sched_init, haifa_sched_finish): ... respectively.
      	New functions.
      	(setup_sched_dump): New function.
      	(haifa_init_only_bb): New static function.
      	(haifa_speculate_insn): New static function.
      	(try_ready): Use haifa_* instead of speculate_insn and
      	change_pattern.
      	(extend_ready, extend_all): Remove.
      	(sched_extend_ready_list, sched_finish_ready_list): New functions.
      	(create_check_block_twin, add_to_speculative_block): Use
      	haifa_insns_init instead of extend_global.  Update to use new
      	initialization functions.  Change parameter.  Factor out code from
      	create_check_block_twin to ...
      	(sched_create_recovery_edges) ... this new function.
      	(add_block): Remove.
      	(sched_scan_info): New.
      	(extend_bb): Use sched_scan_info.
      	(init_bb, extend_insn, init_insn, init_insns_in_bb, sched_scan): New
      	static functions for walking through scheduling region.
      	(sched_luids): New vector variable to replace uid_to_luid.
      	(luids_extend_insn): New function.
      	(sched_max_luid): New variable.
      	(luids_init_insn): New function.
      	(sched_init_luids, sched_finish_luids): New functions.
      	(insn_luid): New debug function.
      	(sched_extend_target): New function.
      	(haifa_init_insn): New static function.
      	(sched_init_only_bb): New hook.
      	(sched_split_block): New hook.
      	(sched_split_block_1): New function.
      	(sched_create_empty_bb): New hook.
      	(sched_create_empty_bb_1): New function.	
      	(common_sched_info, ready): New global variables.
      	(current_sched_info_var): Remove.
      	(move_block_after_check): Use common_sched_info.		
      	(haifa_luid_for_non_insn): New static function.	
      	(init_before_recovery): Use haifa_init_only_bb instead of
      	add_block.
      	(increase_insn_priority): New.
      	* modulo-sched.c: (issue_rate): Remove static declaration.
      	(sms_sched_info): Change type to haifa_sched_info.
      	(sms_sched_deps_info, sms_common_sched_info): New variables.
      	(setup_sched_infos): New.
      	(sms_schedule): Initialize them.  Call haifa_sched_init/finish.
      	Do not call regstat_free_calls_crossed.
      	(sms_print_insn): Use const_rtx.
      	* params.def (PARAM_MAX_PIPELINE_REGION_BLOCKS,
      	PARAM_MAX_PIPELINE_REGION_INSNS, PARAM_SELSCHED_MAX_LOOKAHEAD,
      	PARAM_SELSCHED_MAX_SCHED_TIMES, PARAM_SELSCHED_INSNS_TO_RENAME,
      	PARAM_SCHED_MEM_TRUE_DEP_COST): New.
      	* sched-deps.c (sched_deps_info): New.  Update all relevant uses of
      	current_sched_info to use it.
      	(enum reg_pending_barrier_mode): Move to sched-int.h.
      	(h_d_i_d): New variable. Initialize to NULL.
      	({true, output, anti, spec, forward}_dependency_cache): Initialize
      	to NULL.
      	(estimate_dep_weak): Remove static declaration.
      	(sched_has_condition_p): New function.  Adjust users of
      	sched_get_condition to use it instead.
      	(conditions_mutex_p): Add arguments indicating which conditions are
      	reversed.  Use them.
      	(sched_get_condition_with_rev): Rename from sched_get_condition.  Add
      	argument to indicate whether returned condition is reversed.  Do not
      	generate new rtx when condition should be reversed; indicate it by
      	setting new argument instead.
      	(add_dependence_list_and_free): Add deps parameter.
      	Update all users.  Do not free dependence list when
      	deps context is readonly.
      	(add_insn_mem_dependence, flush_pending_lists): Adjust for readonly
      	contexts.
      	(remove_from_dependence_list, remove_from_both_dependence_lists): New.
      	(remove_from_deps): New. Use the above functions.	
      	(cur_insn, can_start_lhs_rhs_p): New static variables.
      	(add_or_update_back_dep_1): Initialize present_dep_type.
      	(haifa_start_insn, haifa_finish_insn, haifa_note_reg_set,
      	haifa_note_reg_clobber, haifa_note_reg_use, haifa_note_mem_dep,
      	haifa_note_dep): New functions implementing dependence hooks for
      	the Haifa scheduler.
      	(note_reg_use, note_reg_set, note_reg_clobber, note_mem_dep,
      	note_dep): New functions.
      	(ds_to_dt, extend_deps_reg_info, maybe_extend_reg_info_p): New
      	functions.
      	(init_deps): Initialize last_reg_pending_barrier and deps->readonly.
      	(free_deps): Initialize deps->reg_last.
      	(sched_analyze_reg, sched_analyze_1, sched_analyze_2,
      	sched_analyze_insn): Update to use dependency hooks infrastructure
      	and readonly contexts.
      	(deps_analyze_insn): New function.  Move part of logic from ...
      	(sched_analyze): ... here.  Also move some logic to ...
      	(deps_start_bb): ... here.  New function.
      	(add_forw_dep, delete_forw_dep): Guard use of INSN_DEP_COUNT with
      	sel_sched_p.
      	(sched_deps_init): New function.  Move code from ...
      	(init_dependency_caches): ... here.  Remove.
      	(init_deps_data_vector): New.
      	(sched_deps_finish): New function.  Move code from ...
      	(free_dependency_caches): ... here.  Remove.
      	(init_deps_global, finish_deps_global): Adjust for use with
      	selective scheduling.
      	(get_dep_weak): Move logic to ...
      	(get_dep_weak_1): New function.
      	(ds_merge): Move logic to ...
      	(ds_merge_1): New static function.
      	(ds_full_merge, ds_max_merge, ds_get_speculation_types): New functions.
      	(ds_get_max_dep_weak): New function.
      	* sched-ebb.c (sched_n_insns): Rename to sched_rgn_n_insns.
      	(n_insns): Rename to rgn_n_insns.
      	(debug_ebb_dependencies): New function.
      	(init_ready_list): Use it.
      	(begin_schedule_ready): Use sched_init_only_bb.
      	(ebb_print_insn): Indicate when an insn starts a new cycle.
      	(contributes_to_priority, compute_jump_reg_dependencies,
      	add_remove_insn, fix_recovery_cfg): Add ebb_ prefix to function names.
      	(add_block1): Remove to ebb_add_block.
      	(ebb_sched_deps_info, ebb_common_sched_info): New variables.
      	(schedule_ebb): Initialize them.  Use remove_notes instead of
      	rm_other_notes.  Use haifa_local_init/finish.
      	(schedule_ebbs): Use haifa_sched_init/finish.
      	* sched-int.h: Include vecprim.h, remove rtl.h.
      	(struct ready_list): Delete declaration.
      	(sched_verbose_param, enum sched_pass_id_t,
      	bb_vec_t, insn_vec_t, rtx_vec_t): New.
      	(struct sched_scan_info_def): New structure.
      	(sched_scan_info, sched_scan, sched_init_bbs,
      	sched_init_luids, sched_finish_luids, sched_extend_target,
      	haifa_init_h_i_d, haifa_finish_h_i_d): Declare.
      	(struct common_sched_info_def): New.
      	(common_sched_info, haifa_common_sched_info,
      	sched_emulate_haifa_p): Declare.
      	(sel_sched_p): New.
      	(sched_luids): Declare.
      	(INSN_LUID, LUID_BY_UID, SET_INSN_LUID): Declare.
      	(sched_max_luid, insn_luid): Declare.
      	(note_list, remove_notes, restore_other_notes, bb_note): Declare.
      	(sched_insns_init, sched_insns_finish, xrecalloc, reemit_notes,
      	print_insn, print_pattern, print_value, haifa_classify_insn,
      	sel_find_rgns, sel_mark_hard_insn, dfa_state_size, advance_state,
      	setup_sched_dump, sched_init, sched_finish,
      	sel_insn_is_speculation_check): Export.
      	(struct ready_list): Move from haifa-sched.c.
      	(ready_try, ready, max_issue): Export.
      	(ebb_compute_jump_reg_dependencies, find_fallthru_edge,
      	sched_init_only_bb, sched_split_block, sched_split_block_1,
      	sched_create_empty_bb, sched_create_empty_bb_1,
      	sched_create_recovery_block, sched_create_recovery_edges): Export.
      	(enum reg_pending_barrier_mode): Export.
      	(struct deps): New fields `last_reg_pending_barrier' and `readonly'.
      	(deps_t): New.
      	(struct sched_info): Rename to haifa_sched_info.  Use const_rtx for
      	print_insn field.  Move add_block and fix_recovery_cfg to
      	common_sched_info_def.  Move compute_jump_reg_dependencies, use_cselib  ...
      	(struct sched_deps_info_def): ... this new structure.
      	(sched_deps_info): Declare.
      	(struct spec_info_def): Remove weakness_cutoff, add
      	data_weakness_cutoff and control_weakness_cutoff.
      	(spec_info): Declare.
      	(struct _haifa_deps_insn_data): Split from haifa_insn_data.  Add
      	dep_count field.
      	(struct haifa_insn_data): Rename to struct _haifa_insn_data.
      	(haifa_insn_data_def, haifa_insn_data_t): New typedefs.
      	(current_sched_info): Change type to struct haifa_sched_info.
      	(haifa_deps_insn_data_def, haifa_deps_insn_data_t): New typedefs.
      	(h_d_i_d): New variable.
      	(HDID): New accessor macro.
      	(h_i_d): Change type to VEC (haifa_insn_data_def, heap) *.
      	(HID): New accessor macro.  Rewrite h_i_d accessor macros through HID
      	and HDID.
      	(IS_SPECULATION_CHECK_P): Update for selective scheduler.
      	(enum SCHED_FLAGS): Update for selective scheduler.
      	(enum SPEC_SCHED_FLAGS): New flag SEL_SCHED_SPEC_DONT_CHECK_CONTROL.
      	(init_dependency_caches, free_dependency_caches): Delete declarations.
      	(deps_analyze_insn, remove_from_deps, get_dep_weak_1,
      	estimate_dep_weak, ds_full_merge, ds_max_merge, ds_weak,
      	ds_get_speculation_types, ds_get_max_dep_weak, sched_deps_init,
      	sched_deps_finish, haifa_note_reg_set, haifa_note_reg_use,
      	haifa_note_reg_clobber, maybe_extend_reg_info_p, deps_start_bb,
      	ds_to_dt): Export.
      	(rm_other_notes): Delete declaration.
      	(schedule_block): Remove one argument.
      	(cycle_issued_insns, issue_rate, dfa_lookahead, ready_sort,
      	ready_element, ready_lastpos, sched_extend_ready_list,
      	sched_finish_ready_list, sched_change_pattern, sched_speculate_insn,
      	concat_note_lists): Export.
      	(struct region): Move from sched-rgn.h.
      	(nr_regions, rgn_table, rgn_bb_table, block_to_bb, containing_rgn,
      	RGN_NR_BLOCKS, RGN_BLOCKS, RGN_DONT_CALC_DEPS, RGN_HAS_REAL_EBB,
      	BLOCK_TO_BB, CONTAINING_RGN): Export.
      	(ebb_head, BB_TO_BLOCK, EBB_FIRST_BB, EBB_LAST_BB, INSN_BB): Likewise.
      	(current_nr_blocks, current_blocks, target_bb): Likewise.
      	(dep_cost_1, sched_is_disabled_for_current_region_p, sched_rgn_init,
      	sched_rgn_finish, rgn_setup_region, sched_rgn_compute_dependencies,
      	sched_rgn_local_init, extend_regions,
      	rgn_make_new_region_out_of_new_block, compute_priorities,
      	debug_rgn_dependencies, free_rgn_deps, contributes_to_priority,
      	extend_rgns, deps_join rgn_setup_common_sched_info,
      	rgn_setup_sched_infos, debug_regions, debug_region, dump_region_dot,
      	dump_region_dot_file, haifa_sched_init, haifa_sched_finish): Export.
      	(get_rgn_sched_max_insns_priority, sel_add_to_insn_priority, 
      	increase_insn_priority): Likewise.
      	* sched-rgn.c: Include sel-sched.h.
      	(ref_counts): New static variable.  Use it ...
      	(INSN_REF_COUNT): ... here.  Rewrite and move closer to uses.
      	(FED_BY_SPEC_LOAD, IS_LOAD_INSN): Rewrite to use HID accessor macro.
      	(sched_is_disabled_for_current_region_p): Delete static declaration.
      	(struct region): Move to sched-int.h.
      	(nr_regions, rgn_table, rgn_bb_table, block_to_bb, containing_rgn,
      	ebb_head): Define and initialize.
      	(RGN_NR_BLOCKS, RGN_BLOCKS, RGN_DONT_CALC_DEPS, RGN_HAS_REAL_EBB,
      	BLOCK_TO_BB, CONTAINING_RGN, debug_regions, extend_regions,
      	BB_TO_BLOCK, EBB_FIRST_BB, EBB_LAST_BB): Move to
      	sched-int.h.
      	(find_single_block_region): Add new argument to indicate that EBB
      	regions should be constructed.
      	(debug_live): Delete declaration.
      	(current_nr_blocks, current_blocks, target_bb): Remove static qualifiers.
      	(compute_dom_prob_ps, check_live, update_live, set_spec_fed): Delete
      	declaration.
      	(init_regions): Delete declaration.
      	(debug_region, bb_in_region_p, dump_region_dot_file, dump_region_dot,
      	rgn_estimate_number_of_insns): New.
      	(too_large): Use estimate_number_of_insns.
      	(haifa_find_rgns): New. Move the code from ...
      	(find_rgns): ... here.  Call either sel_find_rgns or haifa_find_rgns.
      	(free_trg_info): New.
      	(compute_trg_info): Allocate candidate tables here instead of ...
      	(init_ready_list): ... here.
      	(rgn_print_insn): Use const_rtx.
      	(contributes_to_priority, extend_regions): Delete static declaration.
      	(add_remove_insn, fix_recovery_cfg): Add rgn_ to function names.
      	(add_block1): Rename to rgn_add_block.
      	(debug_rgn_dependencies): Delete static qualifier.
      	(new_ready): Use sched_deps_info.  Simplify.
      	(rgn_common_sched_info, rgn_const_sched_deps_info,
      	rgn_const_sel_sched_deps_info, rgn_sched_deps_info, rgn_sched_info): New.
      	(region_sched_info): Rename to rgn_const_sched_info.
      	(deps_join): New, extracted from ...
      	(propagate_deps): ... here.
      	(compute_block_dependences, debug_dependencies): Update for selective
      	scheduling.
      	(free_rgn_deps, compute_priorities): New functions.
      	(sched_rgn_init, sched_rgn_finish, rgn_setup_region,
      	sched_rgn_compute_dependencies): New functions.
      	(schedule_region): Use them.
      	(sched_rgn_local_init, sched_rgn_local_free, sched_rgn_local_finish,
      	rgn_setup_common_sched_info, rgn_setup_sched_infos):
      	New functions.
      	(schedule_insns): Call new functions that were split out.
      	(rgn_make_new_region_out_of_new_block): New.
      	(get_rgn_sched_max_insns_priority): New.
      	(rest_of_handle_sched, rest_of_handle_sched2): Call selective
      	scheduling when appropriate.
      	* sched-vis.c: Include insn-attr.h.
      	(print_value, print_pattern): Make global.
      	(print_rtl_slim, debug_bb_slim, debug_bb_n_slim): New functions.
      	* target-def.h (TARGET_SCHED_ADJUST_COST_2,
      	TARGET_SCHED_ALLOC_SCHED_CONTEXT, TARGET_SCHED_INIT_SCHED_CONTEXT,
      	TARGET_SCHED_SET_SCHED_CONTEXT, TARGET_SCHED_CLEAR_SCHED_CONTEXT,
      	TARGET_SCHED_FREE_SCHED_CONTEXT, TARGET_SCHED_GET_INSN_CHECKED_DS,
      	TARGET_SCHED_GET_INSN_SPEC_DS, TARGET_SCHED_SKIP_RTX_P): New target
      	hooks.  Initialize them to 0.
      	(TARGET_SCHED_GEN_CHECK): Rename to TARGET_SCHED_GEN_SPEC_CHECK.
      	* target.h (struct gcc_target): Add them.  Rename gen_check field to
      	gen_spec_check.
      	* flags.h (sel_sched_switch_set): Declare.
      	* opts.c (sel_sched_switch_set): New variable.
      	(decode_options): Unset flag_sel_sched_pipelining_outer_loops if
      	pipelining is disabled from command line.
      	(common_handle_option): Record whether selective scheduling is
      	requested from command line.
      	* doc/invoke.texi: Document new flags and parameters.
      	* doc/tm.texi: Document new target hooks.
      	* config/ia64/ia64.c (TARGET_SCHED_GEN_SPEC_CHECK): Define to ia64_gen_check.
      	(dfa_state_size): Do not declare locally.
      	* config/ia64/ia64.opt (msched-ar-data-spec): Default to 0.
      	* config/rs6000/rs6000.c (rs6000_init_sched_context,
      	rs6000_alloc_sched_context, rs6000_set_sched_context,
      	rs6000_free_sched_context): New functions.
      	(struct _rs6000_sched_context): New.
      	(rs6000_sched_reorder2): Do not modify INSN_PRIORITY for selective
      	scheduling.
      	(rs6000_sched_finish): Do not run for selective scheduling. 
      
      Co-Authored-By: Alexander Monakov <amonakov@ispras.ru>
      Co-Authored-By: Dmitry Melnik <dm@ispras.ru>
      Co-Authored-By: Dmitry Zhurikhin <zhur@ispras.ru>
      Co-Authored-By: Maxim Kuvyrkov <maxim@codesourcery.com>
      
      From-SVN: r139854
      Andrey Belevantsev committed
  6. 31 Aug, 2008 1 commit
    • fwprop.c (should_replace_address): Add speed attribute. · f40751dd
      	* fwprop.c (should_replace_address): Add speed attribute.
      	(PR_OPTIMIZE_FOR_SPEED): New flag.
      	(propagate_rtx_1): Use it.
      	(propagate_rtx): Set it.
      	(try_fwprop_subst): Update call of rtx_costs.
      	(forward_propagate_and_simplify): LIkewise.
      	* hooks.c (hook_int_rtx_bool_0): New
      	(hook_bool_rtx_int_int_intp_false): Replace by ...
      	(hook_bool_rtx_int_int_intp_bool_false): .. thisone.
      	* hooks.h (hook_int_rtx_bool_0): New
      	(hook_bool_rtx_int_int_intp_false): Replace by ...
      	(hook_bool_rtx_int_int_intp_bool_false): .. thisone.
      	* optabs.c (avoid_expensive_constant): UPdate call of rtx_cost.
      	(prepare_cmp_insn): UPdate call of rtx_cost.
      	* postreload.c (reload_cse_simplify_set): Update call of rtx_cost.
      	(reload_cse_simplify_operands): Update call of rtx_cost.
      	(reload_cse_move2add): call of rtx_cost.
      	* target.h (struct gcc_target): Update rtx_costs and address_costs.
      	* rtlanal.c (rtx_cost): Add speed argument.
      	(address_cost): Add speed argument
      	(default_address_cost): Likewise.
      	(insn_rtx_cost): Likewise.
      	* cfgloopanal.c (seq_cost): Add speed argument.
      	(target_reg_cost, target_spill_cost): Turn to array.
      	(init_set_costs): Update for speed.
      	(estimate_reg_pressure_cost): Add speed argument.
      	* auto-inc-dec.c (attempt_change): Update call of rtx_cost.
      	* dojump.c (prefer_and_bit_test): UPdate call of rtx_cost.
      	* tree-ssa-loop-ivopts.c (struct ivopts_data): New field speed.
      	(seq_cost): Add speed argument.
      	(computation_cost): Add speed arugment.
      	(add_cost, multiply_by_const, get_address_cost): add speed argument.
      	(force_expr_to_var_cost): Update for profile info.
      	(force_var_cost): Likewise.
      	(split_address_cost): Likewise.
      	(ptr_difference_cost): Likewise.
      	(difference_cost): Likewise.
      	(get_computation_cost_at): Likewise.
      	(determine_iv_cost): Likewise.
      	(ivopts_global_cost_for_size): Likewise.
      	(rewrite_use_address): Likewise.
      	(tree_ssa_iv_optimize_loop): Initialize speed field.
      	* cse.c (optimize_this_for_speed_p): New static var.
      	(notreg_cost): Update call of rtx_cost.
      	(cse_extended_basic_block): set optimize_this_for_speed_p.
      	* ifcvt.c (cheap_bb_rtx_cost_p): Update call of rtx_cost.
      	(noce_try_cmove_arith): Likewise.
      	(noce_try_sign_mask): LIkewise.
      	* expr.c (compress_float_constant): Update rtx_cost calls.
      	* tree-ssa-address.c (most_expensive_mult_to_index): Add speed argument.
      	(addr_to_parts): Likewise.
      	(create_mem_ref): Likewise.
      	* dse.c (find_shift_sequence): Add speed argument.
      	(replace_read): Update call.
      	* calls.c (precompute_register_parameters): Update call of rtx_cost.
      	* expmed.c (sdiv_pow2_cheap, smod_pow2_cheap, zero_cost, add_cost,
      	* neg_cost, shift_cost, shiftadd_cost,
      	shiftsub_cost, mul_cost, sdiv_cost, udiv_cost ,mul_widen_cost,
      	mul_highpart_cost): Increase dimension.
      	(init_expmed): Initialize for both size and speed.
      	(expand_shift): Use profile.
      	(synth_mult): Use profile.
      	(choose_mult_variant): Use profile.
      	(expand_mult): Use profile.
      	(expand_mult_highpart_optab): Use profile.
      	(expand_mult_highpart): Use profile.
      	(expand_smod_pow2): Use profile.
      	(expand_divmod): Use profile.
      	* simplify-rtx.c (simplify_binary_operation_1): Update call of rtx_cost.
      	* loop-invariant.c (create_new_invariant): Use profile.
      	(gain_for_invariant): Add speed parameter.
      	(best_gain_for_invariant): Likewise.
      	(find_invariants_to_move): Likewise.
      	(move_single_loop_invariants): Set it.
      	* target-def.h (TARGET_RTX_COSTS): Use hook.
      	* rtl.h (rtx_cost, address_cost, insn_rtx_cost): Update prototpe.
      	(optimize_insn_for_size_p, optimize_insn_for_speed_p): Declare.
      	* output.h (default_address_cost): Update prototype.
      	* combine.c (optimize_this_for_speed_p): New static var.
      	(combine_validate_cost): Update call of rtx_cost.
      	(combine_instructions): Set optimize_this_for_speed_p.
      	(expand_compound_operation): Update call of rtx_cost.
      	(make_extraction):Update call of rtx_cost.
      	(force_to_mode):Update call of rtx_cost.
      	(distribute_and_simplify_rtx):Update call of rtx_cost.
      	* cfgloop.h (target_reg_cost, target_spill_cost): Turn to array.
      	(estimate_reg_pressure_cost): Update prototype.
      	* tree-flow.h (multiply_by_cost, create_mem_ref): Update prototype.
      	* basic-block.h (optimize_insn_for_size_p, optimize_insn_for_speed_p):
      	Remove.
      	* config/alpha/alpha.c (alpha_rtx_costs): Update.
      	(alpha_rtx_costs): Update.
      	* config/frv/frv.c (frv_rtx_costs): Update.
      	* config/s390/s390.c (s390_rtx_costs): Update.
      	* config/m32c/m32c.c (m32c_memory_move_cost): Update.
      	(m32c_rtx_costs): Update.
      	* config/spu/spu.c (TARGET_ADDRESS_COST): Upate.
      	(spu_rtx_costs): Update.
      	* config/sparc/sparc.c (sparc_rtx_costs): Update.
      	* config/m32r/m32r.c (m32r_rtx_costs): Update.
      	* config/i386/i386.c (:ix86_address_cost): Update.
      	(ix86_rtx_costs): Update.
      	* config/sh/sh.c (sh_rtx_costs, sh_address_cost): Update.
      	* config/pdp11/pdp11.c (pdp11_rtx_costs): Update.
      	* config/avr/avr.c (avr_rtx_costs, avr_address_cost): Update.
      	* config/crx/crx.c (crx_address_cost): Update.
      	* config/xtensa/xtensa.c (xtensa_rtx_costs): Update.
      	* config/stormy16/stormy16.c
      	(xstormy16_address_cost, xstormy16_rtx_costs): Update.
      	* config/m68hc11/m68hc11.c
      	(m68hc11_address_cost, m68hc11_rtx_costs): Update.
      	* config/cris/cris.c (cris_rtx_costs, cris_address_cost): Update.
      	* config/iq2000/iq2000.c (iq2000_rtx_costs, iq2000_address_cost): Update.
      	* config/mn10300/mn10300.c (mn10300_address_cost, mn10300_rtx_costs): Update
      	* config/ia64/ia64.c (ia64_rtx_costs): Update.
      	* config/m68k/m68k.c (m68k_rtx_costs): Update.
      	* config/rs6000/rs6000.c (rs6000_rtx_costs): Update.
      	* config/arc/arc.c (arc_rtx_costs, arc_address_cost): Update.
      	* config/mcore/mcore.c (TARGET_ADDRESS_COST): Update.
      	(mcore_rtx_costs): update.
      	* config/score/score3.c (score3_rtx_costs): Update.
      	* config/score/score7.c (score7_rtx_costs): Update.
      	* config/score/score3.h (score3_rtx_costs):Update.
      	* config/score/score7.h (score7_rtx_costs): Update.
      	* config/score/score.c (score_rtx_costs): Update.
      	* config/arm/arm.c (arm_address_cost): Update.
      	(arm_rtx_costs_1): Update.
      	(arm_rtx_costs_1): Update.
      	(arm_size_rtx_costs): Update.
      	(arm_size_rtx_costs): Update.
      	(arm_size_rtx_costs): Update.
      	(arm_xscale_rtx_costs): Update.
      	(arm_thumb_address_cost): Update.
      	* config/pa/pa.c (hppa_address_cost): Update.
      	* config/mips/mips.c (mips_rtx_costs): Update.
      	* config/vax/vax.c (vax_address_cost): Update.
      	* config/h8300/h8300.c (h8300_shift_costs): Update.
      	(h8300_rtx_costs): Update.
      	* config/v850/v850.c (TARGET_ADDRESS_COST): Update.
      	(v850_rtx_costs): Update.
      	* config/mmix/mmix.c (mmix_rtx_costs, mmix_rtx_costs): Update.
      	* config/bfin/bfin.c
      	(bfin_address_cost): Update.
      	(bfin_rtx_costs): Update.
      	* stmt.c (lshift_cheap_p): Update.
      
      From-SVN: r139821
      Jan Hubicka committed
  7. 15 Jul, 2008 1 commit
    • bt-load.c (add_btr_def, [...]): Avoid C++ keywords. · 32e9fa48
      	* bt-load.c (add_btr_def, migrate_btr_def,
      	branch_target_load_optimize): Avoid C++ keywords.
      	* caller-save.c (insert_restore, insert_save, insert_one_insn):
      	Likewise.
      	* combine.c (subst, simplify_set, make_extraction,
      	make_compound_operation, known_cond, simplify_shift_const_1):
      	Likewise.
      	* cse.c (make_regs_eqv, merge_equiv_classes, validate_canon_reg,
      	fold_rtx, equiv_constant, cse_insn, cse_process_notes_1):
      	Likewise.
      
      From-SVN: r137847
      Kaveh R. Ghazi committed
  8. 26 Jun, 2008 1 commit
    • cse.c (approx_reg_cost_1, cse_insn): Fix -Wc++-compat and/or -Wcast-qual warnings. · 7cbb2a85
      	* cse.c (approx_reg_cost_1, cse_insn): Fix -Wc++-compat and/or
      	-Wcast-qual warnings.
      	* gcc.c (process_command): Likewise.
      	* genattrtab.c (oballoc): Use XOBNEW.
      	(oballocvec): Define.
      	(attr_hash_add_rtx, attr_hash_add_string, attr_string,
      	get_attr_value, fill_attr, make_length_attrs, gen_attr, gen_insn,
      	gen_delay, find_attr, gen_insn_reserv, gen_bypass_1): Fix
      	-Wc++-compat and/or -Wcast-qual warnings.
      	* genautomata.c (XCREATENODE, XCREATENODEVEC, XCREATENODEVAR,
      	XCOPYNODE, XCOPYNODEVEC, XCOPYNODEVAR): New.
      	(gen_cpu_unit, gen_query_cpu_unit, gen_bypass, gen_excl_set,
      	gen_presence_absence_set, gen_automaton, gen_regexp_el,
      	gen_regexp_repeat, gen_regexp_allof, gen_regexp_oneof,
      	gen_regexp_sequence, gen_reserv, gen_insn_reserv, process_excls,
      	add_excls, process_presence_absence_names,
      	process_presence_absence_patterns, add_presence_absence,
      	process_regexp, add_advance_cycle_insn_decl, get_free_alt_state,
      	get_free_state, add_arc, get_free_automata_list_el,
      	form_reserv_sets_list, copy_insn_regexp, transform_1, transform_2,
      	transform_3, cache_presence, create_ainsns, create_automata,
      	create_state_ainsn_table, dfa_insn_code_enlarge,
      	output_trans_func, output_min_issue_delay_func,
      	output_dead_lock_func, output_reset_func,
      	output_get_cpu_unit_code_func, output_dfa_start_func,
      	expand_automata): Likewise.
      	* genextract.c (gen_insn): Likewise.
      	* gengtype-lex.l: Likewise.
      	* gengtype.c (read_input_list, adjust_field_type,
      	process_gc_options): Likewise.
      	* genoutput.c (note_constraint): Likewise.
      	* genpreds.c (mangle, add_constraint): Likewise.
      	* genrecog.c (process_define_predicate, new_decision,
      	add_to_sequence): Likewise.
      	* gensupport.c (record_insn_name): Likewise.
      
      From-SVN: r137135
      Kaveh R. Ghazi committed
  9. 17 Jun, 2008 1 commit
    • Remove libcall notes. · 4a8cae83
      	* see.c (see_analyse_one_def): Do not look for REG_LIBCALL and
      	REG_RETVAL notes.
      	(see_update_relevancy): Likewise.
      	* fwprop.c (try_fwprop_subst): Likewise.
      	* rtlanal.c (noop_move_p): Likewise.
      	* builtins.c (expand_buitlin_mathfn): Don't try to add REG_EQUAL
      	notes to non-existing libcall blocks.
      	* cse.c (cse_insn): Change prototype.  Don't update libcall notes.
      	Remove orig_set.
      	(cse_extended_basic_block): Don't track libcall and no-conflict notes.
      	(dead_libcall_p): Remove.
      	(delete_trivially_dead_insns): Don't use it.
      	* web.c (union_defs): Remove comment about keeping nops.
      	* gcse.c (hash_scan_insn): Don't take libcall pointers.
      	(compute_hash_table_work): Don't track libcall notes.
      	(do_local_cprop): Don't take libcall pointers.  Don't update
      	libcall notes.
      	(adjust_libcall_notes): Deleted.
      	(local_cprop_pass): Remove stack for nested libcalls (which shouldn't
      	ever have existed in the first place).
      	(replace_store_insn): Don't try to remove libcall notes.
      	* lower-subreg.c (move_libcall_note, move_retval_note): Deleted.
      	(resolve_reg_notes): Don't call them.
      	(resolve_simple_move): Likewise.
      	(decompose_multiword_subregs): Remove block handling REG_RETVAL notes.
      	Don't remove REG_RETVAL notes.
      	* emit-rtl.c (try_split): Don't update libcall notes.
      	(emit_copy_of_insn_after): Dito.
      	* cselib.c (cselib_current_insn_in_libcall): Remove.
      	(cselib_process_insn): Don't set/clear it.
      	(new_elt_loc_list): Don't record it.
      	(cselib_init): Don't initialize it.
      	* cselib.c (struct elt_loc_list): Remove in_libcall field.
      	* loop-invariant.c (find_invariant_insn): Don't look for libcall
      	notes.
      	* sched-deps.c (sched_analyze_insn): Don't group libcall blocks.
      	(sched_analyze): Don't set up deps->libcall_block_tail_insn.
      	(init_deps): Don't initialize it.
      	* sched-int.h (struct deps): Rremove libcall_block_tail_insn field.
      	* combine.c (delete_noop_moves): Don't update libcall notes.
      	(can_combine_p): Remove now pointless #if 0 block.
      	(try_combine): Remove another obsolete #if 0 block.
      	(distribute_notes): Don't distribute libcall notes.
      	* reg-notes.def (REG_LIBCALL, REG_RETVAL): Remove.
      	* dce.c (libcall_dead_p): Remove.
      	(delete_unmarked_insns): Don't handle libcall blocks.
      	(preserve_libcall_for_dce): Remove.
      	(prescan_insns_for_dce): Don't special-case libcall block insns.
      	* reload1 (reload): Don't handle libcall notes. 
      	* doc/rtl.texi (REG_LIBCALL, REG_RETVAL, REG_LIBCALL_ID): Remove
      	documentation.
      
      From-SVN: r136861
      Steven Bosscher committed
  10. 06 Jun, 2008 1 commit
  11. 14 May, 2008 2 commits
    • rtl.texi: Removed reference to REG_NO_CONFLICT notes. · d70dcf29
      2008-05-14  Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	* doc/rtl.texi: Removed reference to REG_NO_CONFLICT notes.
      	* optabs.c (expand_binop, expand_absneg_bit, expand_unop,
      	expand_copysign_bit, ): Change call to emit_no_conflict_block to
      	emit_insn and remove unneeded code to construct extra args.
      	(emit_no_conflict_block): Removed.
      	* optabls.h: (emit_no_conflict_block): Removed.
      	* cse.c (cse_extended_basic_block): Remove search for
      	REG_NO_CONFLICT note.  
      	* global.c: Removed incorrect comment added in revision 117.
      	* expr.c (convert_move): Change call to emit_no_conflict_block to
      	emit_insn.
      	* recog.c: Change comments so that they do not mention
      	REG_NO_CONFLICT.
      	* local_alloc.c (combine_regs): Removed last parameter.
      	(no_conflict_p): Removed.
      	(block_alloc): Removed note, no_conflict_combined_regno and set
      	local vars. Removed all code to process REG_NO_CONFLICT blocks.
      	(combine_regs): Removed already_dead and code to look for
      	REG_NO_CONFLICT notes.
      	* lower_subreg (remove_retval_note): Removed code to look for
      	REG_NO_CONFLICT block.
      	(resolve_reg_notes): Removed REG_NO_CONFLICT case.
      	(resolve_clobber): Remove code to process libcalls that have
      	REG_NO_CONFLICT notes.
      	* loop_invariant.c (find_invariant_insn): Removed REG_NO_CONFLICT
      	case.
      	* combine.c (can_combine_p, distribute_notes):  Removed REG_NO_CONFLICT
      	case.
      	* config/cris/cris.md (movdi pattern): Changed
      	emit_no_conflict_block to emit_insns.
      	* config/mn10300/mn10300.md (absdf2, negdf2 patterns): Ditto.
      	* config/m68k/m68k.md (negdf2, negxf2, absdf2, absxf2 patterns):
      	Ditto. 
      	* reg-notes.def (NO_CONFLICT): Removed.
      
      From-SVN: r135289
      Kenneth Zadeck committed
    • cse.c (cse_cc_succs): Invoke delete_insn_and_edges. · 0beb3d66
      2008-05-14  Andreas Krebbel  <krebbel1@de.ibm.com>
      
      	* cse.c (cse_cc_succs): Invoke delete_insn_and_edges.
      
      2008-05-14  Andreas Krebbel  <krebbel1@de.ibm.com>
      
      	* g++.dg/eh/080513-1.C: New testcase.
      
      From-SVN: r135281
      Andreas Krebbel committed
  12. 07 May, 2008 1 commit
    • [multiple changes] · becfd6e5
      2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
      
              PATCH rtl/7335
              PATCH rtl/33826
              * see.c (see_copy_insn): Copy new pure const attributes for new
              call.
              * c-decl.c (merge_decls): Ditto.
              * postreload.c (record_opr_changes): Change CONST_OR_PURE_CALL_P
              to RTL_CONST_OR_PURE_CALL_P.
              * tree.c (define_local_buitin): Rename DECL_IS_PURE to
              DECL_PURE_P.  Initialized DECL_LOOPING_CONST_PURE.
              (process_call_operands): Set tree_side_effects properly.
              * tree.h (TREE_READONLY_DECL_P): Removed.
              (DECL_IS_PURE): Renamed to DECL_PURE_P.
              (DECL_LOOPING_OR_CONST_P): New macro.
              (struct tree_function_decl): Added looping_const_or_pure_p.
              (ECF_*) Renumbered.
              (ECF_LOOPING_OR_CONST_P): New macro,
              * rtlanal.c (pure_const_p): Removed.
              * builtins.c (expand_builtin): Rename DECL_IS_PURE to DECL_PURE_P.
              * reorg.c (delete_prior_computation) Changed CONST_OR_PURE_CALL_P
              to RTL_CONST_CALL_P.
              * ipa-pure-const.c (pure_const_state_e): Added looping field.
              (check_decl, check_tree, check_call, scan_function): Initialize
              looping.
              (analyze_function): Rename DECL_IS_PURE to DECL_PURE_P.
              (static_execute): Set looping true for recursive functions.
              Undo setting state to IPA_NEITHER for recursive functions.
              * cse.c (cse_insn): 
              * ifcvt.c (noce_can_store_speculate_p): Changed
              CONST_OR_PURE_CALL_P and pure_call_p to RTL_CONST_CALL_P or 
              RTL_CONST_OR_PURE_CALL_P.
              * dse.c (scan_insn): Ditto.
              * local-alloc.c (validate_equiv_mem, memref_used_between_p): Ditto.
              * gcse.c (oprs_not_seen_p) Changed CONST_OR_PURE_CALL_P to
              RTL_CONST_OR_PURE_CALL_P.
              (store_killed_in_insn): Changed CONST_OR_PURE_CALL_P and
              pure_call_p to RTL_CONST_CALL_P.
              * gimplify.c (gimplify_call_expr): Clear side effects for
              non-looping pure and constant calls.
              * calls.c (emit_call_1): Set rtl flags from ecf flags.
              (flags_from_decl_or_type): Set ecf flags from decl flags.
              (initialize_argument_information): Turn off
              ECF_LOOPING_CONST_OR_PURE when turning off ECF_CONST.
              Change const to pure if callee_copies is true rather than just
              turning off const.
              (expand_call): Turn off ECF_LOOPING_PURE_CONST_CALL and remove old
              way of marking pure calls.
              (emit_library_call_value_1): Turn off ECF_LOOPING_PURE_CONST_CALL.
              Remove hack that was supposed to fix pr7335 and remove old
              way of marking pure calls.
              * emit-rtl.c (emit_copy_of_insn_after): Copy RTL_CONST_CALL_P,
              RTL_PURE_CALL_P, RTL_LOOPING_CONST_OR_PURE_CALL_P.
              * cselib.c (cselib_process_insn): Changed CONST_OR_PURE_CALL_P to
              RTL_CONST_OR_PURE_CALL_P.
              * tree-ssa-pre.c (can_value_number_call): Fixed spacing.
              * loop-invariant.c (find_exits, find_invariant_bb): Changed
              CONST_OR_PURE_CALL_P to RTL_CONST_OR_PURE_CALL_P.
              * sched-deps.c (schedule_analyze): Ditto.
              * rtl.h (struct rtx_def): Use call field, unchanging field, and
              return_val field of calls to represent pure and const function
              info.
              (CONST_OR_PURE_CALL_P): Deleted macro.
              (RTL_CONST_CALL_P, RTL_PURE_CALL_P,
              RTL_LOOPING_CONST_OR_PURE_CALL_P, RTL_CONST_OR_PURE_P): New macros.
              * tree-inline.c (copy_body_r): Changed TREE_READONLY_DECL_P to
              TREE_READONLY.
              * tree-optimize.c (execute_fixup_cfg): Added test for
              ECF_LOOPING_CONST_OR_PURE.
              * c-common.c (handle_pure_attribute): Changed DECL_IS_PURE to
              DECL_PURE_P.
              * tree-cfg.c (update_call_expr_flags): Do not clear tree side
              effects for looping pure or const calls.
              (verify_gimple_expr): Added verification code. 
              * config/alpha/alpha.c (alpha_legitimize_address,
              alpha_emit_xfloating_libcall): Changed CONST_OR_PURE_CALL_P to
              RTL_CONST_CALL_P.
              * config/s390/s390.c (s390_emit_tls_call_insn): Ditto.
              * config/rs6000/rs6000.c (rs6000_legitimize_tls_address): Ditto.
              * config/mips/mips.c (mips_call_tls_get_addr): Ditto.
              * cfgrtl.c (need_fake_edge_p): Changed CONST_OR_PURE_CALL_P to
              RTL_CONST_OR_PURE_CALL_P.
              * dce.c (deletable_insn_p): Allow non looping, non sibling, pure
              and const calls to be deleted.
      
      java:
      2008-05-07  Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	* decl.c (java_init_decl_processing): Change DECL_IS_PURE to
      	DECL_PURE_P.
      
      cp:
      2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	 * decl.c (duplicate_decls): Merge in DECL_PURE_P, TREE_READONLY,
      	 DECL_LOOPING_CONST_OR_PURE_P attributes.
      	 * rtti.c (build_dynamic_cast_1): Rename DECL_IS_PURE to
      	 DECL_PURE_P.
      
      gfortran:
      2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	 * trans-decl.c (gfc_get_extern_function_decl, build_function_decl):
      	 Rename DECL_IS_PURE to DECL_PURE_P.
      
      From-SVN: r135053
      Kenneth Zadeck committed
  13. 19 Mar, 2008 1 commit
    • re PR other/35094 (RTL dump file letters hosed and partly undocumented) · 8ddbbcae
      	* gcc.dg/20050811-2.c: Update dumping flags.
      	* gcc.dg/sms-2.c: Update dumping flags.
      	* gcc.dg/var-expand1.c: Update dumping flags.
      	* gcc.dg/var-expand3.c: Update dumping flags.
      	* gcc.dg/pr30957-1.c: Update dumping flags.
      	* gcc.dg/20050811-1.c: Update dumping flags.
      	* gcc.dg/cpp/cmdlne-dI-M.C: Do not xfail.
      	* gcc.dg/cpp/cmdlne-dM-M.C: Do not xfail.
      
      	PR other/35094
      	* toplev.c (decode_d_option): Handle all CPP flags.
      	* tree-vrp.c: Update tree_pass descriptors.
      	* regrename.c: Update tree_pass descriptors.
      	* fwprop.c: Update tree_pass descriptors.
      	* doc/invoke.texi: Remove documentation of dropped -d? flags.
      	* tree-into-ssa.c: Update tree_pass descriptors.
      	* tree-dump.c: Update tree_pass descriptors.
      	* tree-complex.c: Update tree_pass descriptors.
      	* tree-dump.h: Update tree_pass descriptors.
      	* see.c: Update tree_pass descriptors.
      	* cgraphbuild.c: Update tree_pass descriptors.
      	* tracer.c: Update tree_pass descriptors.
      	* tree-loop-distribution.c: Update tree_pass descriptors.
      	* cgraph.c: Update tree_pass descriptors.
      	* postreload-gcse.c: Update tree_pass descriptors.
      	* postreload.c: Update tree_pass descriptors.
      	* tree-ssa-loop-ch.c: Update tree_pass descriptors.
      	* tree-tailcall.c: Update tree_pass descriptors.
      	* tree-pass.h (tree_opt_pass): Rename to ...
      	(opt_pass) ... this one; add "type" field and remove letter field.
      	(gimple_opt_pass, rtl_opt_pass, simple_ipa_opt_pass): New.
      	(execute_pass_list, execute_ipa_pass_list, all_passes, all_ipa_passes,
      	all_lowering_passes): Update declaration.
      	* ipa-cp.c: Update tree_pass descriptors.
      	* final.c: Update tree_pass descriptors.
      	* omp-low.c: Update tree_pass descriptors.
      	* tree-ssa-dse.c: Update tree_pass descriptors.
      	* ipa-reference.c: Update tree_pass descriptors.
      	* tree-ssa-uncprop.c: Update tree_pass descriptors.
      	* auto-inc-dec.c: Update tree_pass descriptors.
      	* reorg.c: Update tree_pass descriptors.
      	* cgraphunit.c: Update tree_pass descriptors.
      	* tree-ssa-copyrename.c: Update tree_pass descriptors.
      	* tree-ssa-ccp.c: Update tree_pass descriptors.
      	* df-core.c: Update tree_pass descriptors.
      	* mode-switching.c: Update tree_pass descriptors.
      	* tree-nomudflap.c: Update tree_pass descriptors.
      	* modulo-sched.c: Update tree_pass descriptors.
      	* ipa-pure-const.c: Update tree_pass descriptors.
      	* cse.c: Update tree_pass descriptors.
      	* web.c: Update tree_pass descriptors.
      	* tree-stdarg.c: Update tree_pass descriptors.
      	* tree-ssa-math-opts.c: Update tree_pass descriptors.
      	* tree-ssa-dom.c: Update tree_pass descriptors.
      	* tree-nrv.c: Update tree_pass descriptors.
      	* tree-ssa-alias.c: Update tree_pass descriptors.
      	* loop-init.c: Update tree_pass descriptors.
      	* gimple-low.c: Update tree_pass descriptors.
      	* ipa-inline.c: Update tree_pass descriptors.
      	* tree-ssa-sink.c: Update tree_pass descriptors.
      	* global.c: Update tree_pass descriptors.
      	* ifcvt.c: Update tree_pass descriptors.
      	* jump.c: Update tree_pass descriptors.
      	* predict.c: Update tree_pass descriptors.
      	* tree-ssa-loop.c: Update tree_pass descriptors.
      	* recog.c: Update tree_pass descriptors.
      	* dse.c: Update tree_pass descriptors.
      	* tree-ssa-ifcombine.c: Update tree_pass descriptors.
      	* tree-eh.c: Update tree_pass descriptors.
      	* regmove.c: Update tree_pass descriptors.
      	* local-alloc.c
      	* function.c: Update tree_pass descriptors.
      	* tree-vectorizer.c: Update tree_pass descriptors.
      	* gcse.c: Update tree_pass descriptors.
      	* ipa-type-escape.c: Update tree_pass descriptors.
      	* tree-if-conv.c: Update tree_pass descriptors.
      	* init-regs.c: Update tree_pass descriptors.
      	* ipa.c: Update tree_pass descriptors.
      	* tree-ssa-phiopt.c: Update tree_pass descriptors.
      	* rtl-factoring.c: Update tree_pass descriptors.
      	* lower-subreg.c: Update tree_pass descriptors.
      	* bt-load.c: Update tree_pass descriptors.
      	* tree-dfa.c: Update tree_pass descriptors.
      	* except.c: Update tree_pass descriptors.
      	* emit-rtl.c: Update tree_pass descriptors.
      	* cfgexpand.c: Update tree_pass descriptors.
      	* tree-cfgcleanup.c: Update tree_pass descriptors.
      	* cfgcleanup.c: Update tree_pass descriptors.
      	* tree-ssa-pre.c: Update tree_pass descriptors.
      	* tree-sra.c: Update tree_pass descriptors.
      	* tree-mudflap.c: Update tree_pass descriptors.
      	* tree-ssa-copy.c: Update tree_pass descriptors.
      	* cfglayout.c: Update tree_pass descriptors.
      	* tree-ssa-forwprop.c: Update tree_pass descriptors.
      	* tree-ssa-dce.c: Update tree_pass descriptors.
      	* tree-ssa.c: Update tree_pass descriptors.
      	* regclass.c: Update tree_pass descriptors.
      	* integrate.c: Update tree_pass descriptors.
      	* tree-optimize.c: Update tree_pass descriptors.
      	* tree-ssa-phiprop.c: Update tree_pass descriptors.
      	* tree-object-size.c: Update tree_pass descriptors.
      	* combine.c: Update tree_pass descriptors.
      	* tree-outof-ssa.c: Update tree_pass descriptors.
      	* bb-reorder.c: Update tree_pass descriptors.
      	* stack-ptr-mod.c: Update tree_pass descriptors.
      	* var-tracking.c: Update tree_pass descriptors.
      	* tree-profile.c: Update tree_pass descriptors.
      	* tree-vect-generic.c: Update tree_pass descriptors.
      	* reg-stack.c: Update tree_pass descriptors.
      	* sched-rgn.c: Update tree_pass descriptors.
      	* tree-ssa-structalias.c: Update tree_pass descriptors.
      	* tree-cfg.c: Update tree_pass descriptors.
      	* passes.c (current_pass): Update declaration.
      	(finish_optimization_passes): Update.
      	(all_passes, all_ipa_passes, all_lowering_passes): Update declaration.
      	(register_one_dump_file, register_dump_files_1, next_pass_1):
       	Update arguments.
      	(init_optimization_passes): Update handling of new types.
      	(execute_one_pass, execute_pass_list, execute_ipa_pass_list): Update.
      	* ipa-struct-reorg.c: Update tree_pass descriptors.
      	* tree-ssa-reassoc.c: Update tree_pass descriptors.
      	* combine-stack-adj.c: Update tree_pass descriptors.
      	* cfgrtl.c: Update tree_pass descriptors.
      	* dce.c: Update tree_pass descriptors.
      	* tree-ssanames.c: Update tree_pass descriptors.
      
      From-SVN: r133342
      Jan Hubicka committed
  14. 06 Mar, 2008 1 commit
  15. 25 Feb, 2008 1 commit
    • re PR target/35258 (two memcpy calls merged incorrectly with -O1) · 2e4e39f6
      2008-02-25  Andreas Krebbel  <krebbel1@de.ibm.com>
      
      	PR target/35258
      	* cse.c (cse_insn): Avoid creation of overlapping MEMs.
      	* alias.c (nonoverlapping_memrefs_p): Export for use in other modules.
      	* alias.h (nonoverlapping_memrefs_p): Likewise.
      
      2008-02-25  Andreas Krebbel  <krebbel1@de.ibm.com>
      
      	PR target/35258
      	* gcc.dg/pr35258.c: New testcase.
      
      From-SVN: r132628
      Andreas Krebbel committed
  16. 14 Jan, 2008 1 commit
  17. 12 Nov, 2007 1 commit
    • re PR rtl-optimization/34035 (ICE in calc_dfs_tree with -O2… · 2aac3a01
      re PR rtl-optimization/34035 (ICE in calc_dfs_tree with -O2 -fnon-call-exceptions -ffast-math -fno-gcse)
      
      	PR rtl-optimization/34035
      	* cse.c (cse_cfg_altered): New global variable.
      	(cse_jumps_altered): Make boolean.
      	(recorded_label_ref): Likewise.
      	(cse_insn): Adjust for above changes.
      	(cse_extended_basic_block): Likewise.  Set cse_cfg_altered
      	if dead edges have been purged.
      	(cse_main): Change return value specification and adjust code.
      	(rest_of_handle_cse): Adjust for above change.
      	(rest_of_handle_cse2): Likewise.
      	* gcse.c (rest_of_handle_gcse): Likewise.
      
      From-SVN: r130122
      Eric Botcazou committed
  18. 27 Sep, 2007 1 commit
    • simplify-rtx.c (comparison_result): New. · 39641489
      2007-09-04  Paolo Bonzini  <bonzini@gnu.org>
      
      	* simplify-rtx.c (comparison_result): New.
      	(simplify_const_relational_operation): Use it instead of the five
      	"equal|op[01]ltu?" variables; consequently remove redundant "else"s.
      	Improve bounds-checking optimizations; remove subsumed POPCOUNT
      	optimizations.  Extract nonzero_address_p optimizations into a
      	separate "if" together with optimizations where op1 is const0_rtx.
      	Optimize comparing an IOR with zero.  Simplify op0 RELOP op0 for
      	floating-point arguments too when appropriate.  Hoist test for ABS
      	outside the final switch statement.
      	* cse.c (fold_rtx): Don't look for an IOR equivalent of
      	folded_arg0 if we found a constant equivalent.	Remove
      	transformations done in simplify-rtx.c for "op0 RELOP op0".
      
      From-SVN: r128833
      Paolo Bonzini committed
  19. 09 Sep, 2007 2 commits
    • Divide REG_LABEL notes into REG_LABEL_OPERAND and REG_LABEL_TARGET. · cf7c4aa6
      	* doc/rtl.texi (Insns): Specify when a label_ref makes a jump_insn.
      	Similar for what label_refs can go in the JUMP_TARGET field.  Split
      	REG_LABEL documentation into REG_LABEL_TARGET and REG_LABEL_OPERAND.
      	* reload.c (find_reloads): Generate REG_LABEL_OPERAND, not
      	REG_LABEL when replacing an operand with a LABEL_REF for a
      	non-jump insn.
      	(subst_reloads): When replacing a LABEL_REG with a register,
      	instead of generating a REG_LABEL note, assert that there already
      	is one or that the label is a known target for the insn.
      	* rtlanal.c (computed_jump_p): Instead of looking for a REG_LABEL
      	note, check the JUMP_LABEL field.  Remove "else" after return.
      	* reorg.c (emit_delay_sequence): Replace case for REG_LABEL with
      	cases for REG_LABEL_OPERAND and REG_LABEL_TARGET.
      	(fill_slots_from_thread): Handle both REG_LABEL_OPERAND and
      	REG_LABEL_TARGET notes, including the JUMP_TARGET field on JUMP_P
      	insns.  Iterate over all notes; don't assume there's only one.
      	* cse.c (recorded_label_ref): Adjust comment to refer to
      	REG_LABEL_OPERAND.
      	(cse_extended_basic_block): Do LABEL_REF check for all INSN_P
      	insns, not just NONJUMP_INSN_P.
      	(check_for_label_ref): For JUMP_P insns, check that the LABEL_REF
      	isn't a jump target.
      	* jump.c (rebuild_jump_labels): Adjust head comment.
      	(init_label_info): Ditto.  Remove REG_LABEL_OPERAND notes only;
      	don't reset REG_LABEL_TARGET notes, including the JUMP_LABEL field.
      	(mark_all_labels): For JUMP_P insns without a target, check if the
      	the target is noted on the previous nonjump insn.
      	(mark_jump_label_1): New function, guts from mark_jump_label.
      	<case IF_THEN_ELSE>: Handle first operand as a non-target when
      	marking jump target labels.
      	<case LABEL_REF>: Adjust for whether to generate a
      	REG_LABEL_TARGET or a REG_LABEL_OPERAND note.
      	For 'E' format rtl, iterate in descending element order.
      	(delete_related_insns): Handle both REG_LABEL_TARGET and
      	REG_LABEL_OPERAND notes.  For JUMP_P insns with labels with zero
      	reference count, delete and fallthrough.  Move finding-next-
      	non-deleted insn last in the function.  Look at all INSN_P insns
      	for REG_LABEL_OPERAND notes.
      	(redirect_jump_2): Assert that OLABEL equals the old JUMP_LABEL of
      	JUMP.
      	* print-rtl.c (print_rtx): For JUMP_P insns and a non-NULL
      	JUMP_LABEL, output the INSN_UID of it.
      	* gcse.c: Adjust comments as appropriate to say REG_LABEL_OPERAND
      	and/or REG_LABEL_TARGET.
      	(add_label_notes): Only add REG_LABEL_OPERAND notes.  Put in line
      	with jump.c copy by only adding notes for labels actually
      	referenced in the insn.
      	* emit-rtl.c (try_split): Don't assume only NONJUMP_INSN_P need
      	usage count increment; handle all INSN_P trial insns.
      	(emit_copy_of_insn_after): Change to not copy REG_LABEL_OPERAND
      	notes.
      	* rtl.h (struct rtx_def) <volatil>: Adjust to mention
      	REG_LABEL_TARGET and REG_LABEL_OPERAND.
      	(LABEL_REF_NONLOCAL_P): Allow REG_LABEL_TARGET and
      	REG_LABEL_OPERAND.
      	* combine.c (distribute_notes): Adjust for REG_LABEL_TARGET on
      	JUMP_P insns and REG_LABEL_OPERAND everywhere.
      	* sched-rgn.c (is_cfg_nonregular): Check for REG_LABEL_OPERANDS
      	on all INSN_P insns.
      	* reg-notes.def (LABEL_TARGET, LABEL_OPERAND): Split from LABEL.
      	* cfgrtl.c (delete_insn): Adjust to handle REG_LABEL_TARGET and
      	REG_LABEL_OPERAND notes.
      	* reload1.c (calculate_needs_all_insns): Adjust comments.
      	(set_label_offsets): Adjust to look for REG_LABEL_OPERAND notes.
      	* config/alpha/alpha.md (split for load of an address into a
      	four-insn sequence on Unicos/Mk): Adjust to use
      	REG_LABEL_OPERAND.
      	* config/sh/sh.md (sh_reorg, final_prescan_insn): Ditto.
      
      From-SVN: r128287
      Hans-Peter Nilsson committed
    • revert: regrename.c (copyprop_hardreg_forward_1): New variable next. · ba4807a0
      	Revert:
      	2007-09-05  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
      	* regrename.c (copyprop_hardreg_forward_1): New variable next. Use
      	FOR_BB_INSNS_SAFE instead of for loop.
      	* cse.c (cse_extended_basic_block): Likewise.
      	* postreload.c (reload_cse_regs_1): New variable next. Make sure
      	that the for loop does not invoke NEXT_INSN on a deleted insn.
      	* function.c (instantiate_virtual_regs): Likewise.
      	* lower-subreg.c (remove_retval_note): Likewise.
      	(decompose_multiword_subregs): Use FOR_BB_INSNS_SAFE instead of
      	FOR_BB_INSNS.
      	* emit-rtl.c (remove_insn): Set NEXT_INSN and PREV_INSN to NULL on
      	a deleted insn.
      	* cfgrtl.c (delete_insn): Set JUMP_LABEL to NULL on a deleted
      	insn, if it's a jump.
      	(try_redirect_by_replacing_jump): New variable jump_p. Call
      	tablejump_p before delete_insn_chain.
      	* reload1.c (reload): New variable next. Make sure that the for
      	loop does not invoke NEXT_INSN on a deleted insn.
      	(fixup_eh_region_note): Make the loop terminate if i becomes NULL.
      	(delete_output_reload): New variable prev. Make sure the the for
      	loops do not invoke PREV_INSN on a deleted insn.
      
      From-SVN: r128284
      Laurynas Biveinis committed
  20. 08 Sep, 2007 1 commit
  21. 07 Sep, 2007 1 commit
    • regrename.c (copyprop_hardreg_forward_1): New variable next. · 62a4a967
      2007-09-05  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
      
      	* regrename.c (copyprop_hardreg_forward_1): New variable next. Use
      	FOR_BB_INSNS_SAFE instead of for loop.
      	* cse.c (cse_extended_basic_block): Likewise.
      	* postreload.c (reload_cse_regs_1): New variable next. Make sure
      	that the for loop does not invoke NEXT_INSN on a deleted insn.
      	* function.c (instantiate_virtual_regs): Likewise.
      	* lower-subreg.c (remove_retval_note): Likewise.
      	(decompose_multiword_subregs): Use FOR_BB_INSNS_SAFE instead of
      	FOR_BB_INSNS.
      	* emit-rtl.c (remove_insn): Set NEXT_INSN and PREV_INSN to NULL on
      	a deleted insn.
      	* cfgrtl.c (delete_insn): Set JUMP_LABEL to NULL on a deleted
      	insn, if it's a jump.
      	(try_redirect_by_replacing_jump): New variable jump_p. Call
      	tablejump_p before delete_insn_chain.
      	* reload1.c (reload): New variable next. Make sure that the for
      	loop does not invoke NEXT_INSN on a deleted insn.
      	(fixup_eh_region_note): Make the loop terminate if i becomes NULL.
      	(delete_output_reload): New variable prev. Make sure the the for
      	loops do not invoke PREV_INSN on a deleted insn.
      
      From-SVN: r128224
      Laurynas Biveinis committed
  22. 06 Sep, 2007 1 commit
  23. 05 Sep, 2007 1 commit
    • regrename.c (pass_regrename, [...]): Add RTL sharing verifier. · a36b8a1e
      	* regrename.c (pass_regrename, pass_cprop_hardreg): Add RTL sharing
      	verifier.
      	* fwprop.c (pass_rtl_fwprop, pass_rtl_fwprop_add): Likewise.
      	* see.c (pass_see): Likewise.
      	* tracer.c (pass_tracer): Likewise.
      	* postreload-gcse.c (pass_gcse2): Likewise.
      	* postreload.c (pass_postreload_cse): Likewise.
      	* mode-switching.c (pass_mode_switching): Likewise.
      	* modulo-sched.c (pass_sms): Likewise.
      	* cse.c (cse_insn): Likewise.
      	* web.c (pass_web): Likweise.
      	* combine-stack-adj.c (pass_stack_adjustments): Likewise.
      	* dce.c (pass_ud_rtl_dce, pass_fast_rtl_dce): Likewise.
      	* loop-init.c (pass_rtl_loop_init): Likewise.
      	(pass_rtl_loop_done, pass_rtl_move_loop_, pass_rtl_unswitch,
      	pass_rtl_unroll_and, pass_rtl_doloop): Likewise.
      	* global.c (pass_global_alloc): Likewise.
      	* ifcvt.c (pass_rtl_ifcvt, pass_if_after_combine,
      	pass_if_after_reload): Likewise.
      	* reload.c (pass_peephole2, pass_split_for_shoren_branches): Likewise.
      	* dse.c (pass_rtl_dse1, pass_rtl_dse2): Likewise.
      	* regmove.c (pass_regmove): Likewise.
      	* function.c (pass_thread_prologugues_epilogues): Likewise.
      	* gcse.c (pass_gcse): Likewise.
      	* rtl-factoring.c (pass_rtl_seqabstr): Likewise.
      	* lower-subreg.c (pass_lower_subreg2): Likewise.
      	* bt-load.c (pass_branch_target_load): Likewise.
      	* emit-rtl.c (pass_unshare_all_rtl): Likewise.
      	* cfgcleanup.c (pass_jump, pass_jump2): Likewise.
      	* combine.c (pass_combine): Likewise.
      	* bb-reorder.c (pass_duplicate_comp, pass_reorder_blocks): Likewise.
      	(pass_partition_blocks): Likewise.
      	* var-tracking.c (pass_variable_track): Likewise.
      	* reg-stack.c (pass_stack_regs_run): Likewise.
      	* sched-rgn.c (pass_sched, pass_sched2): Likewise.
      	* passes.c (pass_postreload): Likewise.
      	(execute_function_todo): Add TODO_verify_rtl_sharing handling code.
      	* tree-pass.h (TODO_verify_rtl_sharing): New.
      	(TODO_update_ssa, TODO_update_ssa_no_phi, TODO_update_ssa_full_phi,
      	TODO_update_ssa_only_virtuals, TODO_remove_unused_locals,
      	TODO_set_props, TODO_df_finish, TODO_df_verify,
      	TODO_mark_first_instance, TODO_rebuild_alias): Renumber.
      
      From-SVN: r128126
      Jan Hubicka committed
  24. 23 Aug, 2007 1 commit
    • rtl.c (rtx_code_size): Check CONST_FIXED to calcualte correct sizes in DEF_RTL_EXPR. · 091a3ac7
      	* rtl.c (rtx_code_size): Check CONST_FIXED to calcualte correct sizes
      	in DEF_RTL_EXPR.
      	(copy_rtx): Handle CONST_FIXED.
      	(rtx_equal_p): Likewise.
      	* rtl.h (fixed_value.h): New include.
      	(rtx_def): Add a new field of fixed_value to u.
      	(XCNMPFV): Define for accessing fixed_value.
      	(CONST_FIXED_VALUE, CONST_FIXED_VALUE_HIGH, CONST_FIXED_VALUE_LOW):
      	Define.
      	* rtl.def (CONST_FIXED): New constant.
      	(SS_MULT, US_MULT, SS_DIV, US_DIV, FRACT_CONVERT,
      	UNSIGNED_FRACT_CONVERT, SAT_FRACT, UNSIGNED_SAT_FRACT, US_NEG,
      	US_ASHIFT): New codes.
      	* doc/rtl.texi (Expressions): Document const_fixed, us_neg, ss_mult,
      	us_mult, ss_div, us_div, us_ashift, fract_convert, sat_fract,
      	unsigned_fract_convert, unsigned_sat_fract): Document them.
      	* varasm.c (assemble_integer): Extend to support fixed-point constants
      	by using different machine classes.
      	(decode_addr_const): Handle FIXED_CST.
      	(const_hash_1): Likewise.
      	(compare_constant): Likewise.
      	(copy_constant): Likewise.
      	(const_rtx_hash_1): Handle CONST_FIXED.
      	(output_constant_pool_2): Handle MODE_FRACT, MODE_UFRACT, MODE_ACCUM,
      	MODE_UACCUM, MODE_VECTOR_FRACT, MODE_VECTOR_UFRACT, MODE_VECTOR_ACCUM,
      	MODE_VECTOR_UACCUM.
      	(initializer_constant_valid_p): Handle FIXED_CST.
      	(output_constant): Support FIXED_POINT_TYPE.
      	* gengenrtl.c (excluded_rtx): Check CONST_FIXED to exclude.
      	* cse.c (hash_rtx): Support CONST_FIXED.
      	(exp_equiv_p): Likewise.
      	(cannon_reg): Likewise.
      	(fold_rtx): Likewise.
      	(equiv_constant): Likewise.
      	(cse_process_notes_1): Likewise.
      	(count_reg_usage): Likewise.
      	* cselib.c (entry_and_rtx_equal_p): Check CONST_FIXED.
      	(rtx_equal_for_cselib_p): Handle CONST_FIXED.
      	(wrap_constant): Check CONST_FIXED.
      	(cselib_hash_rtx): Support CONST_FIXED.
      	(cselib_subst_to_values): Likewise.
      	* df-scan.c (df_uses_record): Likewise.
      	* gcse.c (want_to_gcse_p): Likewise.
      	(oprs_unchanged_p): Likewise.
      	(oprs_not_set_p): Likewise.
      	(compute_transp): Likewise.
      	(extract_mentioned_regs_helper): Likewise.
      	* genemit.c (gen_exp): Likewise.
      	* local-alloc.c (equiv_init_varies_p): Likewise.
      	(contains_replace_regs): Likewise.
      	(memref_referenced_p): Likewise.
      	* loop-invariant.c (check_maybe_invariant): Likewise.
      	(hash_invariant_expr_1): Likewise.
      	(invariant_expr_equal_p): Likewise.
      	* postreload-gcse.c (oprs_unchanged_p): Likewise.
      	* regclass.c (reg_scan_mark_refs): Likewise.
      	* regrename.c (scan_rtx): Likewise.
      	* resource.c (mark_referenced_resources): Likewise.
      	(mark_set_resources): Likewise.
      	* rtlanal.c (rtx_unstable_p): Likewise.
      	(rtx_varies_p): Likewise.
      	(count_occurrences): Likewise.
      	(reg_mentioned_p): Likewise.
      	(modified_between_p): Likewise.
      	(modified_in_p): Likewise.
      	(volatile_insn_p): Likewise.
      	(volatile_refs_p): Likewise.
      	(side_effects_p): Likewise.
      	(may_trap_p_1): Likewise.
      	(inequality_comparisons_p): Likewise.
      	(computed_jump_p_1): Likewise.
      	(commutative_operand_precedence): Likewise.
      	* sched-deps.c (sched_analyze_2): Likewise.
      	* sched-vis.c (print_value): Likewise.
      	* reload.c (operands_match_p): Likewise.
      	(subst_reg_equivs): Likewise.
      	* reload1.c (eliminate_regs_1): Likewise.
      	(elimination_effects): Likewise.
      	(scan_paradoxical_subregs): Likewise.
      	* alias.c (rtx_equal_for_memref_p): Likewise.
      	* Makefile.in (RTL_BASE_H): Add fixed-value.h.
      	* emit-rtl.c (const_fixed_htab): New hash table.
      	(const_fixed_htab_hash, const_fixed_htab_eq, lookup_const_fixed):
      	Declare.
      	(const_fixed_htab_hash, const_fixed_htab_eq, lookup_const_fixed,
      	const_fixed_from_fixed_value): New functions.
      	(verify_rtx_sharing): Handle CONST_FIXED.
      	(copy_rtx_if_shared_1): Likewise.
      	(reset_used_flags): Likewise.
      	(set_used_flags): Likewise.
      	(copy_insn_1): Likewise.
      	(init_emit_once): Create const_fixed_htab.
      	Store fixed-point scalar and vector zero and one to const_tiny_rtx.
      
      From-SVN: r127725
      Chao-ying Fu committed
  25. 30 Jul, 2007 1 commit
    • alias.c (mems_in_disjoint_alias_sets_p, [...]): Constify. · 4f588890
      	* alias.c (mems_in_disjoint_alias_sets_p,
      	fixed_scalar_and_varying_struct_p, aliases_everything_p,
      	nonoverlapping_component_refs_p, nonoverlapping_memrefs_p,
      	write_dependence_p, mems_in_disjoint_alias_sets_p,
      	read_dependence, true_dependence, canon_true_dependence,
      	anti_dependence, output_dependence): Constify.
      	* combine.c (extended_count): Likewise.
      	* cse.c (cse_rtx_varies_p, hash_rtx, exp_equiv_p): Likewise.
      	* cselib.c (get_value_hash, references_value_p,
      	cselib_reg_set_mode, cselib_rtx_varies_p): Likewise.
      	* cselib.h (cselib_reg_set_mode, references_value_p): Likewise.
      	* emit-rtl.c (mem_expr_equal_p, active_insn_p): Likewise.
      	* function.c (contains, prologue_epilogue_contains,
      	sibcall_epilogue_contains): Likewise. 
      	* jump.c (simplejump_p, condjump_p, condjump_in_parallel_p,
      	pc_set, any_uncondjump_p, any_condjump_p, onlyjump_p,
      	only_sets_cc0_p, sets_cc0_p, rtx_renumbered_equal_p, true_regnum,
      	reg_or_subregno): Likewise.
      	* recog.c (asm_noperands): Likewise.
      	* reload1.c (function_invariant_p): Likewise.
      	* rtl.h (mem_expr_equal_p, active_insn_p, rtx_varies_p,
      	rtx_addr_varies_p, asm_noperands, exp_equiv_p, hash_rtx,
      	condjump_p, any_condjump_p, any_uncondjump_p, pc_set,
      	simplejump_p, onlyjump_p, only_sets_cc0_p, sets_cc0_p,
      	true_regnum, reg_or_subregno, condjump_in_parallel_p,
      	extended_count, prologue_epilogue_contains,
      	sibcall_epilogue_contains, function_invariant_p, true_dependence,
      	canon_true_dependence, read_dependence, anti_dependence,
      	output_dependence): Likewise.
      	* rtlanal.c (rtx_varies_p, rtx_addr_varies_p): Likewise.
      
      java:
      	* jcf-io.c (find_class): Fix -Wcast-qual warnings.
      
      From-SVN: r127063
      Kaveh R. Ghazi committed
  26. 26 Jul, 2007 1 commit
  27. 09 Jul, 2007 1 commit
  28. 29 Jun, 2007 2 commits
  29. 19 Jun, 2007 1 commit
    • df.h (DF_FIRST_OPTIONAL_PROBLEM): Removed. · 89a95777
      2007-06-15  Kenneth Zadeck <zadeck@naturalbridge.com>
      
      	* df.h (DF_FIRST_OPTIONAL_PROBLEM): Removed.
      	(struct df_problem.free_blocks_on_set_blocks): New field.
      	(struct dataflow.optional_p): New field.
      	(df_bb_regno_last_use_find, df_insn_regno_def_p): Removed.
      	(df_live_set_all_dirty): New function.
      	* df-scan.c (df_scan_alloc): Initialize optional_p.
      	(problem_SCAN): Initialize free_blocks_on_set_blocks.
      	* df-core.c (df_set_blocks): Removed use of
      	DF_FIRST_OPTIONAL_PROBLEM.  Now uses
      	df_problem.free_blocks_on_set_blocks to determine which blocks are
      	recycled.
      	(df_remove_problem): Removed use of DF_FIRST_OPTIONAL_PROBLEM.
      	(df_finish_pass): Removed use of DF_FIRST_OPTIONAL_PROBLEM.  Now
      	uses dataflow.optional_p to determine if problem should be
      	deleted.
      	(rest_of_handle_df_initialize): Only start live problem if 
      	-02 or above.
      	(df_bb_regno_last_use_find, df_insn_regno_def_p): Removed.
      	* df-problems.c (df_ru_alloc, df_rd_alloc, df_lr_alloc,
      	df_live_alloc, df_urec_alloc, df_note_alloc): set optional_p.
      	(problem_RU, problem_RD, problem_LR, problem_UREC, problem_CHAIN,
      	problem_NOTE):  Initialize free_blocks_on_set_blocks.
      	(df_lr_bb_local_compute): Recompute luids if df_live problem is
      	not active.
      	(df_live_set_all_dirty, df_note_alloc): New function.
      	* regrename.c (merge_overlapping_regs): Change DF_LIVE_* to
      	df_get_live_*.
      	* sched_ebb.c (compute_jump_reg_dependencies): Ditto.
      	* postreload.c (reload_combine): Ditto.
      	* cse.c (cse_extended_basic_block): Ditto.
      	* regmove.c (mark_flags_life_zones): Ditto.
      	* rtlfactoring.c (split_blocks_after_seqs, split_pattern_seq,
      	erase_matching_seqs): Ditto.
      	* bt-load.c (compute_defs_uses_and_gen): Ditto.
      	* integrate (allocate_initial_values): Ditto.
      	* combine.c (reg_dead_at_p): Ditto.
      	* resource.c (mark_target_live_regs): Ditto.
      	* sched-rgn.c (check_live_1, update_live_1): Ditto.
      	* config/sh/sh.c (find_r0_life_regions): Ditto.
      	* global.c (rest_of_handle_global_alloc): Only add back df_live
      	for -O > 1.
      	* local-alloc.c (rest_of_handle_local_alloc): Only remove
      	df_live for -O > 1.
      	* ifcvt.c (dead_or_predicable): Change DF_LIVE_* to
      	df_get_live_*.
      	(if_convert): Make sure df_live is there at -O == 1.
      	(pass_if_after_combine): Cleanup flags.
      	* init-regs.c (initialize_uninitialized_regs): Make sure df_live
      	is there at -O == 1.
      
      From-SVN: r125857
      Kenneth Zadeck committed
  30. 11 Jun, 2007 1 commit
  31. 22 May, 2007 1 commit
    • regs.h (end_hard_regno): New function. · 09e18274
      gcc/
      	* regs.h (end_hard_regno): New function.
      	(END_HARD_REGNO, END_REGNO): New macros.
      	(add_to_hard_reg_set): New function.
      	(remove_from_hard_reg_set): Likewise.
      	(in_hard_reg_set_p): Likewise.
      	(overlaps_hard_reg_set_p): Likewise.
      	* bt-load.c (find_btr_reference): Use overlaps_hard_reg_set_p.
      	(note_btr_set): Use END_HARD_REGNO.
      	* caller-save.c (setup_save_areas): Use end_hard_regno.
      	(mark_set_regs): Use END_HARD_REGNO.
      	(add_stored_regs): Use end_hard_regno.
      	(mark_referenced_regs): Use add_to_hard_reg_set.
      	* combine.c (update_table_tick): Use END_REGNO.
      	(record_value_for_reg): Likewise.
      	(record_dead_and_set_regs): Likewise.
      	(get_last_value_validate): Likewise.
      	(use_crosses_set_p): Likewise.
      	(reg_dead_at_p_1): Likewise.
      	(reg_dead_at_p): Likewise.
      	(mark_used_regs_combine): Use add_to_hard_reg_set.
      	(move_deaths): Use END_HARD_REGNO.
      	(reg_bitfield_target_p): Use end_hard_regno.
      	(distribute_notes): Use END_HARD_REGNO.
      	* cse.c (mention_regs): Use END_REGNO.
      	(insert): Use add_to_hard_reg_set.
      	(invalidate): Use END_HARD_REGNO.
      	(invalidate_for_call): Likewise.
      	(exp_equiv_p): Use END_REGNO.
      	(cse_insn): Likewise.
      	* cselib.c (cselib_invalidate_regno): Use end_hard_regno.
      	* df-problems.c (df_urec_mark_reg_change): Use END_HARD_REGNO.
      	* df-scan.c (df_ref_record): Use END_HARD_REGNO.
      	* function.c (keep_stack_depressed): Use end_hard_regno.
      	* global.c (global_alloc): Use end_hard_regno.
      	(global_conflicts): Use add_to_hard_reg_set instead of
      	mark_reg_live_nc.
      	(find_reg): Likewise.
      	(mark_reg_store): Likewise.
      	(mark_reg_conflicts): Likewise.
      	(mark_reg_death): Use remove_from_hard_reg_set.
      	(mark_reg_live_nc): Delete.
      	(set_preference): Use end_hard_regno.
      	* local-alloc.c (mark_life): Use add_to_hard_reg_set and
      	remove_from_hard_reg_set.
      	(post_mark_life): Use add_to_hard_reg_set.
      	* mode-switching.c (reg_dies): Use remove_from_hard_reg_set.
      	(reg_becomes_live): Use add_to_hard_reg_set.
      	* recog.c (reg_fits_class_p): Use in_hard_reg_set_p.
      	(peep2_find_free_register): Use add_to_hard_reg_set.
      	* reg-stack.c (convert_regs_exit): Use END_HARD_REGNO.
      	* regclass.c (record_reg_classes): Use in_hard_reg_set_p.
      	* regrename.c (note_sets): Use add_to_hard_reg_set.
      	(clear_dead_regs): Use remove_from_hard_reg_set.
      	(regrename_optimize): Use add_to_hard_reg_set.
      	(find_oldest_value_reg): Use in_hard_reg_set_p.
      	* reload.c (push_reload): Use in_hard_reg_set_p and end_hard_regno.
      	(hard_reg_set_here_p): Use end_hard_regno.
      	(decompose): Likewise.
      	(reg_overlap_mentioned_for_reload_p): Use END_HARD_REGNO.
      	(find_equiv_reg): Use in_hard_reg_set_p and end_hard_regno.
      	* reload1.c (compute_use_by_pseudos): Use add_to_hard_reg_set.
      	(mark_home_live): Use end_hard_regno.
      	(spill_hard_reg): Likewise.
      	(clear_reload_reg_in_use): Likewise.
      	* reorg.c (delete_prior_computation): Use END_REGNO.
      	* resource.c (update_live_status): Use END_HARD_REGNO.
      	(mark_referenced_resources): Use add_to_hard_reg_set.
      	(mark_set_resources): Likewise.
      	(mark_target_live_regs): Likewise.  Use remove_from_hard_reg_set.
      	* rtlanal.c (refers_to_regno_p): Use END_REGNO.
      	(reg_overlap_mentioned_p): Likewise.
      	(dead_or_set_p): Likewise.  Use an exclusive upper loop bound.
      	(covers_regno_no_parallel_p): Use END_REGNO.
      	(find_regno_note): Likewise.
      	(find_reg_fusage): Use END_HARD_REGNO.
      	* stmt.c (decl_overlaps_hard_reg_set_p): Use overlaps_hard_reg_set_p.
      	* var-tracking.c (emit_note_insn_var_location): Use end_hard_regno.
      
      From-SVN: r124961
      Richard Sandiford committed
  32. 14 Mar, 2007 1 commit
    • re PR middle-end/31127 (ICE in cse_find_path, at cse.c:5930) · 481e0a49
      gcc/ChangeLog:
      PR middle-end/31127
      * cse.c (cse_find_path): Do not bail out if a basic block that
      we already visited now becomes part of a path that starts at a
      different basic block.  Just disallow this, to make sure we
      visit each basic block at most once.
      gcc/testsuite/ChangeLog:
      PR middle-end/31127
      * gcc.dg/pr31127.c: New.
      
      From-SVN: r122900
      Alexandre Oliva committed
  33. 09 Mar, 2007 1 commit
  34. 12 Jan, 2007 1 commit
  35. 22 Dec, 2006 1 commit
    • cgraphunit.c, [...]: Fix comment typos. · 2e226e66
      	* cgraphunit.c, config/i386/i386.c, config/ia64/ia64.c, cse.c,
      	output.h, toplev.c, tree-affine.h, tree-flow.h,
      	tree-ssa-alias.c, tree-ssa-coalesce.c, tree-ssa-live.c,
      	tree-ssa-live.h, tree-ssa-operands.c, tree-ssa-ter.c,
      	tree-vrp.c, varpool.c: Fix comment typos.
      
      From-SVN: r120137
      Kazu Hirata committed
  36. 18 Dec, 2006 1 commit
  37. 17 Dec, 2006 1 commit