Commit Graph

102 Commits

Author SHA1 Message Date
Alexandre Oliva b5b8b0ac64 invoke.texi (-fvar-tracking-assignments): New.
gcc/ChangeLog:
* doc/invoke.texi (-fvar-tracking-assignments): New.
(-fvar-tracking-assignments-toggle): New.
(-fdump-final-insns=file): Mark filename as optional.
(--param min-nondebug-insn-uid): New.
(-gdwarf-@{version}): Mention version 4.
* opts.c (common_handle_option): Accept it.
* tree-vrp.c (find_assert_locations_1): Skip debug stmts.
* regrename.c (regrename_optimize): Drop last.  Don't count debug
insns as uses.  Don't reject change because of debug insn.
(do_replace): Reject DEBUG_INSN as chain starter.  Take base_regno
from the chain starter, and check for inexact matches in
DEBUG_INSNS.
(scan_rtx_reg): Accept inexact matches in DEBUG_INSNs.
(build_def_use): Simplify and fix the marking of DEBUG_INSNs.
* sched-ebb.c (schedule_ebbs): Skip boundary debug insns.
* fwprop.c (forward_propagate_and_simplify): ...into debug insns.
* doc/gimple.texi (is_gimple_debug): New.
(gimple_debug_bind_p): New.
(is_gimple_call, gimple_assign_cast_p): End sentence with period.
* doc/install.texi (bootstrap-debug): More details.
(bootstrap-debug-big, bootstrap-debug-lean): Document.
(bootstrap-debug-lib): More details.
(bootstrap-debug-ckovw): Update.
(bootstrap-time): New.
* tree-into-ssa.c (mark_def_sites): Skip debug stmts.
(insert_phi_nodes_for): Insert debug stmts.
(rewrite_stmt): Take iterator.  Insert debug stmts.
(rewrite_enter_block): Adjust.
(maybe_replace_use_in_debug_stmt): New.
(rewrite_update_stmt): Use it.
(mark_use_interesting): Return early for debug stmts.
* tree-ssa-loop-im.c (rewrite_bittest): Propagate DEFs into debug
stmts before replacing stmt.
(move_computations_stmt): Likewise.
* ira-conflicts.c (add_copies): Skip debug insns.
* regstat.c (regstat_init_n_sets_and_refs): Discount debug insns.
(regstat_bb_compute_ri): Skip debug insns.
* tree-ssa-threadupdate.c (redirection_block_p): Skip debug stmts.
* tree-ssa-loop-manip.c (find_uses_to_rename_stmt,
check_loop_closed_ssa_stmt): Skip debug stmts.
* tree-tailcall.c (find_tail_calls): Likewise.
* tree-ssa-loop-ch.c (should_duplicate_loop_header_p): Likewise.
* tree.h (MAY_HAVE_DEBUG_STMTS): New.
(build_var_debug_value_stat): Declare.
(build_var_debug_value): Define.
(target_for_debug_bind): Declare.
* reload.c (find_equiv_reg): Skip debug insns.
* rtlanal.c (reg_used_between_p): Skip debug insns.
(side_effects_p): Likewise.
(canonicalize_condition): Likewise.
* ddg.c (create_ddg_dep_from_intra_loop_link): Check that non-debug
insns never depend on debug insns.
(create_ddg_dep_no_link): Likewise.
(add_cross_iteration_register_deps): Use ANTI_DEP for debug insns.
Don't add inter-loop dependencies for debug insns.
(build_intra_loop_deps): Likewise.
(create_ddg): Count debug insns.
* ddg.h (struct ddg::num_debug): New.
(num_backargs): Pair up with previous int field.
* diagnostic.c (diagnostic_report_diagnostic): Skip notes on
-fcompare-debug-second.
* final.c (get_attr_length_1): Skip debug insns.
(rest_of_clean-state): Don't dump CFA_RESTORE_STATE.
* gcc.c (invoke_as): Call compare-debug-dump-opt.
(driver_self_specs): Map -fdump-final-insns to
-fdump-final-insns=..
(get_local_tick): New.
(compare_debug_dump_opt_spec_function): Test for . argument and
compute output name.  Compute temp output spec without flag name.
Compute -frandom-seed.
(OPT): Undef after use.
* cfgloopanal.c (num_loop_insns): Skip debug insns.
(average_num_loop_insns): Likewise.
* params.h (MIN_NONDEBUG_INSN_UID): New.
* gimple.def (GIMPLE_DEBUG): New.
* ipa-reference.c (scan_stmt_for_static_refs): Skip debug stmts.
* auto-inc-dec.c (merge_in_block): Skip debug insns.
(merge_in_block): Fix whitespace.
* toplev.c (flag_var_tracking): Update comment.
(flag_var_tracking_assignments): New.
(flag_var_tracking_assignments_toggle): New.
(process_options): Don't open final insns dump file if we're not
going to write to it.  Compute defaults for var_tracking.
* df-scan.c (df_insn_rescan_debug_internal): New.
(df_uses_record): Handle debug insns.
* haifa-sched.c (ready): Initialize n_debug.
(contributes_to_priority): Skip debug insns.
(dep_list_size): New.
(priority): Use it.
(rank_for_schedule): Likewise.  Schedule debug insns as soon as
they're ready.  Disregard previous debug insns to make decisions.
(queue_insn): Never queue debug insns.
(ready_add, ready_remove_first, ready_remove): Count debug insns.
(schedule_insn): Don't reject debug insns because of issue rate.
(get_ebb_head_tail, no_real_insns_p): Skip boundary debug insns.
(queue_to_ready): Skip and discount debug insns.
(choose_ready): Let debug insns through.
(schedule_block): Check boundary debug insns.  Discount debug
insns, schedule them early.  Adjust whitespace.
(set_priorities): Check for boundary debug insns.
(add_jump_dependencies): Use dep_list_size.
(prev_non_location_insn): New.
(check_cfg): Use it.
* tree-ssa-loop-ivopts.c (find-interesting_users): Skip debug
stmts.
(remove_unused_ivs): Reset debug stmts.
* modulo-sched.c (const_iteration_count): Skip debug insns.
(res_MII): Discount debug insns.
(loop_single_full_bb_p): Skip debug insns.
(sms_schedule): Likewise.
(sms_schedule_by_order): Likewise.
(ps_has_conflicts): Likewise.
* caller-save.c (refmarker_fn): New.
(save_call_clobbered_regs): Replace regs with saved mem in
debug insns.
(mark_referenced_regs): Take pointer, mark and arg.  Adjust.
Call refmarker_fn mark for hardregnos.
(mark_reg_as_referenced): New.
(replace_reg_with_saved_mem): New.
* ipa-pure-const.c (check_stmt): Skip debug stmts.
* cse.c (cse_insn): Canonicalize debug insns.  Skip them when
searching back.
(cse_extended_basic_block): Skip debug insns.
(count_reg_usage): Likewise.
(is_dead_reg): New, split out of...
(set_live_p): ... here.
(insn_live_p): Use it for debug insns.
* tree-stdarg.c (check_all_va_list_escapes): Skip debug stmts.
(execute_optimize_stdarg): Likewise.
* tree-ssa-dom.c (propagate_rhs_into_lhs): Likewise.
* tree-ssa-propagate.c (substitute_and_fold): Don't regard
changes in debug stmts as changes.
* sel-sched.c (moving_insn_creates_bookkeeping_block_p): New.
(moveup_expr): Don't move across debug insns.  Don't move
debug insn if it would create a bookkeeping block.
(moveup_expr_cached): Don't use cache for debug insns that
are heads of blocks.
(compute_av_set_inside_bb): Skip debug insns.
(sel_rank_for_schedule): Schedule debug insns first.  Remove
dead code.
(block_valid_for_bookkeeping_p); Support lax searches.
(create_block_for_bookkeeping): Adjust block numbers when
encountering debug-only blocks.
(find_place_for_bookkeeping): Deal with debug-only blocks.
(generate_bookkeeping_insn): Accept no place to insert.
(remove_temp_moveop_nops): New argument full_tidying.
(prepare_place_to_insert): Deal with debug insns.
(advance_state_on_fence): Debug insns don't start cycles.
(update_boundaries): Take fence as argument.  Deal with
debug insns.
(schedule_expr_on_boundary): No full_tidying on debug insns.
(fill_insns): Deal with debug insns.
(track_scheduled_insns_and_blocks): Don't count debug insns.
(need_nop_to_preserve_insn_bb): New, split out of...
(remove_insn_from_stream): ... this.
(fur_orig_expr_not_found): Skip debug insns.
* rtl.def (VALUE): Move up.
(DEBUG_INSN): New.
* tree-ssa-sink.c (all_immediate_uses_same_place): Skip debug
stmts.
(nearest_common_dominator_of_uses): Take debug_stmts argument.
Set it if debug stmts are found.
(statement_sink_location): Skip debug stmts.  Propagate
moving defs into debug stmts.
* ifcvt.c (first_active_insn): Skip debug insns.
(last_active_insns): Likewise.
(cond_exec_process_insns): Likewise.
(noce_process_if_block): Likewise.
(check_cond_move_block): Likewise.
(cond_move_convert_if_block): Likewise.
(block_jumps_and_fallthru_p): Likewise.
(dead_or_predicable): Likewise.
* dwarf2out.c (debug_str_hash_forced): New.
(find_AT_string): Add comment.
(gen_label_for_indirect_string): New.
(get_debug_string_label): New.
(AT_string_form): Use it.
(mem_loc_descriptor): Handle non-TLS symbols.  Handle MINUS , DIV,
MOD, AND, IOR, XOR, NOT, ABS, NEG, and CONST_STRING.  Accept but
discard COMPARE, IF_THEN_ELSE, ROTATE, ROTATERT, TRUNCATE and
several operations that cannot be represented with DWARF opcodes.
(loc_descriptor): Ignore SIGN_EXTEND and ZERO_EXTEND.  Require
dwarf_version 4 for DW_OP_implicit_value and DW_OP_stack_value.
(dwarf2out_var_location): Take during-call mark into account.
(output_indirect_string): Update comment.  Output if there are
label and references.
(prune_indirect_string): New.
(prune_unused_types): Call it if debug_str_hash_forced.
More in dwarf2out.c, from Jakub Jelinek <jakub@redhat.com>:
(dw_long_long_const): Remove.
(struct dw_val_struct): Change val_long_long type to rtx.
(print_die, attr_checksum, same_dw_val_p, loc_descriptor): Adjust for
val_long_long change to CONST_DOUBLE rtx from a long hi/lo pair.
(output_die): Likewise.  Use HOST_BITS_PER_WIDE_INT size of each
component instead of HOST_BITS_PER_LONG.
(output_loc_operands): Likewise.   For const8* assert
HOST_BITS_PER_WIDE_INT rather than HOST_BITS_PER_LONG is >= 64.
(output_loc_operands_raw): For const8* assert HOST_BITS_PER_WIDE_INT
rather than HOST_BITS_PER_LONG is >= 64.
(add_AT_long_long): Remove val_hi and val_lo arguments, add
val_const_double.
(size_of_die): Use HOST_BITS_PER_WIDE_INT size multiplier instead of
HOST_BITS_PER_LONG for dw_val_class_long_long.
(add_const_value_attribute): Adjust add_AT_long_long caller.  Don't
handle TLS SYMBOL_REFs.  If CONST wraps a constant, tail recurse.
(dwarf_stack_op_name): Handle DW_OP_implicit_value and
DW_OP_stack_value.
(size_of_loc_descr, output_loc_operands, output_loc_operands_raw):
Handle DW_OP_implicit_value.
(extract_int): Move prototype earlier.
(mem_loc_descriptor): For SUBREG punt if inner
mode size is wider than DWARF2_ADDR_SIZE.  Handle SIGN_EXTEND
and ZERO_EXTEND by DW_OP_shl and DW_OP_shr{a,}.  Handle
EQ, NE, GT, GE, LT, LE, GTU, GEU, LTU, LEU, SMIN, SMAX, UMIN,
UMAX, SIGN_EXTRACT, ZERO_EXTRACT.
(loc_descriptor): Compare mode size with DWARF2_ADDR_SIZE
instead of Pmode size.
(loc_descriptor): Add MODE argument.  Handle CONST_INT, CONST_DOUBLE,
CONST_VECTOR, CONST, LABEL_REF and SYMBOL_REF if mode != VOIDmode,
attempt to handle other expressions.  Don't handle TLS SYMBOL_REFs.
(concat_loc_descriptor, concatn_loc_descriptor,
loc_descriptor_from_tree_1): Adjust loc_descriptor callers.
(add_location_or_const_value_attribute): Likewise.  For single
location loc_lists attempt to use add_const_value_attribute
for constant decls.  Add DW_AT_const_value even if
NOTE_VAR_LOCATION is VAR_LOCATION with CONSTANT_P or CONST_STRING
in its expression.
* cfgbuild.c (inside_basic_block_p): Handle debug insns.
(control_flow_insn_p): Likewise.
* tree-parloops.c (eliminate_local_variables_stmt): Handle debug
stmt.
(separate_decls_in_region_debug_bind): New.
(separate_decls_in_region): Process debug bind stmts afterwards.
* recog.c (verify_changes): Handle debug insns.
(extract_insn): Likewise.
(peephole2_optimize): Skip debug insns.
* dse.c (scan_insn): Skip debug insns.
* sel-sched-ir.c (return_nop_to_pool): Take full_tidying argument.
Pass it on.
(setup_id_for_insn): Handle debug insns.
(maybe_tidy_empty_bb): Adjust whitespace.
(tidy_control_flow): Skip debug insns.
(sel_remove_insn): Adjust for debug insns.
(sel_estimate_number_of_insns): Skip debug insns.
(create_insn_rtx_from_pattern): Handle debug insns.
(create_copy_of_insn_rtx): Likewise.
* sel-sched-.h (sel_bb_end): Declare.
(sel_bb_empty_or_nop_p): New.
(get_all_loop_exits): Use it.
(_eligible_successor_edge_p): Likewise.
(return_nop_to_pool): Adjust.
* tree-eh.c (tre_empty_eh_handler_p): Skip debug stmts.
* ira-lives.c (process_bb_node_lives): Skip debug insns.
* gimple-pretty-print.c (dump_gimple_debug): New.
(dump_gimple_stmt): Use it.
(dump_bb_header): Skip gimple debug stmts.
* regmove.c (optimize_reg_copy_1): Discount debug insns.
(fixup_match_2): Likewise.
(regmove_backward_pass): Likewise.  Simplify combined
replacement.  Handle debug insns.
* function.c (instantiate_virtual_regs): Handle debug insns.
* function.h (struct emit_status): Add x_cur_debug_insn_uid.
* print-rtl.h: Include cselib.h.
(print_rtx): Print VALUEs.  Split out and recurse for
VAR_LOCATIONs.
* df.h (df_inns_rescan_debug_internal): Declare.
* gcse.c (alloc_hash_table): Estimate n_insns.
(cprop_insn): Don't regard debug insns as changes.
(bypass_conditional_jumps): Skip debug insns.
(one_pre_gcse_pass): Adjust.
(one_code_hoisting_pass): Likewise.
(compute_ld_motion_mems): Skip debug insns.
(one_cprop_pass): Adjust.
* tree-if-conv.c (tree_if_convert_stmt): Reset debug stmts.
(if_convertible_stmt_p): Handle debug stmts.
* init-regs.c (initialize_uninitialized_regs): Skip debug insns.
* tree-vect-loop.c (vect_is_simple_reduction): Skip debug stmts.
* ira-build.c (create_bb_allocnos): Skip debug insns.
* tree-flow-inline.h (has_zero_uses): Discount debug stmts.
(has_single_use): Likewise.
(single_imm_use): Likewise.
(num_imm_uses): Likewise.
* tree-ssa-phiopt.c (empty_block_p): Skip debug stmts.
* tree-ssa-coalesce.c (build_ssa_conflict_graph): Skip debug stmts.
(create_outofssa_var_map): Likewise.
* lower-subreg.c (adjust_decomposed_uses): New.
(resolve_debug): New.
(decompose_multiword_subregs): Use it.
* tree-dfa.c (find_referenced_vars): Skip debug stmts.
* emit-rtl.c: Include params.h.
(cur_debug_insn_uid): Define.
(set_new_first_and_last_insn): Set cur_debug_insn_uid too.
(copy_rtx_if_shared_1): Handle debug insns.
(reset_used_flags): Likewise.
(set_used_flags): LIkewise.
(get_max_insn_count): New.
(next_nondebug_insn): New.
(prev_nondebug_insn): New.
(make_debug_insn_raw): New.
(emit_insn_before_noloc): Handle debug insns.
(emit_jump_insn_before_noloc): Likewise.
(emit_call_insn_before_noloc): Likewise.
(emit_debug_insn_before_noloc): New.
(emit_insn_after_noloc): Handle debug insns.
(emit_jump_insn_after_noloc): Likewise.
(emit_call_insn_after_noloc): Likewise.
(emit_debug_insn_after_noloc): Likewise.
(emit_insn_after): Take loc from earlier non-debug insn.
(emit_jump_insn_after): Likewise.
(emit_call_insn_after): Likewise.
(emit_debug_insn_after_setloc): New.
(emit_debug_insn_after): New.
(emit_insn_before): Take loc from later non-debug insn.
(emit_jump_insn_before): Likewise.
(emit_call_insn_before): Likewise.
(emit_debug_insn_before_setloc): New.
(emit_debug_insn_before): New.
(emit_insn): Handle debug insns.
(emit_debug_insn): New.
(emit_jump_insn): Handle debug insns.
(emit_call_insn): Likewise.
(emit): Likewise.
(init_emit): Take min-nondebug-insn-uid into account.
Initialize cur_debug_insn_uid.
(emit_copy_of_insn_after): Handle debug insns.
* cfgexpand.c (gimple_assign_rhs_to_tree): Do not overwrite
location of single rhs in place.
(maybe_dump_rtl_for_gimple_stmt): Dump lineno.
(floor_sdiv_adjust): New.
(cell_sdiv_adjust): New.
(cell_udiv_adjust): New.
(round_sdiv_adjust): New.
(round_udiv_adjust): New.
(wrap_constant): Moved from cselib.
(unwrap_constant): New.
(expand_debug_expr): New.
(expand_debug_locations): New.
(expand_gimple_basic_block): Drop hiding redeclaration.  Expand
debug bind stmts.
(gimple_expand_cfg): Expand debug locations.
* cselib.c: Include tree-pass.h.
(struct expand_value_data): New.
(cselib_record_sets_hook): New.
(PRESERVED_VALUE_P, LONG_TERM_PRESERVED_VALUE_P): New.
(cselib_clear_table): Move, and implemnet in terms of...
(cselib_reset_table_with_next_value): ... this.
(cselib_get_next_unknown_value): New.
(discard_useless_locs): Don't discard preserved values.
(cselib_preserve_value): New.
(cselib_preserved_value_p): New.
(cselib_preserve_definitely): New.
(cselib_clear_preserve): New.
(cselib_preserve_only_values): New.
(new_cselib_val): Take rtx argument.  Dump it in details.
(cselib_lookup_mem): Adjust.
(expand_loc): Take regs_active in struct.  Adjust.  Silence
dumps unless details are requested.
(cselib_expand_value_rtx_cb): New.
(cselib_expand_value_rtx): Rename and reimplment in terms of...
(cselib_expand_value_rtx_1): ... this.  Adjust.  Silence dumps
without details.  Copy more subregs.  Try to resolve values
using a callback.  Wrap constants.
(cselib_subst_to_values): Adjust.
(cselib_log_lookup): New.
(cselib_lookup): Call it.
(cselib_invalidate_regno): Don't count preserved values as
useless.
(cselib_invalidate_mem): Likewise.
(cselib_record_set): Likewise.
(struct set): Renamed to cselib_set, moved to cselib.h.
(cselib_record_sets): Adjust.  Call hook.
(cselib_process_insn): Reset table when it would be cleared.
(dump_cselib_val): New.
(dump_cselib_table): New.
* tree-cfgcleanup.c (tree_forwarded_block_p): Skip debug stmts.
(remove_forwarder_block): Support moving debug stmts.
* cselib.h (cselib_record_sets_hook): Declare.
(cselib_expand_callback): New type.
(cselib_expand_value_rtx_cb): Declare.
(cselib_reset_table_with_next_value): Declare.
(cselib_get_next_unknown_value): Declare.
(cselib_preserve_value): Declare.
(cselib_preserved_value_p): Declare.
(cselib_preserve_only_values): Declare.
(dump_cselib_table): Declare.
* cfgcleanup.c (flow_find_cross_jump): Skip debug insns.
(try_crossjump_to_edge): Likewise.
(delete_unreachable_blocks): Remove dominant GIMPLE blocks after
dominated blocks when debug stmts are present.
* simplify-rtx.c (delegitimize_mem_from_attrs): New.
* tree-ssa-live.c (remove_unused_locals): Skip debug stmts.
(set_var_live_on_entry): Likewise.
* loop-invariant.c (find_invariants_bb): Skip debug insns.
* cfglayout.c (curr_location, last_location): Make static.
(set_curr_insn_source_location): Don't avoid bouncing.
(get_curr_insn_source_location): New.
(get_curr_insn_block): New.
(duplicate_insn_chain): Handle debug insns.
* tree-ssa-forwprop.c (forward_propagate_addr_expr): Propagate
into debug stmts.
* common.opt (fcompare-debug): Move to sort order.
(fdump-unnumbered-links): Likewise.
(fvar-tracking-assignments): New.
(fvar-tracking-assignments-toggle): New.
* tree-ssa-dce.c (mark_stmt_necessary): Don't mark blocks
because of debug stmts.
(mark_stmt_if_obviously_necessary): Mark debug stmts.
(eliminate_unnecessary_stmts): Walk dominated blocks before
dominators.
* tree-ssa-ter.c (find_replaceable_in_bb): Skip debug stmts.
* ira.c (memref_used_between_p): Skip debug insns.
(update_equiv_regs): Likewise.
* sched-deps.c (sd_lists_size): Accept empty list.
(sd_init_insn): Mark debug insns.
(sd_finish_insn): Unmark them.
(sd_add_dep): Reject non-debug deps on debug insns.
(fixup_sched_groups): Give debug insns group treatment.
Skip debug insns.
(sched_analyze_reg): Don't mark debug insns for sched before call.
(sched_analyze_2): Handle debug insns.
(sched_analyze_insn): Compute next non-debug insn.  Handle debug
insns.
(deps_analyze_insn): Handle debug insns.
(deps_start_bb): Skip debug insns.
(init_deps): Initialize last_debug_insn.
* tree-ssa.c (target_for_debug_bind): New.
(find_released_ssa_name): New.
(propagate_var_def_into_debug_stmts): New.
(propagate_defs_into_debug_stmts): New.
(verify_ssa): Skip debug bind stmts without values.
(warn_uninialized_vars): Skip debug stmts.
* target-def.h (TARGET_DELEGITIMIZE_ADDRESS): Set default.
* rtl.c (rtx_equal_p_cb): Handle VALUEs.
(rtx_equal_p): Likewise.
* ira-costs.c (scan_one_insn): Skip debug insns.
(process_bb_node_for_hard_reg_moves): Likewise.
* rtl.h (DEBUG_INSN_P): New.
(NONDEBUG_INSN_P): New.
(MAY_HAVE_DEBUG_INSNS): New.
(INSN_P): Accept debug insns.
(RTX_FRAME_RELATED_P): Likewise.
(INSN_DELETED_P): Likewise
(PAT_VAR_LOCATION_DECL): New.
(PAT_VAR_LOCATION_LOC): New.
(PAT_VAR_OCATION_STATUS): New.
(NOTE_VAR_LOCATION_DECL): Reimplement.
(NOTE_VAR_LOCATION_LOC): Likewise.
(NOTE_VAR_LOCATION_STATUS): Likewise.
(INSN_VAR_LOCATION): New.
(INSN_VAR_LOCATION_DECL): New.
(INSN_VAR_LOCATION_LOC): New.
(INSN_VAR_LOCATION_STATUS): New.
(gen_rtx_UNKNOWN_VAR_LOC): New.
(VAR_LOC_UNKNOWN_P): New.
(NOTE_DURING_CALL_P): New.
(SCHED_GROUP_P): Accept debug insns.
(emit_debug_insn_before): Declare.
(emit_debug_insn_before_noloc): Declare.
(emit_debug_insn_beore_setloc): Declare.
(emit_debug_insn_after): Declare.
(emit_debug_insn_after_noloc): Declare.
(emit_debug_insn_after_setloc): Declare.
(emit_debug_insn): Declare.
(make_debug_insn_raw): Declare.
(prev_nondebug_insn): Declare.
(next_nondebug_insn): Declare.
(delegitimize_mem_from_attrs): Declare.
(get_max_insn_count): Declare.
(wrap_constant): Declare.
(unwrap_constant): Declare.
(get_curr_insn_source_location): Declare.
(get_curr_insn_block): Declare.
* tree-inline.c (insert_debug_decl_map): New.
(processing_debug_stmt): New.
(remap_decl): Don't create new mappings in debug stmts.
(remap_gimple_op_r): Don't add references in debug stmts.
(copy_tree_body_r): Likewise.
(remap_gimple_stmt): Handle debug bind stmts.
(copy_bb): Skip debug stmts.
(copy_edges_for_bb): Likewise.
(copy_debug_stmt): New.
(copy_debug_stmts): New.
(copy_body): Copy debug stmts at the end.
(insert_init_debug_bind): New.
(insert_init_stmt): Take id.  Skip and emit debug stmts.
(setup_one_parameter): Remap variable earlier, register debug
mapping.
(estimate_num_insns): Skip debug stmts.
(expand_call_inline): Preserve debug_map.
(optimize_inline_calls): Check for no debug_stmts left-overs.
(unsave_expr_now): Preserve debug_map.
(copy_gimple_seq_and_replace_locals): Likewise.
(tree_function_versioning): Check for no debug_stmts left-overs.
Init and destroy debug_map as needed.  Split edges unconditionally.
(build_duplicate_type): Init and destroy debug_map as needed.
* tree-inline.h: Include gimple.h instead of pointer-set.h.
(struct copy_body_data): Add debug_stmts and debug_map.
* sched-int.h (struct ready_list): Add n_debug.
(struct deps): Add last_debug_insn.
(DEBUG_INSN_SCHED_P): New.
(BOUNDARY_DEBUG_INSN_P): New.
(SCHEDULE_DEBUG_INSN_P): New.
(sd_iterator_cond): Accept empty list.
* combine.c (create_log_links): Skip debug insns.
(combine_instructions): Likewise.
(cleanup_auto_inc_dec): New.  From Jakub Jelinek: Make sure the
return value is always unshared.
(struct rtx_subst_pair): New.
(auto_adjust_pair): New.
(propagate_for_debug_subst): New.
(propagate_for_debug): New.
(try_combine): Skip debug insns.  Propagate removed defs into
debug insns.
(next_nonnote_nondebug_insn): New.
(distribute_notes): Use it.  Skip debug insns.
(distribute_links): Skip debug insns.
* tree-outof-ssa.c (set_location_for_edge): Likewise.
* resource.c (mark_target_live_regs): Likewise.
* var-tracking.c: Include cselib.h and target.h.
(enum micro_operation_type): Add MO_VAL_USE, MO_VAL_LOC, and
MO_VAL_SET.
(micro_operation_type_name): New.
(enum emit_note_where): Add EMIT_NOTE_AFTER_CALL_INSN.
(struct micro_operation_def): Update comments.
(decl_or_value): New type.  Use instead of decls.
(struct emit_note_data_def): Add vars.
(struct attrs_def): Use decl_or_value.
(struct variable_tracking_info_def): Add permp, flooded.
(struct location_chain_def): Update comment.
(struct variable_part_def): Use decl_or_value.
(struct variable_def): Make var_part a variable length array.
(valvar_pool): New.
(scratch_regs): New.
(cselib_hook_called): New.
(dv_is_decl_p): New.
(dv_is_value_p): New.
(dv_as_decl): New.
(dv_as_value): New.
(dv_as_opaque): New.
(dv_onepart_p): New.
(dv_pool): New.
(IS_DECL_CODE): New.
(check_value_is_not_decl): New.
(dv_from_decl): New.
(dv_from_value): New.
(dv_htab_hash): New.
(variable_htab_hash): Use it.
(variable_htab_eq): Support values.
(variable_htab_free): Free from the right pool.
(attrs_list_member, attrs_list_insert): Use decl_or_value.
(attrs_list_union): Adjust.
(attrs_list_mpdv_union): New.
(tie_break_pointers): New.
(canon_value_cmp): New.
(unshare_variable): Return possibly-modified slot.
(vars_copy_1): Adjust.
(var_reg_decl_set): Adjust.  Split out of...
(var_reg_set): ... this.
(get_init_value): Adjust.
(var_reg_delete_and_set): Adjust.
(var_reg_delete): Adjust.
(var_regno_delete): Adjust.
(var_mem_decl_set): Split out of...
(var_mem_set): ... this.
(var_mem_delete_and_set): Adjust.
(var_mem_delete): Adjust.
(val_store): New.
(val_reset): New.
(val_resolve): New.
(variable_union): Adjust.  Speed up merge of 1-part vars.
(variable_canonicalize): Use unshared slot.
(VALUED_RECURSED_INTO): New.
(find_loc_in_1pdv): New.
(struct dfset_merge): New.
(insert_into_intersection): New.
(intersect_loc_chains): New.
(loc_cmp): New.
(canonicalize_loc_order_check): New.
(canonicalize_values_mark): New.
(canonicalize_values_star): New.
(variable_merge_over_cur): New.
(variable_merge_over_src): New.
(dataflow_set_merge): New.
(dataflow_set_equiv_regs): New.
(remove_duplicate_values): New.
(struct dfset_post_merge): New.
(variable_post_merge_new_vals): New.
(variable_post_merge_perm_vals): New.
(dataflow_post_merge_adjust): New.
(find_mem_expr_in_1pdv): New.
(dataflow_set_preserve_mem_locs): New.
(dataflow_set_remove_mem_locs): New.
(dataflow_set_clear_at_call): New.
(onepart_variable_different_p): New.
(variable_different_p): Use it.
(dataflow_set_different_1): Adjust.  Make detailed dump
more verbose.
(track_expr_p): Add need_rtl parameter.  Don't generate rtl
if not needed.
(track_loc_p): Pass it true.
(struct count_use_info): New.
(find_use_val): New.
(replace_expr_with_values): New.
(log_op_type): New.
(use_type): New, partially split out of...
(count_uses): ... this.  Count new micro-ops.
(count_uses_1): Adjust.
(count_stores): Adjust.
(count_with_sets): New.
(VAL_NEEDS_RESOLUTION): New.
(VAL_HOLDS_TRACK_EXPR): New.
(VAL_EXPR_IS_COPIED): New.
(VAL_EXPR_IS_CLOBBERED): New.
(add_uses): Adjust.  Generate new micro-ops.
(add_uses_1): Adjust.
(add_stores): Generate new micro-ops.
(add_with_sets): New.
(find_src_status): Adjust.
(find_src_set_src): Adjust.
(compute_bb_dataflow): Use dataflow_set_clear_at_call.
Handle new micro-ops.  Canonicalize value equivalances.
(vt_find_locations): Compute total size of hash tables for
dumping.  Perform merge for var-tracking-assignments.  Don't
disregard single-block loops.
(dump_attrs_list): Handle decl_or_value.
(dump_variable): Take variable.  Deal with decl_or_value.
(dump_variable_slot): New.
(dump_vars): Use it.
(dump_dataflow_sets): Adjust.
(set_slot_part): New, extended to support one-part variables
after splitting out of...
(set_variable_part): ... this.
(clobber_slot_part): New, split out of...
(clobber_variable_part): ... this.
(delete_slot_part): New, split out of...
(delete_variable_part): .... this.
(check_wrap_constant): New.
(vt_expand_loc_callback): New.
(vt_expand_loc): New.
(emit_note_insn_var_location): Adjust.  Handle values.  Handle
EMIT_NOTE_AFTER_CALL_INSN.
(emit_notes_for_differences_1): Adjust.  Handle values.
(emit_notes_for_differences_2): Likewise.
(emit_notes_for_differences): Adjust.
(emit_notes_in_bb): Take pointer to set.  Emit AFTER_CALL_INSN
notes.  Adjust.  Handle new micro-ops.
(vt_add_function_parameters): Adjust.  Create and bind values.
(vt_initialize): Adjust.  Initialize scratch_regs and
valvar_pool, flooded and perm..  Initialize and use cselib.  Log
operations.  Move some code to count_with_sets and add_with_sets.
(delete_debug_insns): New.
(vt_debug_insns_local): New.
(vt_finalize): Release permp, valvar_pool, scratch_regs.  Finish
cselib.
(var_tracking_main): If var-tracking-assignments is enabled
but var-tracking isn't, delete debug insns and leave.  Likewise
if we exceed limits or fail the stack adjustments tests, and
after all var-tracking processing.
More in var-tracking, from Jakub Jelinek <jakub@redhat.com>:
(dataflow_set): Add traversed_vars.
(value_chain, const_value_chain): New typedefs.
(value_chain_pool, value_chains): New variables.
(value_chain_htab_hash, value_chain_htab_eq, add_value_chain,
add_value_chains, add_cselib_value_chains, remove_value_chain,
remove_value_chains, remove_cselib_value_chains): New functions.
(shared_hash_find_slot_unshare_1, shared_hash_find_slot_1,
shared_hash_find_slot_noinsert_1, shared_hash_find_1): New
static inlines.
(shared_hash_find_slot_unshare, shared_hash_find_slot,
shared_hash_find_slot_noinsert, shared_hash_find): Update.
(dst_can_be_shared): New variable.
(unshare_variable): Unshare set->vars if shared, use shared_hash_*.
Clear dst_can_be_shared.  If set->traversed_vars is non-NULL and
different from set->vars, look up slot again instead of using the
passed in slot.
(dataflow_set_init): Initialize traversed_vars.
(variable_union): Use shared_hash_*.  Use initially NO_INSERT
lookup if set->vars is shared.  Don't keep slot cleared before
calling unshare_variable.  Unshare set->vars if needed.  Adjust
unshare_variable callers.  Clear dst_can_be_shared if needed.
Even ->refcount == 1 vars must be unshared if set->vars is shared
and var needs to be modified.
(dataflow_set_union): Set traversed_vars during canonicalization.
(VALUE_CHANGED, DECL_CHANGED): Define.
(set_dv_changed, dv_changed_p): New static inlines.
(track_expr_p): Clear DECL_CHANGED.
(dump_dataflow_sets): Set it.
(variable_was_changed): Call set_dv_changed.
(emit_note_insn_var_location): Likewise.
(changed_variables_stack): New variable.
(check_changed_vars_1, check_changed_vars_2): New functions.
(emit_notes_for_changes): Do nothing if changed_variables is
empty.  Traverse changed_variables with check_changed_vars_1,
call check_changed_vars_2 on each changed_variables_stack entry.
(emit_notes_in_bb): Add SET argument.  Just clear it at the
beginning, use it instead of local &set, don't destroy it at the
end.
(vt_emit_notes): Call dataflow_set_clear early on all
VTI(bb)->out sets, never use them, instead use emit_notes_in_bb
computed set, dataflow_set_clear also VTI(bb)->in when we are
done with the basic block.  Initialize changed_variables_stack,
free it afterwards.  If ENABLE_CHECKING verify that after noting
differences to an empty set value_chains hash table is empty.
(vt_initialize): Initialize value_chains and value_chain_pool.
(vt_finalize): Delete value_chains htab, free value_chain_pool.
(variable_tracking_main): Call dump_dataflow_sets before calling
vt_emit_notes, not after it.
* tree-flow.h (propagate_defs_into_debug_stmts): Declare.
(propagate_var_def_into_debug_stmts): Declare.
* df-problems.c (df_lr_bb_local_compute): Skip debug insns.
(df_set_note): Reject debug insns.
(df_whole_mw_reg_dead_p): Take added_notes_p argument.  Don't
add notes to debug insns.
(df_note_bb_compute): Adjust.  Likewise.
(df_simulate_uses): Skip debug insns.
(df_simulate_initialize_backwards): Likewise.
* reg-stack.c (subst_stack_regs_in_debug_insn): New.
(subst_stack_regs_pat): Reject debug insns.
(convert_regs_1): Handle debug insns.
* Makefile.in (TREE_INLINE_H): Take pointer-set.h from GIMPLE_H.
(print-rtl.o): Depend on cselib.h.
(cselib.o): Depend on TREE_PASS_H.
(var-tracking.o): Depend on cselib.h and TARGET_H.
* sched-rgn.c (rgn_estimate_number_of_insns): Discount
debug insns.
(init_ready_list): Skip boundary debug insns.
(add_branch_dependences): Skip debug insns.
(free_block_dependencies): Check for blocks with only debug
insns.
(compute_priorities): Likewise.
* gimple.c (gss_for_code): Handle GIMPLE_DEBUG.
(gimple_build_with_ops_stat): Take subcode as unsigned.  Adjust
all callers.
(gimple_build_debug_bind_stat): New.
(empty_body_p): Skip debug stmts.
(gimple_has_side_effects): Likewise.
(gimple_rhs_has_side_effects): Likewise.
* gimple.h (enum gimple_debug_subcode, GIMPLE_DEBUG_BIND): New.
(gimple_build_debug_bind_stat): Declare.
(gimple_build_debug_bind): Define.
(is_gimple_debug): New.
(gimple_debug_bind_p): New.
(gimple_debug_bind_get_var): New.
(gimple_debug_bind_get_value): New.
(gimple_debug_bind_get_value_ptr): New.
(gimple_debug_bind_set_var): New.
(gimple_debug_bind_set_value): New.
(GIMPLE_DEBUG_BIND_NOVALUE): New internal temporary macro.
(gimple_debug_bind_reset_value): New.
(gimple_debug_bind_has_value_p): New.
(gsi_next_nondebug): New.
(gsi_prev_nondebug): New.
(gsi_start_nondebug_bb): New.
(gsi_last_nondebug_bb): New.
* sched-vis.c (print_pattern): Handle VAR_LOCATION.
(print_insn): Handle DEBUG_INSN.
* tree-cfg.c (remove_bb): Walk stmts backwards.  Let loc
of first insn prevail.
(first_stmt): Skip debug stmts.
(first_non_label_stmt): Likewise.
(last_stmt): Likewise.
(has_zero_uses_1): New.
(single_imm_use_1): New.
(verify_gimple_debug): New.
(verify_types_in_gimple_stmt): Handle debug stmts.
(verify_stmt): Likewise.
(debug_loop_num): Skip debug stmts.
(remove_edge_and_dominated_blocks): Remove dominators last.
* tree-ssa-reasssoc.c (rewrite_expr_tree): Propagate into
debug stmts.
(linearize_expr): Likewise.
* config/i386/i386.c (ix86_delegitimize_address): Call
default implementation.
* config/ia64/ia64.c (ia64_safe_itanium_class): Handle debug
insns.
(group_barrier_needed): Skip debug insns.
(emit_insn_group_barriers): Likewise.
(emit_all_insn_group_barriers): Likewise.
(ia64_variable_issue): Handle debug insns.
(ia64_dfa_new_cycle): Likewise.
(final_emit_insn_group_barriers): Skip debug insns.
(ia64_dwarf2out_def_steady_cfa): Take frame argument.  Don't
def cfa without frame.
(process_set): Likewise.
(process_for_unwind_directive): Pass frame on.
* config/rs6000/rs6000.c (TARGET_DELEGITIMIZE_ADDRESS): Define.
(rs6000_delegitimize_address): New.
(rs6000_debug_adjust_cost): Handle debug insns.
(is_microcoded_insn): Likewise.
(is_cracked_insn): Likewise.
(is_nonpipeline_insn): Likewise.
(insn_must_be_first_in_group): Likewise.
(insn_must_be_last_in_group): Likewise.
(force_new_group): Likewise.
* cfgrtl.c (rtl_split_block): Emit INSN_DELETED note if block
contains only debug insns.
(rtl_merge_blocks): Skip debug insns.
(purge_dead_edges): Likewise.
(rtl_block_ends_with_call_p): Skip debug insns.
* dce.c (deletable_insn_p): Handle VAR_LOCATION.
(mark_reg_dependencies): Skip debug insns.
* params.def (PARAM_MIN_NONDEBUG_INSN_UID): New.
* tree-ssanames.c (release_ssa_name): Propagate def into
debug stmts.
* tree-ssa-threadedge.c
(record_temporary_equivalences_from_stmts): Skip debug stmts.
* regcprop.c (replace_oldest_value_addr): Skip debug insns.
(replace_oldest_value_mem): Use ALL_REGS for debug insns.
(copyprop_hardreg_forward_1): Handle debug insns.
* reload1.c (reload): Skip debug insns.  Replace unassigned
pseudos in debug insns with their equivalences.
(eliminate_regs_in_insn): Skip debug insns.
(emit_input_reload_insns): Skip debug insns at first, adjust
them later.
* tree-ssa-operands.c (add_virtual_operand): Reject debug stmts.
(get_indirect_ref_operands): Pass opf_no_vops on.
(get_expr_operands): Likewise.  Skip debug stmts.
(parse_ssa_operands): Scan debug insns with opf_no_vops.
gcc/testsuite/ChangeLog:
* gcc.dg/guality/guality.c: New.
* gcc.dg/guality/guality.h: New.
* gcc.dg/guality/guality.exp: New.
* gcc.dg/guality/example.c: New.
* lib/gcc-dg.exp (cleanup-dump): Remove .gk files.
(cleanup-saved-temps): Likewise, .gkd files too.
gcc/cp/ChangeLog:
* cp-tree.h (TFF_NO_OMIT_DEFAULT_TEMPLATE_ARGUMENTS): New.
* cp-lang.c (cxx_dwarf_name): Pass it.
* error.c (count_non_default_template_args): Take flags as
argument.  Adjust all callers.  Skip counting of default
arguments if the new flag is given.
ChangeLog:
* Makefile.tpl (BUILD_CONFIG): Default to bootstrap-debug.
* Makefile.in: Rebuilt.
contrib/ChangeLog:
* compare-debug: Look for .gkd files and compare them.
config/ChangeLog:
* bootstrap-debug.mk: Add comments.
* bootstrap-debug-big.mk: New.
* bootstrap-debug-lean.mk: New.
* bootstrap-debug-ckovw.mk: Add comments.
* bootstrap-debug-lib.mk: Drop CFLAGS for stages.  Use -g0
for TFLAGS in stage1.  Drop -fvar-tracking-assignments-toggle.

From-SVN: r151312
2009-09-02 02:42:21 +00:00
Eric Botcazou 9d2bb9026f re PR rtl-optimization/40710 (Linux kernel miscompiled for sh4-linux)
PR rtl-optimization/40710
	* resource.c (mark_target_live_regs): Reset DF problem to LR.

From-SVN: r149696
2009-07-15 21:32:46 +00:00
Ian Lance Taylor 675f99c97f resource.c (mark_referenced_resources): Change include_delayed_effects parameter to bool.
* resource.c (mark_referenced_resources): Change
	include_delayed_effects parameter to bool.  Change all callers.
	(mark_end_of_function_resources): Likewise.
	* reorg.c (insn_references_resource_p): Likewise.
	(insn_sets_resource_p): Likewise.
	* resource.h (mark_referenced_resources): Update declaration.
	(mark_end_of_function_resources): Update declaration.

From-SVN: r148547
2009-06-16 18:55:20 +00:00
Eric Botcazou 2a34bece47 re PR rtl-optimization/39938 (build broke for cris-elf with dbr_schedule change)
PR rtl-optimization/39938
	* Makefile.in (cfgrtl.o): Add $(INSN_ATTR_H).
	* cfgrtl.c: Include insn-attr.h.
	(rest_of_pass_free_cfg): New function.
	(pass_free_cfg): Use rest_of_pass_free_cfg as execute function.
	* resource.c (init_resource_info): Remove call to df_analyze.

Co-Authored-By: Steven Bosscher <steven@gcc.gnu.org>

From-SVN: r146988
2009-04-29 21:44:26 +00:00
Eric Botcazou e1a3b85c7a re PR rtl-optimization/39938 (build broke for cris-elf with dbr_schedule change)
PR rtl-optimization/39938
	* resource.c (init_resource_info): Add call to df_analyze.

From-SVN: r146915
2009-04-28 21:29:58 +00:00
Eric Botcazou a1fa3e7944 resource.c (find_basic_block): Use BLOCK_FOR_INSN to look up a label's basic block.
* resource.c (find_basic_block): Use BLOCK_FOR_INSN to look up
	a label's basic block.
	(mark_target_live_regs): Tidy and rework obsolete comments.
	Change back DF problem to LIVE.  If a label starts a basic block,
	assume that all registers that used to be live then still are.
	(init_resource_info): If a label starts a basic block, set its
	BLOCK_FOR_INSN accordingly.
	(fini_resource_info): Undo the setting of BLOCK_FOR_INSN.

From-SVN: r146829
2009-04-27 10:42:09 +00:00
Jakub Jelinek 66647d441f Update Copyright years for files modified in 2008 and/or 2009.
From-SVN: r144324
2009-02-20 16:20:38 +01:00
Richard Sandiford 1b929c9a04 resource.c (mark_referenced_resources): Look inside UNSPEC_VOLATILEs and ASM_INPUTs.
gcc/
	* resource.c (mark_referenced_resources): Look inside
	UNSPEC_VOLATILEs and ASM_INPUTs.

From-SVN: r137375
2008-07-02 18:05:42 +00:00
Jan Hubicka 38173d38cc function.h (incomming_args): Break out of struct function.
* function.h (incomming_args): Break out of struct function.
	(function_subsections): Break out of struct function.
	(rtl_data): Add args, subsections fields. Break out outgoing_args_size,
	return_rtx and hard_reg_initial_vals from struct function.
	Kill inl_max_label_num.
	(current_function_pops_args, current_function_args_info,
	current_function_args_size, current_function_args_size,
	current_function_pretend_args_size,
	current_function_outgoing_args_size,
	current_function_internal_arg_pointer, current_function_return_rtx):
	Kill compatibility accestor macros.
	* builtins.c (expand_builtin_apply_args_1): Update.
	(expand_builtin_next_arg): Update.
	* df-scan.c (df_get_call_refs): Update.
	* dbxout.c (dbxout_function_end): Update.
	* dwarf2out.c (dwarf2out_switch_text_section): Update.
	(output_line_info): Update.
	(secname_for_decl): Update.
	(dwarf2out_var_location): Update.
	* function.c (free_after_compilation): Update.
	(assign_parm_find_stack_rtl): Update.
	(assign_parms): Update.
	(expand_dummy_function_end): Update.
	(expand_function_end): Update.
	* calls.c (mem_overlaps_already_clobbered_arg_p): Update.
	(expand_call): Update.
	(emit_library_call_value_1): Update.
	(store_one_arg): Update.
	* varasm.c (initialize_cold_section_name): Update.
	(unlikely_text_section): Update.
	(unlikely_text_section_p): Update.
	(assemble_start_function): Update.
	(assemble_end_function): Update.
	(default_section_type_flags): Update.
	(switch_to_section): Update.
	* integrate.c (set_decl_abstract_flags): Update.
	(get_hard_reg_initial_val): Update.
	(has_hard_reg_initial_val): Update.
	(allocate_initial_values): Update.
	* resource.c (init_resource_info): Update.
	* config/alpha/alpha.c (NUM_ARGS): Update.
	(direct_return): Update.
	(alpha_va_start): Update.
	(alpha_sa_size): Update.
	(alpha_initial_elimination_offset): Update.
	(alpha_expand_prologue): Update.
	(alpha_start_function): Update.
	(alpha_expand_epilogue): Update.
	(unicosmk_initial_elimination_offset):
	* config/alpha/alpha.md (call expander): Update.
	* config/s390/s390.c (s390_register_info): Update.
	(s390_register_info): Update.
	(s390_frame_info): Update.
	(s390_initial_elimination_offset): Update.
	(s390_build_builtin_va_list): Update.
	(s390_va_start): Update.
	* config/spu/spu.c (direct_return): Update.
	(spu_expand_prologue): Update.
	(spu_initial_elimination_offset): Update.
	(spu_build_builtin_va_list): Update.
	(spu_va_start): Update.
	* config/sparc/sparc.c (sparc_init_modes): Update.
	(sparc_compute_frame_size): Update.
	(function_value): Update.
	* config/m32r/m32r.c (m32r_compute_frame_size): Update.
	* config/i386/i386.md (return expander): Update.
	* config/i386/i386.c (ix86_va_start): Update.
	(ix86_can_use_return_insn_p): Update.
	(ix86_compute_frame_layout): Update.
	(ix86_expand_epilogue): Update.
	* config/sh/sh.c (output_stack_adjust): Update.
	(calc_live_regs): Update.
	(sh_expand_prologue): Update.
	(sh_builtin_saveregs): Update.
	(sh_va_start): Update.
	(initial_elimination_offset): Update.
	(sh_allocate_initial_value): Update.
	(sh_function_ok_for_sibcall): Update.
	(sh_get_pr_initial_val): Update.
	* config/sh/sh.md (return expander): Update.
	* config/avr/avr.c (frame_pointer_required_p): UPdate.
	* config/crx/crx.c (crx_compute_frame): UPdate.
	(crx_initial_elimination_offset): UPdate.
	* config/xtensa/xtensa.c (compute_frame_size): Update
	(xtensa_builtin_saveregs): Update.
	(xtensa_va_start): Update.
	(order_regs_for_local_alloc): Update.
	* config/stormy16/stormy16.c (xstormy16_compute_stack_layout): Update.
	(xstormy16_expand_builtin_va_start): Update.
	* config/fr30/fr30.c (fr30_compute_frame_size): Update.
	* config/m68hc11/m68hc11.md (return expanders): Update.
	* config/m68hc11/m68hc11.c (expand_prologue): Update.
	(expand_epilogue): Update.
	* config/cris/cris.c (cris_initial_frame_pointer_offset): Update.
	(cris_simple_epilogue): Update.
	(cris_expand_prologue): Update.
	(cris_expand_epilogue): Update.
	* config/iq2000/iq2000.c (iq2000_va_start): Update.
	(compute_frame_size): Update.
	* config/mt/mt.c (mt_compute_frame_size): Update.
	* config/mn10300/mn10300.c (expand_prologue): Update.
	(expand_epilogue): Update.
	(initial_offset): Update.
	(mn10300_builtin_saveregs):
	* config/mn10300/mn10300.md (return expander): Update.
	* config/ia64/ia64.c (ia64_compute_frame_size): Update.
	(ia64_initial_elimination_offset): Update.
	(ia64_initial_elimination_offset): Update.
	(ia64_expand_prologue): Update.
	* config/m68k/m68k.md (return expander): Update.
	* config/rs6000/rs6000.c (rs6000_va_start): Update.
	(rs6000_stack_info): Update.
	* config/mcore/mcore.c (layout_mcore_frame): Update.
	(mcore_expand_prolog): Update.
	* config/arc/arc.c (arc_compute_frame_size): Update.
	* config/score/score3.c (score3_compute_frame_size): Update.
	* config/score/score7.c (score7_compute_frame_size): Update.
	* config/arm/arm.c (use_return_insn): Update.
	(thumb_find_work_register): Update.
	(arm_compute_save_reg_mask): Update.
	(arm_output_function_prologue): Update.
	(arm_output_epilogue): Update.
	(arm_size_return_regs): Update.
	(arm_get_frame_offsets): Update.
	(arm_expand_prologue): Update.
	(thumb_exit): Update.
	(thumb_unexpanded_epilogue): Update.
	(thumb1_output_function_prologue): Update.
	* config/pa/pa.md (return expander): Update.
	* config/pa/pa.c (compute_frame_size): Update.
	(hppa_builtin_saveregs): Update.
	* config/mips/mips.c (mips_va_start): Update.
	(mips16_build_function_stub): Update.
	(mips_compute_frame_info): Update.
	(mips_restore_gp): Update.
	(mips_output_function_prologue): Update.
	(mips_expand_prologue): Update.
	* config/v850/v850.c (compute_frame_size): Update.
	(expand_prologue): * config/mmix/mmix.c (along): update.
	(mmix_initial_elimination_offset): update.
	(mmix_reorg): update.
	(mmix_use_simple_return): update.
	(mmix_expand_prologue): update.
	(mmix_expand_epilogue): Update.
	* config/bfin/bfin.c (bfin_initial_elimination_offset): Update.
	(emit_link_insn): Update.

From-SVN: r134087
2008-04-08 08:59:34 +00:00
Richard Sandiford eef75f5ec0 200x-xx-xx Kaz Kylheku <kaz@zeugmasystems.com>
gcc/
200x-xx-xx  Kaz Kylheku  <kaz@zeugmasystems.com>

	PR rtl-optimization/34456
	* resource.c (mark_set_resources): Use regs_invalidated_by_call
	rather than call_used_regs and global_regs.

gcc/testsuite/
	PR rtl-optimization/34456
	* gcc.c-torture/execute/pr34456.c: New test.

From-SVN: r131033
2007-12-18 07:40:17 +00:00
Richard Sandiford 30c6f45db6 re PR rtl-optimization/34415 (Possible miscompilation on MIPS)
gcc/
	PR rtl-optimization/34415
	* df.h (DF_LR_IN, DF_LR_OUT): Update comments.
	* resource.c (mark_target_live_regs): Use DF_LR_IN rather than
	df_get_live_in.  Don't handle pseudos.

gcc/testsuite/
	PR rtl-optimization/34415
	* gcc.c-torture/execute/pr34415.c: New test.

From-SVN: r130987
2007-12-16 09:54:34 +00:00
Chao-ying Fu 091a3ac7b8 rtl.c (rtx_code_size): Check CONST_FIXED to calcualte correct sizes in DEF_RTL_EXPR.
* 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
2007-08-23 00:30:39 +00:00
Kaveh R. Ghazi ed7a4b4b30 alias.c (rtx_equal_for_memref_p): Constify.
* alias.c (rtx_equal_for_memref_p): Constify.
	* basic-block.h (const_edge, const_basic_block): New.
	(reg_set_to_hard_reg_set, dfs_enumerate_from, single_succ_p,
	single_pred_p, single_succ_edge, single_pred_edge, single_succ,
	single_pred, maybe_hot_bb_p, probably_cold_bb_p,
	probably_never_executed_bb_p, edge_probability_reliable_p,
	br_prob_note_reliable_p, forwarder_block_p, flow_nodes_print,
	inside_basic_block_p, control_flow_insn_p, dominated_by_p):
	Likewise.
	* bb-reorder.c (better_edge_p, push_to_next_round_p): Likewise.
	* bt-load.c (basic_block_freq, insn_sets_btr_p, can_move_up):
	Likewise.
	* cfganal.c (flow_active_insn_p, forwarder_block_p,
	flow_nodes_print, dfs_enumerate_from): Likewise.
	* cfgbuild.c (count_basic_blocks, inside_basic_block_p,
	control_flow_insn_p, count_basic_blocks): Likewise.
	* cfgloop.c (flow_bb_inside_loop_p, glb_enum_p,
	get_loop_body_with_size, loop_exit_edge_p): Likewise.
	* cfgloop.h (flow_bb_inside_loop_p, num_loop_insns,
	average_num_loop_insns, loop_exit_edge_p,
	just_once_each_iteration_p, can_duplicate_loop_p): Likewise.
	* cfgloopanal.c (just_once_each_iteration_p, num_loop_insns,
	average_num_loop_insns, seq_cost): Likewise.
	* cfgloopmanip.c (rpe_enum_p, can_duplicate_loop_p): Likewise.
	* dominance.c (dominated_by_p): Likewise.
	* emit-rtl.c (validate_subreg): Likewise.
	* except.c (can_throw_internal, can_throw_external): Likewise.
	* except.h (can_throw_internal, can_throw_external): Likewise.
	* gcse.c (gcse_constant_p, oprs_unchanged_p, oprs_anticipatable_p,
	oprs_available_p, hash_expr, expr_equiv_p, oprs_not_set_p,
	compute_transp, load_killed_in_block_p, reg_killed_on_edge,
	simple_mem, store_ops_ok, load_kills_store, find_loads,
	store_killed_in_insn, store_killed_after, store_killed_before,
	gcse_mem_operand, implicit_set_cond_p, store_killed_in_pat):
	Likewise.
	* ifcvt.c (count_bb_insns, cheap_bb_rtx_cost_p, noce_operand_ok,
	noce_mem_write_may_trap_or_fault_p): Likewise.
	* pointer-set.c (pointer_set_contains, pointer_map_contains):
	Likewise.
	* pointer-set.h (pointer_set_contains, pointer_map_contains):
	Likewise.
	* predict.c (can_predict_insn_p, maybe_hot_bb_p,
	probably_cold_bb_p, probably_never_executed_bb_p,
	edge_probability_reliable_p, br_prob_note_reliable_p,
	can_predict_insn_p): Likewise.
	* regclass.c (reg_set_to_hard_reg_set): Likewise.
	* resource.c (return_insn_p): Likewise.
	* rtl.h (reg_set_between_p, reg_set_p, validate_subreg):
	Likewise.
	* rtlanal.c (reg_set_between_p, reg_set_p): Likewise.
	* tracer.c (count_insns, ignore_bb_p, better_p): Likewise.
	* tree-cfg.c (verify_gimple_unary_expr, verify_gimple_binary_expr,
	verify_gimple_modify_stmt): Likewise.
	* tree-chrec.c (is_not_constant_evolution,
	is_multivariate_chrec_rec, is_multivariate_chrec,
	chrec_contains_symbols, chrec_contains_undetermined,
	tree_contains_chrecs, evolution_function_is_affine_multivariate_p,
	evolution_function_is_univariate_p, avoid_arithmetics_in_type_p,
	eq_evolutions_p, scev_direction): Likewise.
	* tree-chrec.h (automatically_generated_chrec_p, tree_is_chrec,
	eq_evolutions_p, is_multivariate_chrec, chrec_contains_symbols,
	chrec_contains_symbols_defined_in_loop,
	chrec_contains_undetermined, tree_contains_chrecs,
	evolution_function_is_affine_multivariate_p,
	evolution_function_is_univariate_p, chrec_zerop,
	evolution_function_is_constant_p, evolution_function_is_affine_p,
	evolution_function_is_affine_or_constant_p,
	tree_does_not_contain_chrecs, chrec_type): Likewise.
	* tree-data-ref.c (tree_fold_divides_p,
	object_address_invariant_in_loop_p, dr_may_alias_p,
	ziv_subscript_p, siv_subscript_p, gcd_of_steps_may_divide_p,
	same_access_functions, constant_access_functions,
	access_functions_are_affine_or_constant_p, find_vertex_for_stmt):
	Likewise.
	* tree-flow.h (scev_direction): Likewise.
	* tree-gimple.c (is_gimple_stmt): Likewise.
	* tree-outof-ssa.c (identical_copies_p, identical_stmt_lists_p):
	Likewise.
	* tree-pretty-print.c (op_prio): Likewise.
	* tree-scalar-evolution.c (chrec_contains_symbols_defined_in_loop,
	analyzable_condition, backedge_phi_arg_p): Likewise.
	* tree-scalar-evolution.h (get_chrec_loop): Likewise.
	* tree-ssa-operands.c (get_name_decl, operand_build_cmp): Likewise.
	* tree-ssa-threadupdate.c (dbds_continue_enumeration_p):
	Likewise.

From-SVN: r127404
2007-08-14 04:44:35 +00:00
Kaveh R. Ghazi 7bc980e1d9 alias.c (record_set, [...]): Constify.
* alias.c (record_set, memory_modified_1): Constify.
	* bt-load.c (note_btr_set): Likewise.
	* caller-save.c (mark_set_regs, add_stored_regs): Likewise.
	* combine.c (set_nonzero_bits_and_sign_copies,
	expand_field_assignment, record_dead_and_set_regs_1,
	use_crosses_set_p, reg_dead_at_p_1, can_combine_p,
	likely_spilled_retval_1): Likewise.
	* config/frv/frv.c (frv_registers_update_1, frv_io_check_address,
	frv_io_handle_set): Likewise.
	* config/mips/mips.c (mips_sim_record_set,
	vr4130_true_reg_dependence_p_1): Likewise.
	* config/mt/mt.c (insn_dependent_p_1): Likewise.
	* config/s390/s390.c (s390_reg_clobbered_rtx): Likewise.
	* config/sh/sh.c (flow_dependent_p_1): Likewise.
	* cselib.c (cselib_invalidate_rtx_note_stores): Likewise.
	* dce.c (mark_nonreg_stores_1, mark_nonreg_stores_2): Likewise.
	* ddg.c (mark_mem_store): Likewise.
	* df-problems.c (df_urec_mark_reg_change): Likewise.
	* function.c (update_epilogue_consts): Likewise.
	* gcse.c (record_set_info, record_last_set_info,
	mems_conflict_for_gcse_p, canon_list_insert, reg_set_info,
	reg_clear_last_set): Likewise.
	* global.c (mark_reg_store, mark_reg_clobber, reg_becomes_live):
	Likewise.
	* jump.c (reversed_comparison_code_parts): Likewise.
	* local-alloc.c (validate_equiv_mem_from_store, no_equiv,
	reg_is_set): Likewise.
	* loop-iv.c (mark_altered): Likewise.
	* mode-switching.c (reg_becomes_live): Likewise.
	* optabs.c (no_conflict_move_test): Likewise.
	* postreload-gcse.c (record_last_set_info, find_mem_conflicts):
	Likewise.
	* postreload.c (reload_combine_note_store, move2add_note_store):
	Likewise.
	* regmove.c (flags_set_1): Likewise.
	* regrename.c (note_sets, kill_clobbered_value, kill_set_value):
	Likewise.
	* reload1.c (mark_not_eliminable, forget_old_reloads_1):
	Likewise. 
	* resource.c (update_live_status): Likewise.
	* rtl.h (set_of, note_stores): Likewise.
	* rtlanal.c (set_of_1, parms_set, struct set_of_data, set_of,
	note_stores, parms_set): Likewise.
	* sched-rgn.c (sets_likely_spilled_1): Likewise.
	* stack-ptr-mod.c (notice_stack_pointer_modification_1):
	Likewise. 
	* var-tracking.c (count_stores, add_stores): Likewise.

From-SVN: r127065
2007-07-30 16:30:18 +00:00
Nick Clifton 9dcd6f09a3 Change copyright header to refer to version 3 of the GNU General Public License and to point readers at the COPYING3 file and the FSF's license web page.
From-SVN: r126948
2007-07-26 08:37:01 +00:00
Kenneth Zadeck 89a9577706 df.h (DF_FIRST_OPTIONAL_PROBLEM): Removed.
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
2007-06-19 19:04:52 +00:00
Daniel Berlin 6fb5fa3cbc Merge dataflow branch into mainline
From-SVN: r125624
2007-06-11 18:02:15 +00:00
Richard Sandiford 09e18274fd regs.h (end_hard_regno): New function.
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
2007-05-22 20:52:39 +00:00
Jan Hubicka a38e7aa544 gengtype.c (adjust_field_rtx_def): Use NOTE_KIND instead of NOTE_LINE_NUMBER...
* gengtype.c (adjust_field_rtx_def): Use NOTE_KIND instead of
	NOTE_LINE_NUMBER; use NOTE_INSN_BASIC_BLOCK_P when possible.
	* ddg.c (create_ddg): LIkewise.
	* final.c (final): Remove hunk moving line numbernotes around since
	they are no longer present at this stage.
	(final_scan_insn): Use NOTE_KIND instead of
	NOTE_LINE_NUMBER; use NOTE_INSN_BASIC_BLOCK_P when possible.
	(output_asm_label): Likewise.
	* reorg.c (dbr_schedule): Likewise.
	* haifa-sched.c (unlink_other_notes): Likewise.
	* mode-switching.c (optimize_mode_switching): Likewise.
	* graph.c (start_bb): Likewise.
	* rtl.def (NOTE): Update description.
	* jump.c (squeeze_notes): Delete.
	(mark_jump_label): Use NOTE_KIND instead of NOTE_LINE_NUMBER; use
	NOTE_INSN_BASIC_BLOCK_P when possible.
	* ifcvt.c (dead_or_predicable): Remove call of squeeze_notes.
	* dwarf2out.c (gen_label_die): Use NOTE_KIND instead of
        NOTE_LINE_NUMBER; use NOTE_INSN_BASIC_BLOCK_P when possible.
	(dwarf2out_var_location): Likewise.
	* cfgbuild.c (make_edges): Likewise.
	(find_basic_blocks_1): Likewise.
	* function.c (reorder_blocks_1): Likewise.
	(epilogue_done): Likewise.
	(reposition_prologue_and_epilogue_notes): Likewise.
	* print-rtl.c (print_rtx): Likewise; drop code for printing line number
	notes.
	(print_rtl): Likewise.
	(print_rtl_single): Likewise.
	* gcse.c (insert_insn_start_bb): Likewise.
	* alias.c (init_alias_analysis): Likewise.
	* calls.c (fixup_tail_calls): Likewise.
	* except.c (sjlj_emit_function_enter): Likewise.
	* emit-rtl.c (add_insn_after): Likeiwse.
	(emit_label_before): Likewise.
	(emit_label_after): Likewise.
	(emit_note_before, emit_note_after, emit_note): Update
	parameter to be enum insn_note; do not deal with source
	files.
	* cfgcleanup.c (merge_blocks_move_predecessor_nojumps):
	Use NOTE_KIND instead of NOTE_LINE_NUMBER; use NOTE_INSN_BASIC_BLOCK_P
	when possible.
	(merge_blocks_move_successor_nojumps): Simplify now when
	we don't have BLOCK notes.
	(try_optimize_cfg): Likewise.
	* cfglayout.c (skip_insns_after_block): Likewise.
	(record_effective_endpoints): Likewise.
	(duplicate_insn_chain): Likewise.
	* varasm.c (output_constant_pool_1): Likewise.
	* sched-deps.c (sched_analyze): Likewise.
	* rtl.c (NOTE_INSN_MAX_isnt_negative_adjust_NOTE_INSN_BIAS):
	Exterminate.
	(note_insn_name): Simplify now when NOTE_INSN_BIAS is gone.
	* rtl.h (NOTE_SOURCE_LOCATION, NOTE_EXPANDED_LOCATION): Exterminate.
	(SET_INSN_DELETED): Simplify.
	(NOTE_LINE_NUMBER): Exterminate.
	(NOTE_LINE_KIND): New.
	(NOTE_INSN_BASIC_BLOCK_P): Update.
	(enum insn_note): Simplify.
	(GET_NOTE_INSN_NAME) Simplify.
	(emit_note_before, emit_note_after, emit_note): Update prototype.
	(squeeze_notes): Remove.
	* sched-int.h (NOTE_NOT_BB_P): Update.
	* resource.c (mark_target_live_regs): Update.
	* sched-rgn.c (debug_dependencies): Update.
	* sched-vis.c (print_insn): Update.
	* config/alpha/alpha.c (alpha_handle_trap_shadows): Update.
	* config/i386/i386.c (ix86_output_function_epilogue): Update.
	* config/sh/sh.c (sh_adjust_unroll_max): Function dead since gcc 4.0.0.
	(TARGET_ADJUST_UNROLL_MAX): Likewise.
	(split_branches): Update.
	(sh_optimize_target_register_callee_saved): Remove hunk dead since gcc
	4.0.0.
	(sh_adjust_unroll_max): Exterminate.
	* config/c4x/c4x.c (c4x_reorg): Use SET_INSN_DELETED.
	* config/m68hc11/m68hc11.c (m68hc11_check_z_replacement): Likewise.
	(m68hc11_reorg): Likewise.
	* config/ia64/ia64.c (emit_insn_group_barriers): Update.
	(emit_predicate_relation_info): Update.
	(process_for_unwind_directive): Update.
	* config/rs6000/rs6000.c (rs6000_output_function_epilogue): Update.
	(output_call): Update.
	* config/pa/pa.c (output_lbranch): Update.
	(output_millicode_call): Update.
	(output_call): Update.
	(pa_combine_instructions): Update.
	* config/mips/mips.c (mips16_gp_pseudo_reg): Update.
	* config/bfin/bfin.c (gen_one_bundle): Update.
	* cfgrtl.c (can_delete_note_p): Update.
	(delete_insn): Update.
	(rtl_merge_blocks): Update.
	(commit_one_edge_insertion): Update.
	(rtl_verify_flow_info): Update.
	* stmt.c (expand_case): Do not call squeeze_notes.

From-SVN: r124895
2007-05-21 06:19:50 +00:00
Joseph Myers f1f4e530a5 rtlanal.c (struct subreg_info, [...]): New.
* rtlanal.c (struct subreg_info, subreg_get_info, subreg_nregs):
	New.
	(subreg_regno_offset, subreg_offset_representable_p): Change to
	wrappers about subreg_get_info.
	(refers_to_regno_p, reg_overlap_mentioned_p): Use subreg_nregs.
	* rtl.h (subreg_nregs): Declare.
	* doc/tm.texi (HARD_REGNO_NREGS_HAS_PADDING): Update to refer to
	subreg_get_info.
	* caller-save.c (mark_set_regs, add_stored_regs): Use
	subreg_nregs.
	* df-scan.c (df_ref_record): Use subreg_nregs.
	* flow.c (mark_set_1): Use subreg_nregs.
	* postreload.c (move2add_note_store): Use subreg_nregs.
	* reload.c (decompose, refers_to_regno_for_reload_p,
	reg_overlap_mentioned_for_reload_p): Use subreg_nregs.
	* resource.c (update_live_status, mark_referenced_resources,
	mark_set_resources): Use subreg_nregs.

From-SVN: r120076
2006-12-20 16:25:00 +00:00
Marcin Dalecki 5ed6ace578 tree-vrp.c: Use XNEW/XCNEW allocation wrappers.
2006-01-31  Marcin Dalecki  <martin@dalecki.de>

	* tree-vrp.c: Use XNEW/XCNEW allocation wrappers.
	* regrename.c: Ditto.
	* tree-ssa-loop-im.c: Ditto.
	* tree-dump.c: Ditto.
	* tree-complex.c: Ditto.
	* genrecog.c: Ditto.
	* tree-ssa-threadupdate.c: Ditto.
	* tracer.c: Ditto.
	* java/class.c: Ditto.
	* java/jcf-parse.c: Ditto.
	* java/resource.c: Ditto.
	* java/except.c: Ditto.
	* java/jvspec.c: Ditto.
	* java/jcf-write.c: Ditto.
	* java/jcf-path.c: Ditto.
	* java/gjavah.c: Ditto.
	* java/zextract.c: Ditto.
	* java/jcf-io.c: Ditto.
	* java/jcf.h: Ditto.
	* java/buffer.c: Ditto.
	* java/lang.c: Ditto.
	* java/parse-scan.y: Ditto.
	* java/lex.c: Ditto.
	* java/lex.h: Ditto.
	* cfgloopmanip.c: Ditto.
	* postreload-gcse.c: Ditto.
	* tree-ssa-loop-manip.c: Ditto.
	* postreload.c: Ditto.
	* tree-ssa-loop-ch.c: Ditto.
	* loop.c: Ditto.
	* ipa-cp.c: Ditto.
	* cppspec.c: Ditto.
	* diagnostic.c: Ditto.
	* final.c: Ditto.
	* genoutput.c: Ditto.
	* gcc.c: Ditto.
	* cfghooks.c: Ditto.
	* cfgloopanal.c: Ditto.
	* objc/objc-act.c: Ditto.
	* gcov.c: Ditto.
	* genextract.c: Ditto.
	* genautomata.c: Ditto.
	* pretty-print.c: Ditto.
	* genemit.c: Ditto.
	* cgraphunit.c: Ditto.
	* flow.c: Ditto.
	* df-scan.c: Ditto.
	* haifa-sched.c: Ditto.
	* dominance.c: Ditto.
	* dbxout.c: Ditto.
	* tree-ssa-loop-ivopts.c: Ditto.
	* df-core.c: Ditto.
	* mode-switching.c: Ditto.
	* modulo-sched.c: Ditto.
	* graph.c: Ditto.
	* ipa-pure-const.c: Ditto.
	* cse.c: Ditto.
	* fix-header.c: Ditto.
	* web.c: Ditto.
	* tree-stdarg.c: Ditto.
	* ipa-utils.c: Ditto.
	* loop-init.c: Ditto.
	* ipa-inline.c: Ditto.
	* cfganal.c: Ditto.
	* global.c: Ditto.
	* alloc-pool.c: Ditto.
	* dwarf2out.c: Ditto.
	* opts.c: Ditto.
	* genattrtab.c: Ditto.
	* tree-ssa-loop-ivcanon.c: Ditto.
	* predict.c: Ditto.
	* timevar.c: Ditto.
	* lcm.c: Ditto.
	* fortran/gfortranspec.c: Ditto.
	* regmove.c: Ditto.
	* local-alloc.c: Ditto.
	* langhooks.c: Ditto.
	* function.c: Ditto.
	* tree-vectorizer.c: Ditto.
	* gcse.c: Ditto.
	* ipa-type-escape.c: Ditto.
	* alias.c: Ditto.
	* tree-if-conv.c: Ditto.
	* profile.c: Ditto.
	* ipa.c: Ditto.
	* tree-data-ref.c: Ditto.
	* loop-unroll.c: Ditto.
	* treelang/treetree.c: Ditto.
	* calls.c: Ditto.
	* bt-load.c: Ditto.
	* ggc-common.c: Ditto.
	* except.c: Ditto.
	* coverage.c: Ditto.
	* cselib.c: Ditto.
	* tree-cfgcleanup.c: Ditto.
	* tree-ssa-pre.c: Ditto.
	* cfgcleanup.c: Ditto.
	* loop-invariant.c: Ditto.
	* loop-iv.c: Ditto.
	* ipa-prop.c: Ditto.
	* print-tree.c: Ditto.
	* conflict.c: Ditto.
	* ggc-page.c: Ditto.
	* sched-deps.c: Ditto.
	* regclass.c: Ditto.
	* tree-object-size.c: Ditto.
	* combine.c: Ditto.
	* bb-reorder.c: Ditto.
	* resource.c: Ditto.
	* var-tracking.c: Ditto.
	* cfgloop.c: Ditto.
	* df-problems.c: Ditto.
	* reg-stack.c: Ditto.
	* tlink.c: Ditto.
	* gccspec.c: Ditto.
	* sched-rgn.c: Ditto.
	* tree-ssa-structalias.c: Ditto.
	* tree-ssa-reassoc.c: Ditto.
	* config/darwin-c.c: Ditto.
	* config/darwin.c: Ditto.
	* config/arm/arm.c: Ditto.
	* cfgrtl.c: Ditto.
	* collect2.c: Ditto.
	* reload1.c: Ditto.

From-SVN: r110446
2006-01-31 20:56:55 +01:00
Kelley Cook 366ccddb2b Update FSF address.
From-SVN: r101317
2005-06-25 02:02:01 +00:00
Jan Hubicka 5e2d947ce8 basic-block.h (rtl_bb_info): Break out head_, end_, global_live_at_start, global_live_at_end from ...
* basic-block.h (rtl_bb_info): Break out head_, end_,
	global_live_at_start, global_live_at_end from ...
	(basic_block_def): ... here; update all references
	(BB_RTL): New flag.
	(init_rtl_bb_info): Declare.
	* cfgexpand.c (expand_gimple_basic_block): Init bb info, set BB_RTL
	flag.
	* cfgrtl.c: Include ggc.h
	(create_basic_block_structure): Init bb info.
	(rtl_verify_flow_info_1): Check BB_RTL flag and rtl_bb_info pointer.
	(init_rtl_bb_info): New function.
	(rtl_merge_block, cfglayout_merge_block): Copy global_live_at_end here.
	* cfghooks.c (merge_block): Do not copy global_live_at_end here.
	* cfg.c (clear_bb_flags): Skip BB_RTL flag.
	(dump_flow_info): Gueard global_live_* dumping.

From-SVN: r101082
2005-06-16 10:33:40 +00:00
Kazu Hirata 2ca202e792 bt-load.c, [...]: Use JUMP_P, LABEL_P, REG_P, MEM_P, NONJUMP_INSN_P, and INSN_P where appropriate.
* bt-load.c, cfgexpand.c, dwarf2out.c, emit-rtl.c, expr.c,
	function.c, global.c, lcm.c, loop-invariant.c, optabs.c,
	reorg.c, resource.c, tree-ssa-loop-ivopts.c, value-prof.c: Use
	JUMP_P, LABEL_P, REG_P, MEM_P, NONJUMP_INSN_P, and INSN_P
	where appropriate.

From-SVN: r98913
2005-04-28 05:03:09 +00:00
Kazu Hirata ad616de14c basic-block.h, [...]: Update copyright.
* basic-block.h, c-common.c, c-cppbuiltin.c, c-lang.c,
	c-tree.h, cfgbuild.c, cgraph.c, cgraph.h, collect2.c,
	combine.c, config.gcc, coverage.h, cse.c, cselib.c,
	defaults.h, df.c, dwarf2asm.c, dwarf2out.c, explow.c, expr.c,
	flow.c, fold-const.c, gcse.c, ggc-page.c, gimple-low.c,
	gimplify.c, ifcvt.c, langhooks-def.h, lcm.c, optabs.h,
	output.h, postreload-gcse.c, postreload.c, recog.c,
	resource.c, rtl.def, rtlanal.c, sched-deps.c, sched-rgn.c,
	targhooks.h, toplev.c, tree-data-ref.c, tree-eh.c,
	tree-flow.h, tree-loop-linear.c, tree-mudflap.h, tree-nrv.c,
	tree-optimize.c, tree-outof-ssa.c, tree-pass.h,
	tree-scalar-evolution.c, tree-ssa-copy.c, tree-ssa-dce.c,
	tree-ssa-dse.c, tree-ssa-loop-ivopts.c, tree-ssa-operands.c,
	tree-ssa-pre.c, tree-ssa.c, tree-vectorizer.c, tree.def,
	unwind-dw2-fde-darwin.c, var-tracking.c: Update copyright.

From-SVN: r93827
2005-01-18 11:36:31 +00:00
Steven Bosscher 46d096a3c7 combine.c (expand_compound_operation): Add comment that we fall through after case.
* combine.c (expand_compound_operation)  <ZERO_EXTRACT>: Add
	comment that we fall through after case.
	(mark_used_regs_combine): Don't expect a SIGN_EXTRACT in a SET_DEST.
	(distribute_links): Likewise.
	* cse.c (cse_insn): Likewise.
	* cselib.c (cselib_invalidate_mem): Likewise.
	* df.c: Update comments at the top of the file.
	(read_modify_subreg_p): Update comments here too.
	(df_def_record_1): Don't expect a SIGN_EXTRACT in a SET_DEST.
	* flow.c (mark_set_1): Likewise.
	(mark_used_regs): Likewise.
	* gcse.c (mems_conflict_for_gcse_p): Likewise.
	(canon_list_insert): Likewise.
	(mark_set): Likewise.
	(try_replace_reg): Likewise.
	(store_killed_in_insn): Likewise.
	* loop.c (count_one_set): Likewise.
	(basic_induction_var): Likewise.
	* postreload-gcse.c (find_mem_conflicts): Likewise.
	* postreload.c (reload_combine_note_store): Likewise.
	(move2add_note_store): Likewise.
	* reload.c (find_equiv_reg): Likewise.
	(mark_referenced_resources): Likewise.
	* rtlanal.c (set_noop_p): Likewise.
	(note_stores): Likewise.
	(note_uses): Likewise.
	* sched-deps.c (sched_analyze_1): Likewise.
	* sched-rgn.c (check_live_1): Likewise.
	(update_live_1): Likewise.
	* config/i860/i860.c: Likewise.

	* rtl.dec (SIGN_EXTRACT): Document that this cannot appear as
	an lvalue.
	(ZERO_EXTRACT): Mention that this one can be an lvalue.

	* doc/rtl.texi: Update documentation for bit-fields and SET.

From-SVN: r92974
2005-01-05 23:19:23 +00:00
Nathan Sidwell 7932a3db21 bitmap.h (struct bitmap_obstack): New obstack type.
* 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
2004-11-22 12:23:59 +00:00
Kazu Hirata a204196782 basic-block.h (reg_set_iterator): New.
* basic-block.h (reg_set_iterator): New.
	(EXECUTE_IF_SET_IN_REG_SET): Make it iterator style.
	(EXECUTE_IF_AND_COMPL_IN_REG_SET): Likewise.
	(EXECUTE_IF_AND_IN_REG_SET): Likewise.
	* caller-save.c (save_call_clobbered_regs): Adjust to the new
	style.
	* cfgcleanup.c (thread_jump): Likewise.
	* cfgrtl.c (safe_insert_insn_on_edge): Likewise.
	* conflict.c (conflict_graph_compute): Likewise.
	* flow.c (verify_local_live_at_start, update_life_info,
	initialize_uninitialized_subregs, propagate_one_insn,
	init_propagate_block_info, free_propagate_block_info,
	propagate_block, dump_regset): Likewise.
	* global.c (global_conflicts): Likewise.
	* graph.c (start_bb): Likewise.
	* local-alloc.c (update_equiv_regs): Likewise.
	* loop.c (load_mems): Likewise.
	* reload1.c (compute_use_by_pseudos, order_regs_for_reload,
	find_reg, finish_spills): Likewise.
	* resource.c (mark_target_live_regs): Likewise.
	* sched-deps.c (sched_analyze_insn): Likewise.
	* sched-rgn.c (sched-rgn.c): Likewise.
	* config/frv/frv.c (frv_ifcvt_modify_tests): Likewise.

From-SVN: r89226
2004-10-18 15:11:31 +00:00
Nathan Sidwell 41374e13ac ra-build.c (copy_insn_p, [...]): Use gcc_assert and gcc_unreachable instead of abort.
* ra-build.c (copy_insn_p, remember_move, defuse_overlap_p_1,
	live_out_1, prune_hardregs_for_mode, init_one_web_common,
	reinit_one_web, add_subweb, add_subweb_2, init_web_parts,
	record_conflict, compare_and_free_webs, init_webs_defs_uses,
	parts_to_webs_1, parts_to_webs, reset_conflicts,
	check_conflict_numbers, remember_web_was_spilled, handle_asm_insn,
	ra_build_free): Use gcc_assert and gcc_unreachable instead of abort.
	* ra-colorize.c (push_list, put_web, reset_lists, put_web_at_end,
	put_move, remove_move, combine, select_spill, colorize_one_web,
	try_recolor_web, insert_coalesced_conflicts, check_colors,
	break_precolored_alias, restore_conflicts_from_coalesce,
	sort_and_combine_web_pairs, check_uncoalesced_moves): Likewise.
	* ra-rewrite.c (spill_coalescing, slots_overlap_p, emit_loads,
	reloads_to_loads, rewrite_program2, emit_colors): Likewise.
	* ra.c (first_hard_reg, create_insn_info, find_subweb, init_ra,
	check_df): Likewise.
	* real.c (do_add, do_multiply, do_divide, do_compare, do_fix_trunc,
	real_arithmetic, real_compare, real_exponent, real_ldexp,
	real_identical, real_to_integer, real_to_integer2, real_to_decimal,
	real_to_hexadecimal, real_from_integer, ten_to_ptwo, ten_to_mptwo,
	real_digit, real_nan, real_maxval, round_for_format, real_convert,
	real_to_target, real_from_target, real_hash, encode_ieee_single,
	encode_ieee_double, encode_ieee_extended, encode_ieee_quad,
	encode_vax_f, encode_vax_d, encode_vax_g, encode_i370_single,
	encode_i370_double, encode_c4x_single, encode_c4x_extended): Likewise.
	* recog.c (validate_change, validate_replace_rtx_1, asm_operand_ok,
	extract_insn, peep2_next_insn, peep2_reg_dead_p,
	peep2_find_free_register, peephole2_optimize, store_data_bypass_p,
	if_test_bypass_p): Likewise.
	* reg-stack.c (record_label_references, get_asm_operand_n_inputs,
	stack_result, remove_regno_note, get_hard_regnum, emit_pop_insn,
	emit_swap_insn, swap_to_top, move_for_stack_reg,
	subst_stack_regs_pat, subst_asm_stack_regs, change_stack,
	compensate_edge, convert_regs_1): Likewise.
	* regclass.c (init_reg_sets, init_reg_sets_1,
	memory_move_secondary_cost): Likewise.
	* regrename.c (note_sets, clear_dead_regs, scan_rtx_reg, scan_rtx):
	Likewise.
	* reload.c (push_secondary_reload, find_valid_class, push_reload,
	operands_match_p, decompose, immune_p, find_reloads,
	find_reloads_toplev, find_reloads_address_1, subst_reloads,
	copy_replacements, refers_to_regno_for_reload_p,
	reg_overlap_mentioned_for_reload_p): Likewise.
	* reload1.c (compute_use_by_pseudos, replace_pseudos_in, reload,
	count_pseudo, find_reg, eliminate_regs, eliminate_regs_in_insn,
	verify_initial_elim_offsets, finish_spills, clear_reload_reg_in_use,
	reload_reg_free_p, reload_reg_reaches_end_p, reloads_conflict,
	choose_reload_regs, merge_assigned_reloads, emit_input_reload_insns,
	do_output_reload, fixup_abnormal_edges): Likewise.
	* reorg.c (stop_search_p, emit_delay_sequence, get_jump_flags,
	fill_slots_from_thread, relax_delay_slots): Likewise.
	* resource.c (mark_referenced_resources, mark_set_resources):
	Likewise.
	* rtl.c (copy_rtx, rtx_equal_p): Likewise.
	* rtlanal.c (insn_dependent_p, reg_overlap_mentioned_p,
	dead_or_set_p, find_reg_fusage, remove_note, replace_rtx,
	subreg_lsb_1, subreg_regno_offset, subreg_offset_representable_p,
	find_first_parameter_load, can_hoist_insn_p, hoist_update_store,
	hoist_insn_after, hoist_insn_to_edge, nonzero_bits1): Likewise.
	* rtlhooks.c (gen_lowpart_general): Likewise.
	* sbitmap.c (sbitmap_difference): Likewise.
	* sched-deps.c (add_dependence, sched_analyze_1, sched_analyze_2,
	sched_analyze, add_forward_dependence): Likewise.
	* sched-ebb.c (fix_basic_block_boundaries, schedule_ebb): Likewise.
	* sched-rgn.c (debug_regions, compute_trg_info, schedule_region,
	schedule_insns): Likewise.
	* sched-vis.c (print_pattern): Likewise.
	* sdbout.c (sdbout_symbol, sdbout_toplevel_data): Likewise.
	* simplify-rtx.c (simplify_unary_operation, simplify_binary_operation,
	simplify_const_relational_operation, simplify_ternary_operation,
	simplify_immed_subreg, simplify_subreg, simplify_gen_subreg):
	Likewise.
	* sreal.c (copy, sreal_sub, sreal_div): Likewise.
	* stmt.c (force_label_rtx, expand_goto, expand_asm_operands,
	resolve_operand_name_1, expand_return, expand_decl,
	expand_anon_union_decl, emit_case_bit_tests, expand_case): Likewise.
	* stor-layout.c (put_pending_size, smallest_mode_for_size,
	int_mode_for_mode, layout_decl, finish_builtin_struct, layout_type,
	set_sizetype, get_mode_bounds): Likewise.

From-SVN: r87244
2004-09-09 17:19:16 +00:00
Richard Henderson 389fdba06a rtl.h (MEM_READONLY_P): Replace RTX_UNCHANGING_P.
* rtl.h (MEM_READONLY_P): Replace RTX_UNCHANGING_P.
	* alias.c (true_dependence): Update to match new semantics.
	(canon_true_dependence, write_dependence_p): Likewise.
	(anti_dependence, output_dependence): Update write_dependence_p args.
	(unchanging_anti_dependence): Remove.
	* calls.c (purge_mem_unchanging_flag): Remove.
	(fixup_tail_calls): Don't call it.
	(expand_call): Don't add unchanging memory to function usage.
	* expr.c (emit_block_move_via_libcall): Likewise.
	(clear_storage_via_libcall): Don't clobber RTX_UNCHANGING_P mems.
	(get_subtarget): Don't use RTX_UNCHANGING_P.
	(expand_assignment, store_constructor, expand_expr_real_1): Likewise.
	(do_tablejump): Set MEM_READONLY_P, not RTX_UNCHANGING_P.
	* combine.c (get_last_value_validate): Use MEM_READONLY_P.
	* cse.c (insert): Don't use RTX_UNCHANGING_P.
	(cse_insn, canon_hash): Use MEM_READONLY_P.
	* emit-rtl.c (set_mem_attributes_minus_bitpos): Use MEM_READONLY_P
	instead of RTX_UNCHANGING_P.
	* explow.c (maybe_set_unchanging): Remove.
	* expr.h (maybe_set_unchanging): Remove.
	* flow.c (insn_dead_p, mark_used_regs): Use anti_dependence.
	* function.c (assign_stack_temp_for_type): Don't use RTX_UNCHANGING_P.
	(assign_parm_setup_reg, expand_function_start): Likewise.
	* integrate.c (copy_rtx_and_substitute): Likewise.
	* ra-rewrite.c (emit_colors): Likewise.
	* regmove.c (copy_src_to_dest, regmove_optimize): Likewise.
	(fixup_match_1): Likewise.
	* reload1.c (reload, alter_reg): Likewise.
	* local-alloc.c (validate_equiv_mem): Check MEM_READONLY_P,
	not RTX_UNCHANGING_P.
	(equiv_init_varies_p): Likewise.
	* loop-invariant.c (check_maybe_invariant): Likewise.
	* resource.c (mark_referenced_resources, mark_set_resources): Likewise.
	* loop.c (note_addr_stored): Likewise.
	(prescan_loop): Likewise. Don't check function usage for clobbered
	unchanging memory.
	* rtlanal.c (rtx_unstable_p): Check MEM_READONLY_P,
        not RTX_UNCHANGING_P.
	(rtx_varies_p, modified_between_p, modified_in_p): Likewise.
	* varasm.c (force_const_mem): Likewise.
	* stmt.c (expand_decl): Don't set RTX_UNCHANGING_P.
	* web.c (entry_register): Likewise.
	* tree-gimple.h (get_base_address): Move decl ...
	* tree.h: ... here.
	* doc/rtl.texi (MEM_READONLY_P): Replace RTX_UNCHANGING_P.

	* config/alpha/alpha.c (alpha_set_memflags_1): Rewrite to be
	called via for_each_rtx.  Copy MEM_SCALAR_P, MEM_NOTRAP_P too.
	(alpha_set_memflags): Update to match.

	* config/darwin.c (machopic_indirect_data_reference): Set
	MEM_READONLY_P instead of RTX_UNCHANGING_P.
	(machopic_indirect_call_target): Likewise.
	(machopic_legitimize_pic_address): Likewise.
	* config/arm/arm.c (legitimize_pic_address, arm_gen_load_multiple,
	arm_gen_store_multiple, arm_gen_movmemqi): Likewise.
	* config/arm/arm.md (load_multiple, store_multiple): Likewise.
	* config/frv/frv.md (symGOT2reg): Likewise.
	* config/i386/i386.c (legitimize_pic_address,
	legitimize_tls_address, ix86_split_to_parts): Likewise.
	* config/ia64/ia64.c (ia64_expand_tls_address): Likewise.
	* config/ia64/ia64.md (load_fptr): Likewise.
	* config/m32r/m32r.c (m32r_legitimize_pic_address): Likewise.
	* config/m68k/m68k.c (legitimize_pic_address): Likewise.
	* config/mcore/mcore.c (block_move_sequence): Likewise.
	* config/mn10300/mn10300.md (symGOT2reg): Likewise.
	* config/pa/pa.c (legitimize_pic_address): Likewise.
	* config/rs6000/rs6000.c (rs6000_legitimize_tls_address): Likewise.
	(rs6000_emit_move): Likewise.
	* config/s390/s390.c (legitimize_pic_address): Likewise.
	(legitimize_tls_address): Likewise.
	* config/s390/s390.md (casesi): Likewise.
	* config/sh/sh.c (prepare_move_operands, sh_reorg): Likewise.
	* config/sh/sh.md (symGOT2reg): Likewise.
	* config/sparc/sparc.c (legitimize_pic_address): Likewise.
	* config/v850/v850.md (casesi): Likewise.

	* config/ia64/ia64.c (gen_thread_pointer): Don't set RTX_UNCHANGING_P.
	* config/iq2000/iq2000.c (save_restore_insns): Likewise.
	* config/mips/mips.c (mips_restore_gp): Likewise.
	(mips_save_restore_reg, mips16_gp_pseudo_reg): Likewise.
	* config/sh/sh.c (sh_reorg): Likewise.

From-SVN: r86178
2004-08-18 01:25:01 -07:00
Eric Botcazou 6e456a1054 re PR rtl-optimization/16294 (Missed delay slot scheduling opportunity)
PR rtl-optimization/16294
	* resource.c (return_insn_p): New predicate.
	(mark_target_live_regs): Use it.  Special-case return insns.
	(init_resource_info): Use it.  Don't scan the epilogue past
	a return.

From-SVN: r84874
2004-07-17 18:12:37 +00:00
Jerry Quinn 4b4bf9414f alias.c (nonlocal_mentioned_p, [...]): Use, LABEL_P, JUMP_P, CALL_P, NONJUMP_INSN_P, INSN_P, NOTE_P, BARRIER_P.
2004-07-08  Jerry Quinn  <jlquinn@optonline.net>

	* alias.c (nonlocal_mentioned_p, nonlocal_referenced_p,
	nonlocal_set_p, init_alias_analysis): Use, LABEL_P, JUMP_P, CALL_P,
	NONJUMP_INSN_P, INSN_P, NOTE_P, BARRIER_P.
	* bb-reorder.c (mark_bb_for_unlikely_executed_section,
	add_labels_and_missing_jumps, find_jump_block,
	fix_crossing_unconditional_branches, add_reg_crossing_jump_notes):
	Likewise.
	* bt-load.c (btr_referenced_p, compute_defs_uses_and_gen,
	link_btr_uses, move_btr_def): Likewise.
	* builtins.c (expand_builtin_longjmp, expand_builtin_nonlocal_goto,
	expand_builtin_expect_jump): Likewise.
	* caller-save.c (save_call_clobbered_regs, insert_one_insn): Likewise.
	* calls.c (expand_call, emit_library_call_value_1): Likewise.
	* cfganal.c (forwarder_block_p): Likewise.
	* cfgbuild.c (inside_basic_block_p, count_basic_blocks,
	make_label_edge, rtl_make_eh_edge, make_edges, find_basic_blocks_1,
	find_bb_boundaries): Likewise.
	* cfgcleanup.c (try_simplify_condjump, try_forward_edges,
	merge_blocks_move_predecessor_nojumps,
	merge_blocks_move_successor_nojumps, insns_match_p,
	flow_find_cross_jump, outgoing_edges_match, try_crossjump_to_edge,
	try_optimize_cfg): Likewise.
	* cfgexpand.c (expand_block, construct_exit_block): Likewise.
	* cfglayout.c (skip_insns_after_block, label_for_bb,
	record_effective_endpoints, insn_locators_initialize,
	fixup_reorder_chain, update_unlikely_executed_notes): Likewise.
	* cfgmainloop.c (create_loop_notes): Likewise.
	* cfgrtl.c (delete_insn, delete_insn_chain,
	create_basic_block_structure, rtl_delete_block, free_bb_for_insn,
	update_bb_for_insn, rtl_merge_blocks, rtl_can_merge_blocks,
	block_label, try_redirect_by_replacing_jump, last_loop_beg_note,
	redirect_branch_edge, force_nonfallthru_and_redirect,
	rtl_tidy_fallthru_edge, back_edge_of_syntactic_loop_p,
	rtl_split_edge, commit_one_edge_insertion, print_rtl_with_bb,
	update_br_prob_note, rtl_verify_flow_info_1, rtl_verify_flow_info,
	purge_dead_edges, cfg_layout_redirect_edge_and_branch,
	cfg_layout_delete_block, cfg_layout_can_merge_blocks_p,
	cfg_layout_merge_blocks, rtl_block_ends_with_call_p,
	need_fake_edge_p, rtl_flow_call_edges_add): Likewise.
	* combine.c (combine_instructions, can_combine_p, try_combine,
	find_split_point, record_dead_and_set_regs, reg_dead_at_p,
	distribute_notes, distribute_links, insn_cuid): Likewise.
	* cse.c (fold_rtx, cse_insn, cse_around_loop,
	invalidate_skipped_block, cse_set_around_loop,
	cse_end_of_basic_block, cse_main, cse_basic_block,
	cse_condition_code_reg): Likewise.
	* cselib.c (cselib_process_insn): Likewise.
	* ddg.c (create_ddg): Likewise.
	* df.c (df_insn_refs_record, df_bb_rd_local_compute, df_insns_modify):
	Likewise.
	* dwarf2out.c (dwarf2out_stack_adjust, dwarf2out_frame_debug,
	gen_label_die, dwarf2out_var_location): Likewise.
	* emit-rtl.c (get_first_nonnote_insn, get_last_nonnote_insn,
	next_insn, previous_insn, next_nonnote_insn, prev_nonnote_insn,
	last_call_insn, active_insn_p, next_label, prev_label,
	link_cc0_insns, next_cc0_user, try_split, add_insn_after,
	add_insn_before, remove_insn, add_function_usage_to,
	reorder_insns, find_line_note, remove_unnecessary_notes,
	emit_insn_after_1, classify_insn): Likewise.
	* except.c (convert_from_eh_region_ranges_1, emit_to_new_bb_before,
	connect_post_landing_pads, sjlj_mark_call_sites,
	sjlj_emit_function_enter, sjlj_emit_function_exit, reachable_handlers,
	can_throw_internal, can_throw_external, set_nothrow_function_flags,
	convert_to_eh_region_ranges): Likewise.
	* explow.c (optimize_save_area_alloca): Likewise.
	* expr.c (expand_expr_real): Likewise.
	* final.c (insn_current_reference_address, compute_alignments,
	shorten_branches, final, scan_ahead_for_unlikely_executed_note,
	final_scan_insn, output_asm_label, leaf_function_p): Likewise.
	* flow.c (first_insn_after_basic_block_note, delete_dead_jumptables,
	propagate_block_delete_insn, propagate_one_insn,
	init_propagate_block_info, propagate_block, libcall_dead_p,
	mark_set_1, attempt_auto_inc, find_auto_inc, try_pre_increment):
	Likewise.
	* function.c (instantiate_virtual_regs,	reorder_blocks_1,
	expand_function_start, expand_function_end, contains,
	thread_prologue_and_epilogue_insns,
	reposition_prologue_and_epilogue_notes): Likewise.
	* gcse.c (constprop_register, bypass_conditional_jumps,
	insert_insn_end_bb, gcse_after_reload): Likewise.
	* genemit.c (gen_expand, gen_split): Likewise.
	* genpeep.c (gen_peephole, main): Likewise.
	* global.c (build_insn_chain): Likewise.
	* graph.c (node_data, print_rtl_graph_with_bb): Likewise.
	* haifa-sched.c (unlink_other_notes, unlink_line_notes,
	get_block_head_tail, no_real_insns_p, rm_line_notes, save_line_notes,
	restore_line_notes, rm_redundant_line_notes, rm_other_notes,
	ok_for_early_queue_removal, set_priorities, sched_init): Likewise.
	* ifcvt.c (count_bb_insns, first_active_insn, last_active_insn,
	cond_exec_process_insns, end_ifcvt_sequence, noce_process_if_block,
	merge_if_block, block_jumps_and_fallthru_p, find_if_block,
	dead_or_predicable): Likewise.
	* integrate.c (try_constants): Likewise.
	* jump.c (rebuild_jump_labels, cleanup_barriers,
	purge_line_number_notes, init_label_info, mark_all_labels,
	squeeze_notes, get_label_before, get_label_after,
	reversed_comparison_code_parts, simplejump_p, pc_set,
	returnjump_p, onlyjump_p, follow_jumps, mark_jump_label,
	delete_barrier, delete_prior_computation, delete_computation,
	delete_related_insns, delete_for_peephole, redirect_jump):
	Likewise.
	* lcm.c (optimize_mode_switching): Likewise.
	* local-alloc.c (validate_equiv_mem, update_equiv_regs, block_alloc):
	Likewise.
	* loop-doloop.c (doloop_valid_p, doloop_optimize): Likewise.
	* loop-invariant.c (find_exits, find_invariants_bb): Likewise.
	* loop-iv.c (simplify_using_assignment): Likewise.
	* loop.c (compute_luids, loop_optimize, scan_loop, libcall_other_reg,
	libcall_benefit, skip_consec_insns, move_movables, prescan_loop,
	find_and_verify_loops, labels_in_range_p, for_each_insn_in_loop,
	loop_bivs_init_find, strength_reduce, check_insn_for_bivs,
	check_insn_for_givs, check_final_value, update_giv_derive,
	basic_induction_var, product_cheap_p, check_dbra_loop,
	loop_insn_first_p, last_use_this_basic_block,
	canonicalize_condition, get_condition, loop_regs_scan, load_mems,
	try_copy_prop, LOOP_BLOCK_NUM, loop_dump_aux): Likewise.
	* modulo-sched.c (doloop_register_get, find_line_note, sms_schedule,
	sms_schedule_by_order): Likewise.
	* optabs.c (emit_no_conflict_block, emit_libcall_block): Likewise.
	* postreload.c (reload_cse_simplify_operands, reload_combine,
	reload_cse_move2add): Likewise.
	* predict.c (can_predict_insn_p, estimate_probability,
	expected_value_to_br_prob, process_note_predictions): Likewise.
	* print-rtl.c (print_rtx, print_rtl, print_rtl_single): Likewise.
	* profile.c (branch_prob): Likewise.
	* ra-build.c (live_out_1, livethrough_conflicts_bb,
	detect_webs_set_in_cond_jump): Likewise.
	* ra-debug.c (ra_print_rtx_object, ra_debug_insns,
	ra_print_rtl_with_bb): Likewise.
	* ra-rewrite.c (insert_stores, rewrite_program2): Likewise.
	* recog.c (next_insn_tests_no_inequality, find_single_use,
	split_all_insns, peephole2_optimize, if_test_bypass_p): Likewise.
	* reg-stack.c (next_flags_user, record_label_references,
	emit_swap_insn, swap_rtx_condition, subst_stack_regs,
	compensate_edge, convert_regs_1): Likewise.
	* regclass.c (scan_one_insn): Likewise.
	* regmove.c (optimize_reg_copy_1, optimize_reg_copy_2, fixup_match_2,
	regmove_optimize, fixup_match_1, single_set_for_csa,
	combine_stack_adjustments_for_block): Likewise.
	* regrename.c (build_def_use, copyprop_hardreg_forward_1): Likewise.
	* reload.c (find_reloads, find_reloads_address_1, subst_reloads,
	find_equiv_reg): Likewise.
	* reload1.c (reload, calculate_needs_all_insns, set_label_offsets,
	reload_as_needed, emit_input_reload_insns, do_output_reload,
	delete_output_reload, delete_address_reloads_1, fixup_abnormal_edges):
	Likewise.
	* reorg.c (find_end_label, emit_delay_sequence,
	delete_from_delay_slot, delete_scheduled_jump, optimize_skip,
	get_jump_flags, rare_destination, mostly_true_jump,
	try_merge_delay_insns, redundant_insn, own_thread_p,
	fill_simple_delay_slots, fill_slots_from_thread,
	fill_eager_delay_slots, relax_delay_slots, make_return_insns,
	dbr_schedule): Likewise.
	* resource.c (find_basic_block, next_insn_no_annul,
	find_dead_or_set_registers, mark_target_live_regs): Likewise.
	* rtl.h (RTX_PREV): Likewise.
	* rtlanal.c (global_reg_mentioned_p, no_labels_between_p,
	no_jumps_between_p, reg_used_between_p, reg_referenced_between_p,
	reg_set_p, find_last_value, dead_or_set_regno_p, find_reg_fusage,
	find_regno_fusage, pure_call_p, replace_label, rtx_referenced_p_1,
	tablejump_p, computed_jump_p, insns_safe_to_move_p,
	find_first_parameter_load, can_hoist_insn_p): Likewise.
	* sched-deps.c (get_condition, add_dependence, sched_analyze_2,
	sched_analyze_insn, sched_analyze, add_forward_dependence): Likewise.
	* sched-ebb.c (fix_basic_block_boundaries, add_deps_for_risky_insns,
	schedule_ebbs): Likewise.
	* sched-rgn.c (is_cfg_nonregular, find_conditional_protection,
	is_conditionally_protected, can_schedule_ready_p,
	add_branch_dependences, debug_dependencies): Likewise.
	* stmt.c (emit_nop, expand_start_case, emit_jump_if_reachable):
	Likewise.
	* unroll.c (unroll_loop, copy_loop_body, back_branch_in_range_p,
	reg_dead_after_loop, loop_find_equiv_value, loop_iterations,
	set_dominates_use, ujump_to_loop_cont): Likewise.
	* var-tracking.c (prologue_stack_adjust, vt_initialize): Likewise.
	* varasm.c (output_constant_pool_1): Likewise.

From-SVN: r84341
2004-07-09 03:29:35 +00:00
Jerry Quinn 3c0cb5de6a alias.c (get_alias_set, [...]): Use MEM_P.
2004-07-01  Jerry Quinn  <jlquinn@optonline.net>

	* alias.c (get_alias_set, canon_rtx, get_addr,
	nonoverlapping_memrefs_p, nonlocal_referenced_p_1, memory_modified_1):
	Use MEM_P.
	* builtins.c (expand_builtin_prefetch, expand_builtin_profile_func,
	expand_builtin): Likewise.
	* calls.c (expand_call, emit_library_call_value_1, store_one_arg):
	Likewise.
	* combine.c (can_combine_p, combinable_i3pat, try_combine,
	find_split_point, combine_simplify_rtx, simplify_set, make_extraction,
	rtx_equal_for_field_assignment_p, gen_lowpart_for_combine,
	record_dead_and_set_regs_1, get_last_value_validate,
	mark_used_regs_combine, move_deaths, unmentioned_reg_p_1): Likewise.
	* cse.c (check_dependence, canon_hash, equiv_constant,
	gen_lowpart_if_possible, cse_insn, invalidate_from_clobbers,
	cse_around_loop, cse_check_loop_start, cse_set_around_loop,
	count_reg_usage): Likewise.
	* cselib.c (rtx_equal_for_cselib_p, add_mem_for_addr, cselib_lookup,
	cselib_invalidate_mem, cselib_invalidate_rtx, cselib_record_set,
	cselib_record_sets): Likewise.
	* dbxout.c (PARM_PASSED_IN_MEMORY, dbxout_symbol,
	dbxout_symbol_location, dbxout_parms, dbxout_reg_parms): Likewise.
	* ddg.c (mark_mem_use, mark_mem_store, rtx_mem_access_p): Likewise.
	* df.c (df_uses_record): Likewise.
	* dojump (do_jump): Likewise.
	* dwarf2out.c (stack_adjust_offset, mem_loc_descriptor,
	loc_descriptor_from_tree, rtl_for_decl_location, add_bound_info,
	decl_start_label): Likewise.
	* emit-rtl.c (gen_complex_constant_part, gen_highpart,
	operand_subword, change_address_1, make_safe_from): Likewise.
	* explow.c (break_out_memory_refs, copy_all_regs, validize_mem,
	stabilize, force_not_mem): Likewise.
	* expmed.c (store_bit_field, store_split_bit_field, extract_bit_field,
	expand_mult_const, expand_divmod, emit_store_flag): Likewise.
	* expr.c (convert_move, convert_modes, emit_block_move,
	emit_group_load, emit_group_store, clear_storage, emit_move_insn,
	emit_move_insn_1, expand_assignment, store_expr,
	store_constructor_field, store_constructor, store_field,
	force_operand, safe_from_p, expand_expr_real_1, expand_increment):
	Likewise.
	* final.c (cleanup_subreg_operands, alter_subreg,
	get_mem_expr_from_op): Likewise.
	* flow.c (notice_stack_pointer_modification_1,
	init_propagate_block_info, insn_dead_p, mark_set_1, mark_used_regs):
	Likewise.
	* function.c (mark_temp_addr_taken, preserve_temp_slots,
	preserve_rtl_expr_result, put_var_into_stack, fixup_var_refs_1,
	optimize_bit_field, flush_addressof, purge_addressof_1,
	instantiate_decl, instantiate_virtual_regs_1, assign_parms,
	setjmp_protect, setjmp_protect_args, fix_lexical_addr,
	keep_stack_depressed): Likewise.
	* ifcvt.c (noce_try_cmove_arith, noce_try_abs, noce_operand_ok,
	noce_process_if_block, find_memory): Likewise.
	* integrate.c (subst_constants, allocate_initial_values): Likewise.
	* local-alloc.c (validate_equiv_mem_from_store, memref_referenced_p,
	update_equiv_regs): Likewise.
	* loop.c (scan_loop, prescan_loop, note_addr_stored, check_store,
	maybe_eliminate_biv_1, find_mem_in_note_1): Likewise.
	* optabs.c (expand_abs, emit_unop_insn): Likewise.
	* passes.c (rest_of_handle_final): Likewise.
	* postreload.c (reload_cse_simplify_set, reload_cse_simplify_operands,
	move2add_note_store): Likewise.
	* ra-build.c (detect_remat_webs): Likewise.
	* ra-debug.c (dump_static_insn_cost): Likewise.
	* ra-rewrite.c (slots_overlap_p, insert_stores): Likewise.
	* recog.c (validate_change, apply_change_group, cancel_changes,
	validate_replace_rtx_1, general_operand, register_operand,
	nonmemory_operand, push_operand, pop_operand, memory_operand,
	indirect_operand, asm_operand_ok, offsettable_memref_p,
	offsettable_nonstrict_memref_p, constrain_operands,
	store_data_bypass_p): Likewise.
	* reg-stack.c (subst_stack_regs_pat): Likewise.
	* regclass.c (record_operand_costs, scan_one_insn, record_reg_classes,
	copy_cost, reg_scan_mark_refs): Likewise.
	* regmove.c (optimize_reg_copy_3, stack_memref_p,
	combine_stack_adjustments_for_block): Likewise.
	* regrename.c (copyprop_hardreg_forward_1): Likewise.
	* reload.c (can_reload_into, push_reload, decompose, immune_p,
	find_reloads, find_reloads_address, find_reloads_address_1,
	reg_overlap_mentioned_for_reload_p, refers_to_mem_for_reload_p,
	find_equiv_reg): Likewise.
	* reload1.c (reload, eliminate_regs, eliminate_regs_in_insn,
	reload_as_needed, choose_reload_regs, emit_input_reload_insns,
	do_input_reload, emit_reload_insns, gen_reload, delete_output_reload,
	delete_address_reloads): Likewise.
	* resource.c (mark_referenced_resources): Likewise.
	* rtlanal.c (get_jump_table_offset, count_occurrences,
	reg_referenced_p, reg_set_p, set_of_1, set_noop_p,
	reg_overlap_mentioned_p, note_uses, replace_regs, nonzero_bits1,
	num_sign_bit_copies1): Likewise.
	* rtlhooks.c (gen_lowpart_general): Likewise.
	* sched-deps.c (sched_analyze_1, sched_analyze_2): Likewise.
	* sdbout.c (PARM_PASSED_IN_MEMORY, sdbout_symbol,
	sdbout_toplevel_data, sdbout_parms, sdbout_reg_parms,
	sdbout_global_decl): Likewise.
	* simplify-rtx.c (simplify_subreg): Likewise.
	* stmt.c (expand_asm_operands, expand_expr_stmt_value, expand_decl,
	expand_anon_union_decl, expand_end_case_type): Likewise.
	* unroll.c (calculate_giv_inc): Likewise.
	* var-tracking.c (stack_adjust_offset_pre_post,
	bb_stack_adjust_offset, track_expr_p, count_uses, add_uses,
	add_stores, compute_bb_dataflow, vt_get_decl_and_offset,
	vt_add_function_parameters): Likewise.
	* varasm.c (make_var_volatile, notice_global_symbol,
	assemble_external, decode_addr_const, mark_weak,
	default_encode_section_info): Likewise.

From-SVN: r83980
2004-07-01 12:52:53 +00:00
Jerry Quinn f8cfc6aa07 alias.c (record_set, [...]): Use REG_P.
2004-06-15  Jerry Quinn  <jlquinn@optonline.net>

	* alias.c (record_set, record_base_value, canon_rtx, get_addr,
	nonlocal_mentioned_p_1, init_alias_analysis): Use REG_P.
	* bt-load.c (find_btr_reference, insn_sets_btr_p, note_btr_set):
	Likewise.
	* builtins.c (expand_builtin_setjmp, expand_builtin_apply,
	expand_builtin_mathfn, expand_builtin_strlen, expand_builtin_memcmp,
	expand_builtin_strcmp, expand_builtin_strncmp,
	expand_builtin_frame_address): Likewise.
	* caller-save.c (mark_set_regs, add_stored_regs, mark_referenced_regs,
	insert_one_insn): Likewise.
	* calls.c (prepare_call_address, precompute_register_parameters,
	precompute_arguments, expand_call, emit_library_call_value_1): Likewise.
	* cfganal.c (flow_active_insn_p): Likewise.
	* combine.c (set_nonzero_bits_and_sign_copies, can_combine_p,
	combinable_i3pat, try_combine, find_split_point, COMBINE_RTX_EQUAL_P,
	subst, combine_simplify_rtx, simplify_if_then_else, simplify_set,
	make_extraction, recog_for_combine, gen_lowpart_for_combine,
	simplify_comparison, record_dead_and_set_regs_1,
	record_dead_and_set_regs, record_promoted_value,
	check_promoted_subreg, get_last_value_validate, get_last_value,
	reg_dead_at_p_1, reg_bitfield_target_p, distribute_notes,
	unmentioned_reg_p_1): Likewise.
	* conflict.c (mark_reg): Likewise.
	* cse.c (HASH, COST, COST_IN, approx_reg_cost_1, notreg_cost,
	mention_regs, insert_regs, lookup, lookup_for_remove, insert,
	merge_equiv_classes, flush_hash_table, invalidate,
	remove_invalid_refs, remove_invalid_subreg_refs, rehash_using_reg,
	invalidate_for_call, use_related_value, canon_hash, exp_equiv_p,
	cse_rtx_varies_p, canon_reg, find_best_addr, fold_rtx, equiv_constant,
	record_jump_cond, cse_insn, addr_affects_sp_p,
	invalidate_from_clobbers, cse_process_notes, cse_around_loop,
	cse_set_around_loop, count_reg_usage, set_live_p, cse_change_cc_mode,
	cse_cc_succs, cse_condition_code_reg): Likewise.
	* cselib.c (cselib_reg_set_mode, rtx_equal_for_cselib_p,
	cselib_lookup, cselib_invalidate_regno, cselib_invalidate_rtx,
	cselib_record_set, cselib_record_sets): Likewise.
	* dbxout.c (dbxout_symbol_location, dbxout_parms, dbxout_reg_parms,
	dbxout_block): Likewise.
	* df.c (df_ref_record, df_def_record_1, df_uses_record): Likewise.
	* dojump.c (do_jump): Likewise.
	* dwarf2out.c (dwarf2out_frame_debug_expr, is_pseudo_reg,
	is_based_loc, rtl_for_decl_location): Likewise.
	* emit-rtl.c (set_reg_attrs_for_parm, set_decl_rtl,
	set_decl_incoming_rtl, mark_user_reg): Likewise.
	* explow.c (copy_all_regs, copy_all_regs, memory_address, force_reg,
	copy_to_suggested_reg, allocate_dynamic_stack_space,
	probe_stack_range, hard_function_value): Likewise.
	* expmed.c (store_bit_field, store_fixed_bit_field,
	store_split_bit_field, extract_bit_field, extract_fixed_bit_field,
	extract_split_bit_field, expand_divmod, emit_store_flag_force):
	Likewise.
	* expr.c (convert_move, convert_modes,
	block_move_libcall_safe_for_call_parm, emit_group_load, use_reg,
	use_group_regs, emit_move_insn, emit_move_insn_1,
	compress_float_constant, push_block, emit_single_push_insn,
	emit_push_insn, get_subtarget, expand_assignment, store_expr,
	store_constructor, store_field, force_operand, safe_from_p,
	expand_expr_real_1, expand_increment, do_store_flag, do_tablejump):
	Likewise.
	* final.c (profile_function, final_scan_insn, alter_subreg,
	get_mem_expr_from_op, output_asm_operand_names, output_operand,
	only_leaf_regs_used, leaf_renumber_regs_insn): Likewise.
	* flow.c (verify_wide_reg_1, mark_regs_live_at_end,
	find_regno_partial, propagate_one_insn, init_propagate_block_info,
	insn_dead_p, libcall_dead_p, mark_set_1, not_reg_cond,
	attempt_auto_inc, find_auto_inc, mark_used_regs,
	count_or_remove_death_notes_bb): Likewise.
	* function.c (find_temp_slot_from_address, update_temp_slot_address,
	preserve_temp_slots, put_var_into_stack, fixup_var_refs_insn,
	fixup_var_refs_1, fixup_stack_1, optimize_bit_field, flush_addressof,
	put_addressof_into_stack, purge_addressof_1, insns_for_mem_walk,
	purge_single_hard_subreg_set, instantiate_decl,
	instantiate_virtual_regs_1, aggregate_value_p, assign_parms,
	promoted_input_arg, setjmp_vars_warning, setjmp_args_warning,
	setjmp_protect, setjmp_protect_args, fix_lexical_addr,
	expand_function_start, diddle_return_value, clobber_return_register,
	expand_function_end, keep_stack_depressed, handle_epilogue_set,
	update_epilogue_consts): Likewise.
	* genemit.c (gen_exp, gen_insn): Likewise.
	* genrecog.c (make_insn_sequence): Likewise.
	* global.c (global_conflicts, expand_preferences, mark_reg_store,
	mark_reg_conflicts, set_preference, reg_becomes_live,
	build_insn_chain, mark_reg_change): Likewise.
	* haifa_sched.c (CONST_BASED_ADDRESS_P, find_set_reg_weight):
	Likewise.
	* ifcvt.c (noce_try_abs, noce_get_condition, noce_process_if_block):
	Likewise.
	* integrate.c (copy_rtx_and_substitute, try_constants,
	subst_constants, mark_stores, allocate_initial_values): Likewise.
	* jump.c (reversed_comparison_code_parts, delete_prior_computation,
	delete_computation, rtx_renumbered_equal_p, true_regnum,
	reg_or_subregno): Likewise.
	* lcm.c (reg_dies, reg_becomes_live): Likewise.
	* local-alloc.c (validate_equiv_mem_from_store, validate_equiv_mem,
	update_equiv_regs, no_equiv, block_alloc, combine_regs, reg_is_set,
	wipe_dead_reg, no_conflict_p): Likewise.
	* loop-iv.c (simple_reg_p, simple_set_p, kill_sets,
	iv_get_reaching_def, iv_analyze_biv, altered_reg_used, mark_altered,
	simple_rhs_p, simplify_using_assignment, implies_p): Likewise.
	* loop.c (scan_loop, combine_movables, rtx_equal_for_loop_p,
	move_movables, note_set_pseudo_multiple_uses, consec_sets_invariant_p,
	find_single_use_in_loop, count_one_set, loop_bivs_init_find,
	loop_givs_rescan, check_insn_for_bivs, check_insn_for_givs,
	valid_initial_value_p, simplify_giv_expr, consec_sets_giv,
	loop_regs_update, check_dbra_loop, maybe_eliminate_biv,
	maybe_eliminate_biv_1, record_initial, update_reg_last_use,
	canonicalize_condition, loop_regs_scan, load_mems, try_copy_prop,
	try_swap_copy_prop): Likewise.
	* optabs.c (expand_binop, expand_vector_binop, expand_vector_unop,
	expand_abs, emit_no_conflict_block, emit_libcall_block, expand_float):
	Likewise.
	* postreload.c (reload_cse_simplify, reload_cse_simplify_set,
	reload_cse_simplify_operands, reload_combine,
	reload_combine_note_store, reload_combine_note_use,
	reload_cse_move2add, move2add_note_store): Likewise.
	* print-rtl.c (print_rtx): Likewise.
	* ra-build.c (copy_insn_p, remember_move, init_one_web_common,
	contains_pseudo, handle_asm_insn): Likewise.
	* ra-debug.c (ra_print_rtx_object, dump_constraints,
	dump_static_insn_cost): Likewise.
	* ra-rewrite.c (slots_overlap_p, emit_colors,
	remove_suspicious_death_notes): Likewise.
	* recog.c (validate_replace_rtx_1, find_single_use_1, find_single_use,
	register_operand, scratch_operand, nonmemory_operand,
	constrain_operands): Likewise.
	* reg-stack (check_asm_stack_operands, remove_regno_note,
	emit_swap_insn, swap_rtx_condition, subst_stack_regs_pat,
	subst_asm_stack_regs): Likewise.
	* regclass.c (scan_one_insn, record_reg_classes, copy_cost,
	record_address_regs, reg_scan_mark_refs): Likewise.
	* regmove.c (discover_flags_reg, replacement_quality,
	copy_src_to_dest, reg_is_remote_constant_p, regmove_optimize,
	fixup_match_1): Likewise.
	* regrename.c (note_sets, clear_dead_regs, build_def_use, kill_value,
	kill_set_value, copyprop_hardreg_forward_1): Likewise.
	* reload.c (MATCHES, push_secondary_reload, find_reusable_reload,
	reload_inner_reg_of_subreg, can_reload_into, push_reload,
	combine_reloads, find_dummy_reload, hard_reg_set_here_p,
	operands_match_p, decompose, find_reloads, find_reloads_toplev,
	find_reloads_address, subst_indexed_address, find_reloads_address_1,
	find_reloads_subreg_address, find_replacement,
	refers_to_regno_for_reload_p, reg_overlap_mentioned_for_reload_p,
	refers_to_mem_for_reload_p, find_equiv_reg, regno_clobbered_p): Likewise.
	* reload1.c (replace_pseudos_in, reload, calculate_needs_all_insns,
	find_reg, delete_dead_insn, alter_reg, eliminate_regs,
	elimination_effects, eliminate_regs_in_insn, scan_paradoxical_subregs,
	forget_old_reloads_1, reload_reg_free_for_value_p, choose_reload_regs,
	emit_input_reload_insns, emit_output_reload_insns, do_input_reload,
	do_output_reload, emit_reload_insns, gen_reload,
	delete_address_reloads_1, inc_for_reload): Likewise.
	* reorg.c (update_reg_dead_notes, fix_reg_dead_note,
	update_reg_unused_notes, fill_slots_from_thread): Likewise.
	* resource.c (update_live_status, mark_referenced_resources,
	mark_set_resources, mark_target_live_regs): Likewise.
	* rtlanal.c (nonzero_address_p, get_jump_table_offset,
	global_reg_mentioned_p_1, reg_mentioned_p, reg_referenced_p,
	reg_set_p, set_noop_p, find_last_value, refers_to_regno_p,
	note_stores, dead_or_set_p, dead_or_set_regno_p, find_regno_note,
	find_reg_fusage, find_regno_fusage, replace_regs, regno_use_in,
	parms_set, find_first_parameter_load, keep_with_call_p,
	hoist_test_store, hoist_update_store, address_cost, nonzero_bits1,
	num_sign_bit_copies1): Likewise.
	* rtlhooks.c (gen_lowpart_general): Likewise.
	* sched-deps.c (deps_may_trap_p, sched_analyze_1, sched_analyze_insn,
	sched_analyze): Likewise.
	* sched-rgn.c (check_live_1, update_live_1, sets_likely_spilled_1):
	Likewise.
	* sdbout.c (sdbout_symbol, sdbout_parms, sdbout_reg_parms): Likewise.
	* simplify-rtx.c (simplify_replace_rtx, simplify_unary_operation,
	simplify_binary_operation, simplify_const_relational_operation,
	simplify_subreg): Likewise.
	* stmt.c (decl_conflicts_with_clobbers_p, expand_asm_operands,
	expand_end_stmt_expr, expand_return, expand_decl,
	expand_anon_union_decl): Likewise.
	* unroll.c (precondition_loop_p, calculate_giv_inc, copy_loop_body,
	find_splittable_regs, find_splittable_givs, find_common_reg_term,
	loop_iterations): Likewise.
	* var-tracking.c (variable_union, variable_part_different_p,
	variable_different_p, count_uses, add_uses, add_stores,
	compute_bb_dataflow, set_variable_part, delete_variable_part,
	emit_notes_in_bb, vt_get_decl_and_offset, vt_add_function_parameters):
	Likewise.
	* varasm.c (assemble_variable): Likewise.

From-SVN: r83195
2004-06-15 18:02:40 +00:00
Kazu Hirata e146f815b8 alloc-pool.h, [...]: Update copyright.
gcc/
	* alloc-pool.h, c-convert.c, c-lang.c, c-tree.h,
	caller-save.c, df.h, genconfig.c, global.c, lcm.c,
	ra-rewrite.c, ra.c, regclass.c, regs.h, resource.c,
	sched-rgn.c, config/arm/aof.h, config/arm/cirrus.md,
	config/arm/fpa.md, config/arm/iwmmxt.md,
	config/arm/netbsd-elf.h, config/arm/netbsd.h,
	config/m68hc11/m68hc11.md, config/mips/iris5.h,
	config/mn10300/mn10300.md, config/rs6000/altivec.md,
	config/sparc/netbsd-elf.h: Update copyright.

	cp/
	* error.c, search.c: Update copyright.

	java/
	* typeck.c: Update copyright.

From-SVN: r77265
2004-02-04 19:15:30 +00:00
Jan Hubicka 66fd46b6c6 alias.c (record_set): Use hard_regno_nregs.
* alias.c (record_set): Use hard_regno_nregs.
	* bt-load.c (find_btr_reference, note_btr_set): Likewise.
	* builtins.c (apply_args_size): Likewise.
	* caller-save.c (setup_save_areas, save_call_clobbered_regs,
	mark_set_regs, add_stored_regs, mark_referenced_regs,
	insert_restore, insert_save, insert_one_insn): Likewise.
	* cfgcleanup.c: Include regs.h
	(mark_effect, mentions_nonequal_regs): Likewise.
	* cfgrtl.c (mark_killed_regs): Likewise
	* combine.c (update_table_tick, record_value_for_reg,
	record_dead_and_set_regs, get_last_value_validate, use_crosses_set_p,
	reg_dead_at_p_1, reg_dead_at_p, mark_used_regs_combine, move_deaths,
	reg_bitfield_target_p, distribute_notes): Likewise.
	* cse.c (mention_regs, insert, invalidate, invalidate_for_call,
	exp_equiv_p, cse_insn): Likewise.
	* cselib.c (cselib_lookup): Likewise.
	(cselib_invalidate_regno, cselib_record_set): Likewise.
	* df.c (df_ref_record): Likewise.
	* dwarf2out.c (reg_loc_descriptor, multiple_reg_loc_descriptor):
	Likewise.
	* flow.c (mark_reg, insn_dead_p, mark_set_1, mark_used_reg,
	count_or_remove_death_notes_bb): Likewise.
	* function.c (aggregate_value_p, keep_stack_depressed): Likewise.
	* gloval.c (global_alloc, find_reg, mark_reg_store, mark_reg_conflicts,
	mark_reg_death, set_preference, reg_becomes_live, reg_dies): Likewise.
	* integrate.c (mark_stores): Likewise.
	* jump.c (delete_prior_computation): Likewise.
	* lcm.c (reg_dies, reg_becomes_live): Likewise.
	* local-alloc.c (combine_regs, find_free_reg, post_mark_life): Likewise.
	* loop.c (LOOP_REGNO_NREGS): Likewise.
	* postreload.c (reload_combine, reload_combine_note_store,
	reload_combine_note_use, reload_cse_move2add, move2add_note_store): Likewise.
	* ra-colorize.c (combine, color_usable_p, get_free_reg,
	calculate_dont_begin, calculate_dont_begin, colorize_one_web,
	try_recolor_web, insert_coalesced_conflicts, check_colors,
	break_precolored_alias): Likewise.
	* ra-debug.c: Include regs.h
	(ra_print_rtx_object): Likewise.
	* ra-rewrite (choose_spill_colors): Likewise.
	(spill_same_color_p, update_spill_colors, spill_is_free): Likewise.
	* ra.c (init_ra): Likewise.
	* recog.c (reg_fits_class_p, peep2_reg_dead_p,
	peep2_find_free_register): Likewise.
	* reg-stack.c (subst_stack_regs_pat, convert_regs_exit): Likewise.
	* regclass.c (hard_regno_nregs): New array.
	(init_reg_modes_once): Initialize it.
	(choose_hard_reg_mode): Use it.
	(record_reg_classes): Likewise.
	* regmove.c (mark_flags_life_zones): Likewise.
	* regrename.c (note_sets, clear_dead_regs, regrename_optimize,
	scan_rtx_reg, dump_def_use_chain, kill_value, set_value_regno,
	copy_value, maybe_mode_change, find_oldest_value_reg,
	copyprop_hardreg_forward_1):
	* regs.h (hard_regno_nregs): Declare.
	* realod.c (reload_inner_reg_of_subreg): Use it.
	(push_reload, combine_reloads, find_dummy_reload,
	hard_reg_set_here_p, operands_match_p, decompose, find_reloads,
	refers_to_regno_for_reload_p, find_equiv_reg, regno_clobbered_p,
	reload_adjust_reg_for_mode): Likewise.
	* reload1.c (compute_use_by_pseudos, count_pseudo,
	count_spilled_pseudo, find_reg, find_reload_regs, mark_home_live,
	spill_hard_reg, forget_old_reloads_1, mark_reload_reg_in_use,
	clear_reload_reg_in_use, reload_reg_free_for_value_p, free_for_value_p
	allocate_reload_reg, choose_reload_regs, emit_reload_insns,
	delete_output_reload): Likewise.
	* resource.c (update_live_status, mark_referenced_resources,
	mark_set_resources, mark_target_live_regs): Likewise.
	* rtlanal.c:  Include regs.h
	(refers_to_regno_p, reg_overlap_mentioned_p, dead_or_set_p,
	dead_or_set_regno_p, find_regno_note, find_reg_fusage,
	subreg_regno_offset, subreg_offset_representable_p,
	hoist_test_store): Likewise.
	* sched-deps.c (sched_analyze_1, sched_analyze_2): Likewise.
	* sched-rgn.c (check_live_1, update_live_1): Likewise.
	* stmt.c: Include regs.h
	(decl_conflicts_with_clobbers_p): Likewise.
	* varasm.c (make_decl_rtl): Likewise.
	* Makefile.in (cfgcleanup.o, rtlanal.o, ra-debug.o): Add regs.h dependnecy.

From-SVN: r77088
2004-02-02 00:17:18 +00:00
Kazu Hirata 9d05bbceb2 flow.c (EXIT_IGNORE_STACK): Move to ...
* flow.c (EXIT_IGNORE_STACK): Move to ...
	* defaults.h (EXIT_IGNORE_STACK): ... here.
	* dojump.c (clear_pending_stack_adjust): Don't use #ifdef
	EXIT_IGNORE_STACK.
	* function.c (expand_function_end): Likewise.
	* global.c (global_alloc): Likewise.
	* ra.c (init_ra): Likewise.
	* reload1.c (init_elim_table): Likewise.
	* reorg.c (fill_simple_delay_slots): Likewise.
	* resource.c (init_resource_info): Likewise.
	* doc/tm.texi (EXIT_IGNORE_STACK): Document that the default
	is 0.

From-SVN: r74654
2003-12-16 00:06:36 +00:00
Steven Bosscher a813c11120 basic-block.h (BLOCK_HEAD, BLOCK_END): Remove.
2003-12-11  Steven Bosscher  <steven@gcc.gnu.org>

	* basic-block.h (BLOCK_HEAD, BLOCK_END): Remove.
	(BLOCK_HEAD_TREE, BLOCK_END_TREE): Remove.
	(basic_block_def): Rename `head' to `head_' and `end' to `end_'.
	(BB_HEAD, BB_END): New accessor macros for the `head_' and `end_'
	fields of a basic block.
	* bb-reorder.c, bt-load.c, caller-save.c, cfg.c, cfganal.c,
	cfgbuild.c, cfgcleanup.c, cfglayout.c, cfgloop.c, cfgloopanal.c,
	cfgloopmanip.c, cfgrtl.c, combine.c, conflict.c, df.c, emit-rtl.c,
	final.c, flow.c, function.c, gcse.c, global.c, graph.c,
	haifa-sched.c, ifcvt.c, lcm.c, local-alloc.c, loop-unswitch.c,
	loop.c, postreload.c, predict.c, profile.c, ra-build.c, ra-debug.c,
	ra-rewrite.c, ra.c, recog.c, reg-stack.c, regclass.c, regmove.c,
	regrename.c, reload1.c, resource.c, sched-ebb.c, sched-rgn.c,
	sibcall.c, tracer.c, config/frv/frv.c, config/i386/i386.c,
	config/ia64/ia64.c: Use the BB_HEAD and BB_END macros instead of
	accessing the `head' and `end' fields of a basic block directly.

	* gengtype.c: Add missing piece from earlier patch.  Dunno what
	I was thinking...

From-SVN: r74520
2003-12-11 00:20:51 +00:00
Hans-Peter Nilsson 73fb6466a4 re PR target/13256 (strict_low_part mistreated in delay slots)
PR target/13256
	* resource.h (enum mark_resource_type): Remove member MARK_DEST.
	The only user changed as follows:
	* resource.c (mark_set_resources) <case SET>: Always recurse for
	SET_SRC (x).
	<case SIGN_EXTRACT, case ZERO_EXTRACT>: Always recurse on
	operands.
	<case STRICT_LOW_PART>: Delete, deferring to default code.

From-SVN: r74328
2003-12-05 11:53:56 +00:00
Kaveh R. Ghazi 703ad42b4b alias.c [...]: Remove unnecessary casts.
* alias.c alloc-pool.c bitmap.c bitmap.h bt-load.c builtins.c
	c-common.c c-decl.c c-incpath.c c-lex.c c-opts.c c-parse.in
	c-pragma.c c-typeck.c calls.c cfg.c cfganal.c cfgloop.c cfgrtl.c
	collect2.c combine.c conflict.c coverage.c cppexp.c cppfiles.c
	cpphash.c cppinit.c cpplex.c cpplib.c cppmacro.c cppspec.c
	cpptrad.c cse.c cselib.c dbxout.c defaults.h df.c dominance.c
	dwarf2out.c dwarfout.c emit-rtl.c except.c expmed.c expr.c final.c
	fix-header.c flow.c fold-const.c function.c gcc.c gccspec.c gcov.c
	gcse.c genattr.c genattrtab.c genautomata.c genconditions.c
	genemit.c genextract.c genoutput.c genrecog.c gensupport.c
	ggc-page.c ggc-simple.c global.c graph.c haifa-sched.c hashtable.c
	integrate.c jump.c langhooks.c lcm.c line-map.c local-alloc.c
	loop.c mips-tdump.c mips-tfile.c mkdeps.c optabs.c params.c
	postreload.c prefix.c print-tree.c protoize.c ra-build.c
	ra-colorize.c ra-rewrite.c ra.c recog.c reg-stack.c regclass.c
	regmove.c regrename.c reload.c reload1.c reorg.c resource.c
	sbitmap.c sched-deps.c sched-rgn.c sched-vis.c sdbout.c
	simplify-rtx.c ssa-ccp.c ssa.c stmt.c stor-layout.c timevar.c
	tlink.c toplev.c tree-dump.c tree.c unroll.c unwind-dw2-fde.c
	varasm.c varray.c vmsdbgout.c xcoffout.c: Remove unnecessary
	casts.

From-SVN: r69587
2003-07-19 14:47:15 +00:00
Andreas Jaeger 0c20a65f04 jump.c: Convert prototypes to ISO C90.
* jump.c: Convert prototypes to ISO C90.
	* langhooks-def.h: Likewise.  Add extern to prototypes.
	* langhooks.c: Likewise.
	* langhooks.h: Likewise.
	* lcm.c: Likewise.
	* local-alloc.c: Likewise.
	* loop-init.c: Likewise.
	* loop-unroll.c: Likewise.
	* loop-unswitch.c: Likewise.
	* loop.c: Likewise.
	* loop.h: Likewise. Add extern to prototypes.
	* machmode.h: Likewise.
	* main.c: Likewise.
	* mbchar.c: Likewise.
	* mbchar.h: Likewise.
	* mkdeps.c: Likewise.
	* mkdeps.h: Likewise.
	* optabs.c: Likewise.
	* optabs.h: Likewise.
	* output.h: Likewise.
	* gccspec.c: Likwise.
	* postreload.c: Likewise.
	* prefix.c: Likewise.
	* prefix.h: Likewise.
	* print-rtl.c: Likewise.
	* print-tree.c: Likewise.
	* profile.c: Likewise.
	* read-rtl.c: Likewise.
	* real.c: Likewise.
	* real.h: Likewise.
	* recog.c: Likewise.
	* recog.h: Likewise.
	* reg-stack.c: Likewise.
	* regclass.c: Likewise.
	* regmove.c: Likewise.
	* regrename.c: Likewise.
	* regs.h: Likewise.
	* reload.c: Likewise.
	* reload.h: Likewise.
	* reload1.c: Likewise.
	* reorg.c: Likewise.
	* resource.c: Likewise.
	* resource.h: Likewise.
	* rtl-error.c: Likewise.
	* rtl.c: Likewise.
	* rtl.h: Likewise.
	* rtlanal.c: Likewise.

From-SVN: r68998
2003-07-06 11:56:09 +02:00
Kazu Hirata 14b493d64d regmove.c: Fix comment typos.
* regmove.c: Fix comment typos.
	* reload.c: Likewise.
	* reload1.c: Likewise.
	* resource.c: Likewise.
	* rtl.def: Likewise.
	* rtl.h: Likewise.
	* rtlanal.c: Likewise.
	* sched-deps.c: Likewise.
	* sched-rgn.c: Likewise.
	* sibcall.c: Likewise.
	* simplify-rtx.c: Likewise.
	* ssa-ccp.c: Likewise.
	* ssa.c: Likewise.
	* stmt.c: Likewise.
	* stor-layout.c: Likewise.
	* system.h: Likewise.
	* tlink.c: Likewise.
	* toplev.c: Likewise.
	* tracer.c: Likewise.
	* tree-inline.c: Likewise.
	* tree.c: Likewise.
	* tree.h: Likewise.
	* unroll.c: Likewise.
	* varasm.c: Likewise.

From-SVN: r60473
2002-12-24 08:30:34 +00:00
Zack Weinberg 4977bab6ed Merge basic-improvements-branch to trunk
From-SVN: r60174
2002-12-16 18:23:00 +00:00
Kazu Hirata 40f0365880 c-common.h: Follow spelling conventions.
* c-common.h: Follow spelling conventions.
	* cpplex.c: Likewise.
	* cpplib.h: Likewise.
	* gthr-dce.h: Likewise.
	* gthr-posix.h: Likewise.
	* optabs.c: Likewise.
	* output.h: Likewise.
	* profile.c: Likewise.
	* protoize.c: Likewise.
	* ra-rewrite.c: Likewise.
	* real.c: Likewise.
	* recog.c: Likewise.
	* reg-stack.c: Likewise.
	* regclass.c: Likewise.
	* regmove.c: Likewise.
	* reload.c: Likewise.
	* reload.h: Likewise.
	* reload1.c: Likewise.
	* reorg.c: Likewise.
	* resource.c: Likewise.
	* rtl.h: Likewise.
	* rtlanal.c: Likewise.

From-SVN: r57555
2002-09-26 22:25:14 +00:00
Zdenek Dvorak d55bc08175 basic-block.h (last_basic_block): Defined as synonym for n_basic_blocks.
* basic-block.h (last_basic_block): Defined as synonym for
	n_basic_blocks.
	* cfganal.c (mark_dfs_back_edges, flow_reverse_top_sort_order_compute,
	flow_depth_first_order_compute, flow_preorder_transversal_compute,
	flow_dfs_compute_reverse_init): Replaced relevant occurences of
	n_basic_blocks with last_basic_block.
	* cfgbuild.c (make_edges): Likewise.
	* cfgloop.c (flow_loop_scan, flow_loops_find): Likewise.
	* cfgrtl.c (verify_flow_info, purge_all_dead_edges): Likewise.
	* combine.c (combine_instructions): Likewise.
	* df.c (df_alloc, df_analyse_1, df_analyse, iterative_dataflow_sbitmap,
	iterative_dataflow_bitmap): Likewise.
	* dominance.c (init_dom_info, calc_dfs_tree_nonrec, calc_dfs_tree,
	calc_idoms, idoms_to_doms): Likewise.
	* flow.c (update_life_info_in_dirty_blocks, free_basic_block_vars):
	Likewise.
	* gcse.c (gcse_main, alloc_gcse_mem, compute_local_properties,
	compute_hash_table, expr_reaches_here_p, one_classic_gcse_pass,
	one_cprop_pass, compute_pre_data, pre_expr_reaches_here_p,
	one_pre_gcse_pass, compute_transpout, delete_null_pointer_checks_1,
	delete_null_pointer_checks, compute_code_hoist_vbeinout,
	hoist_expr_reaches_here_p, hoist_code, one_code_hoisting_pass,
	compute_store_table, build_store_vectors): Likewise.
	* haifa-sched.c (sched_init): Likewise.
	* ifcvt.c (if_convert): Likewise.
	* lcm.c (compute_antinout_edge, compute_laterin, compute_insert_delete,
	pre_edge_lcm, compute_available, compute_nearerout,
	compute_rev_insert_delete, pre_edge_rev_lcm, optimize_mode_switching):
	Likewise.
	* predict.c (estimate_probability, process_note_prediction,
	note_prediction_to_br_prob): Likewise.
	* profile.c (GCOV_INDEX_TO_BB, BB_TO_GCOV_INDEX): Likewise.
	* recog.c (split_all_insns, peephole2_optimize): Likewise.
	* regrename.c (copyprop_hardreg_forward): Likewise.
	* resource.c (init_resource_info): Likewise.
	* sched-rgn.c (build_control_flow, find_rgns, compute_trg_info,
	init_regions, schedule_insns): Likewise.
	* ssa-ccp.c (ssa_const_prop): Likewise.
	* ssa-dce.c (ssa_eliminate_dead_code): Likewise.
	* ssa.c (compute_dominance_frontiers,
	compute_iterated_dominance_frontiers, convert_to_ssa): Likewise.

	* df.c (df_refs_unlink): Fix FOR_EACH_BB usage (in #if 0'ed code)
	* gcse.c (alloc_rd_mem, alloc_avail_expr_mem): Use n_blocks for vector
	sizes consistently.

From-SVN: r53924
2002-05-27 13:45:44 +00:00
Zdenek Dvorak e0082a7265 bb-reorder.c (make_reorder_chain, [...]): Use FOR_EACH_BB macros to iterate over basic block chain.
* bb-reorder.c (make_reorder_chain, make_reorder_chain_1):
	Use FOR_EACH_BB macros to iterate over basic block chain.
	* cfg.c (clear_edges, clear_bb_flags, dump_flow_info,
	alloc_aux_for_blocks, clear_aux_for_blocks, alloc_aux_for_edges):
	Likewise.
	* cfganal.c (set_edge_can_fallthru_flag, flow_call_edges_add,
	find_unreachable_blocks, create_edge_list, verify_edge_list,
	remove_fake_edges, add_noreturn_fake_exit_edges,
	flow_preorder_transversal_compute, flow_dfs_compute_reverse_execute):
	Likewise.
	* cfgbuild.c (make_edges, find_basic_blocks, find_many_sub_basic_blocks,
	find_sub_basic_blocks): Likewise.
	* cfgcleanup.c (try_optimize_cfg, delete_unreachable_blocks):
	Likewise.
	* cfglayout.c (record_effective_endpoints, cleanup_unconditional_jumps):
	Likewise.
	* cfgloop.c (flow_loops_cfg_dump, flow_loops_find):
	Likewise.
	* cfgrtl.c (compute_bb_for_insn, tidy_fallthru_edges,
	commit_edge_insertions, commit_edge_insertions_watch_calls,
	print_rtl_with_bb, verify_flow_info, purge_all_dead_edges): Likewise.
	* combine.c (combine_instructions, reg_dead_at_p): Likewise.
	* conflict.c (conflict_graph_compute): Likewise.
	* df.c (df_bitmaps_alloc, df_bitmaps_free, df_alloc, df_analyse_1,
	df_modified_p, df_refs_unlink, df_dump): Likewise.
	* dominance.c (calc_dfs_tree, calculate_dominance_info): Likewise.
	* final.c (compute_alignments): Likewise.
	* flow.c (update_life_info, update_life_info_in_dirty_blocks,
	delete_noop_moves, calculate_global_regs_live, allocate_bb_life_data,
	count_or_remove_death_notes): Likewise.
	* gcse.c (oprs_unchanged_p, record_last_reg_set_info,
	compute_hash_table, compute_kill_rd, compute_rd, compute_ae_kill,
	classic_gcse, compute_transp, cprop, compute_pre_data,
	compute_transpout, invalidate_nonnull_info,
	delete_null_pointer_checks_1, delete_null_pointer_checks,
	compute_code_hoist_vbeinout, hoist_code, compute_ld_motion_mems,
	compute_store_table, build_store_vectors, store_motion): Likewise.
	* global.c (global_conflicts, mark_elimination): Likewise.
	* graph.c (print_rtl_graph_with_bb): Likewise.
	* haifa-sched.c (sched_init): Likewise.
	* ifcvt.c (if_convert): Likewise.
	* lcm.c (compute_antinout_edge, compute_laterin, compute_insert_delete,
	compute_available, compute_nearerout, compute_rev_insert_delete,
	optimize_mode_switching): Likewise.
	* local-alloc.c (local_alloc, update_equiv_regs): Likewise.
	* predict.c (estimate_probability, note_prediction_to_br_prob,
	propagate_freq, counts_to_freqs, expensive_function_p,
	estimate_bb_frequencies): Likewise.
	* profile.c (instrument_edges, get_exec_counts,
	compute_branch_probabilities, compute_checksum, branch_prob,
	find_spanning_tree): Likewise.
	* recog.c (split_all_insns, peephole2_optimize): Likewise.
	* reg-stack.c (reg_to_stack, convert_regs_entry, convert_regs):
	Likewise.
	* regclass.c (scan_one_insn, regclass): Likewise.
	* regmove.c (mark_flags_life_zones, regmove_optimize,
	record_stack_memrefs): Likewise.
	* regrename.c (regrename_optimize, copyprop_hardreg_forward): Likewise.
	* reload1.c (reload, reload_combine, fixup_abnormal_edges): Likewise.
	* resource.c (find_basic_block): Likewise.
	* sched-ebb.c (schedule_ebbs): Likewise.
	* sched-rgn.c (is_cfg_nonregular, build_control_flow,
	find_single_block_region, find_rgns, schedule_insns)
	* sibcall.c (optimize_sibling_and_tail_recursive_call)
	* ssa-ccp.c (optimize_unexecutable_edges,
	ssa_ccp_df_delete_unreachable_insns): Likewise.
	* ssa-dce.c (ssa_eliminate_dead_code): Likewise.
	* ssa.c (find_evaluations, compute_dominance_frontiers_1,
	rename_block, convert_to_ssa, compute_conservative_reg_partition,
	compute_coalesced_reg_partition, rename_equivalent_regs,
	convert_from_ssa): Likewise.
	* config/ia64/ia64.c (emit_predicate_relation_info, process_epilogue,
	process_for_unwind_directive): Likewise.

	* df.c (FOR_ALL_BBS): Removed.
	* gcse.c (struct null_pointer_info): Type of current_block field
	changed.
	(struct reg_avail_info): Type of last_bb field changed.
	* config/ia64/ia64.c (block_num): Removed.
	(need_copy_state): Type changed.
	(last_block): New.

From-SVN: r53804
2002-05-23 19:23:51 +00:00
Zdenek Dvorak f6366fc7ad bb-reorder.c (make_reorder_chain_1): Modified.
* bb-reorder.c (make_reorder_chain_1): Modified.
	* cfganal.c (can_fallthru, flow_call_edges_add,
	flow_preorder_transversal_compute): Modified.
	* cfgbuild.c (make_edges, find_basic_blocks, find_many_sub_basic_blocks,
	find_sub_basic_blocks): Modified.
	* cfgcleanup.c (try_simplify_condjump, try_optimize_cfg): Modified.
	* cfglayout.c (skip_insns_after_block, fixup_reorder_chain,
	fixup_fallthru_exit_predecessor, cfg_layout_redirect_edge): Modified.
	* cfgrtl.c (tidy_fallthru_edges, verify_flow_info): Modified.
	* combine.c (this_basic_block): Type changed to basic_block.
	(combine_instructions, set_nonzero_bits_and_sign_copies, try_combine,
	nonzero_bits, num_sign_bit_copies, get_last_value_validate,
	get_last_value, distribute_notes, distribute_links): Modified.
	* final.c (compute_alignments): Modified.
	* flow.c (regno_uninitialized, regno_clobbered_at_setjmp): Modified.
	* function.c (thread_prologue_and_epilogue_insns): Modified.
	* gcse.c (compute_code_hoist_vbeinout): Modified.
	* global.c (build_insn_chain): Modified.
	* ifcvt.c (find_if_block, find_cond_trap): Modified.
	* predict.c (last_basic_block_p, note_prediction_to_br_prob): Modified.
	* regmove.c (regmove_optimize): Modified.
	* resource.c (find_basic_block): Modified.
	* sched-ebb.c (schedule_ebbs): Modified.
	* ssa-dce.c (find_control_dependence, find_pdom): Modified.

From-SVN: r53695
2002-05-21 20:37:43 +00:00
Richard Henderson 0b17ab2f5b Revert "Basic block renumbering removal", and two followup patches.
From-SVN: r53537
2002-05-16 19:31:56 -07:00
Zdenek Dvorak 355e4ec445 Basic block renumbering removal.
From-SVN: r53522
2002-05-16 10:34:53 -07:00
David S. Miller 7440af146e rtl.h (INSN_ANNULLED_BRANCH_P): Accept INSN too, update comment.
2002-05-10  David S. Miller  <davem@redhat.com>

	* rtl.h (INSN_ANNULLED_BRANCH_P): Accept INSN too, update comment.
	(struct rtx_def): Update unchanging flag comment.
	* doc/rtl.texi (INSN_ANNULLED_BRANCH_P): Update description.
	* reorg.c (delete_from_delay_list): INSN_ANNULLED_BRANCH_P needs
	to be handled to INSN too.
	(dbr_schedule): Likewise.
	* resource.c (next_insn_no_annul): Likewise.

From-SVN: r53370
2002-05-10 13:13:02 -07:00