aboutsummaryrefslogtreecommitdiff
path: root/gcc/regrename.c
AgeCommit message (Collapse)AuthorFilesLines
2002-01-08regrename.c (find_oldest_value_reg): Use gen_rtx_raw_REG.Richard Henderson1-2/+2
* regrename.c (find_oldest_value_reg): Use gen_rtx_raw_REG. (copyprop_hardreg_forward_1): Likewise. From-SVN: r48676
2002-01-08* regrename.c (copy_value): Ignore overlapping copies.Richard Henderson1-0/+8
From-SVN: r48669
2002-01-07regrename.c (find_oldest_value_reg): Ignore the value chain if the original ↵Richard Henderson1-1/+25
register was copied in a mode with a... * regrename.c (find_oldest_value_reg): Ignore the value chain if the original register was copied in a mode with a fewer number of hard registers than the desired mode. (copyprop_hardreg_forward_1): Likewise. (debug_value_data): Fix loop test. * toplev.c (parse_options_and_default_flags): Reenable -fcprop-registers at -O1. From-SVN: r48624
2001-12-31regrename.c (build_def_use): Don't rename asm operands that were originally ↵Richard Henderson1-14/+61
hard registers. * regrename.c (build_def_use): Don't rename asm operands that were originally hard registers. (copyprop_hardreg_forward_1): Likewise. (find_oldest_value_reg): Copy ORIGINAL_REGNO from source. * varasm.c (make_decl_rtl): Use gen_rtx_raw_REG. Set ORIGINAL_REGNO. * gcc.dg/asm-5.c: New. From-SVN: r48435
2001-12-17Implement MODE_BASE_REG_CLASSNick Clifton1-6/+10
From-SVN: r48104
2001-12-15regrename.c (copyprop_hardreg_forward): Do not keep register value data live ↵Ulrich Weigand1-0/+1
across abnormal call or eh egdes. * regrename.c (copyprop_hardreg_forward): Do not keep register value data live across abnormal call or eh egdes. From-SVN: r48043
2001-12-15builtins.c (expand_builtin_memcmp): Mark parameter with ATTRIBUTE_UNUSED.Kaveh R. Ghazi1-1/+1
* builtins.c (expand_builtin_memcmp): Mark parameter with ATTRIBUTE_UNUSED. * cfgcleanup.c (insns_match_p): Likewise. * regrename.c (mode_change_ok): Likewise. * gcc.c (execute): Const-ify. From-SVN: r48033
2001-12-14regrename.c (mode_change_ok): New.Richard Henderson1-2/+24
* regrename.c (mode_change_ok): New. (find_oldest_value_reg): Use it. From-SVN: r48029
2001-12-14regrename.c (struct value_data): Add max_value_regs.Richard Henderson1-4/+46
* regrename.c (struct value_data): Add max_value_regs. (init_value_data): Initialize it. (kill_value): Kill values that overlap the dying register. (set_value_regno): New. (kill_set_value, kill_autoinc_value, copy_value): Use it. (copyprop_hardreg_forward_1): Kill earlyclobber operands before looking at inputs. From-SVN: r48028
2001-12-13regrename.c (kill_value_regno): Simplify chain removal.Richard Henderson1-29/+24
* regrename.c (kill_value_regno): Simplify chain removal. (kill_value): Kill all of HARD_REGNO_NREGS. (kill_set_value): Use kill_value not kill_value_regno. (kill_autoinc_value): Likewise. (copyprop_hardreg_forward): Don't collect refresh_blocks. Call delete_noop_moves. From-SVN: r47992
2001-12-12regrename.c (copyprop_hardreg_forward): New optimization.Richard Henderson1-0/+740
* regrename.c (copyprop_hardreg_forward): New optimization. (kill_value_regno, kill_value, init_value_data, kill_clobbered_value, kill_set_value, kill_autoinc_value, copy_value, find_oldest_value_reg, replace_oldest_value_reg, replace_oldest_value_addr, replace_oldest_value_mem, copyprop_hardreg_forward_1, debug_value_data, validate_value_data): New. * rtl.h (copyprop_hardreg_forward): Declare. * toplev.c (flag_cprop_registers): New. (f_options): Add -fcprop-registers (rest_of_compilation): Invoke it. (parse_options_and_default_flags): Set it at -O1. * doc/invoke.texi: Document it. From-SVN: r47951
2001-09-29reload.c (find_reloads): Mark new USE insns with QImode.Alexandre Oliva1-0/+10
* reload.c (find_reloads): Mark new USE insns with QImode. (find_reloads_toplev, find_reloads_address, subst_reg_equivs, find_reloads_subreg_address): Likewise. * regrename.c (note_sets, clear_dead_regs): Abort if pseudos are encountered. * reload1.c (reload_combine_note_use): Likewise, inside USEs and CLOBBERs. (reload): Make sure there are no USEs with mode other than VOIDmode. At the end, remove those marked with QImode. From-SVN: r45889
2001-08-22Makefile.in, [...]: replace "GNU CC" with "GCC".Lars Brinkhoff1-10/+10
* Makefile.in, alias.c, basic-block.h, bb-reorder.c, bitmap.c, bitmap.h, builtin-types.def, builtins.c, builtins.def, c-aux-info.c, c-common.c, c-common.def, c-common.h, c-convert.c, c-decl.c, c-dump.c, c-dump.h, c-errors.c, c-format.c, c-lang.c, c-lex.c, c-lex.h, c-parse.in, c-pragma.c, c-pragma.h, c-semantics.c, c-tree.h, c-typeck.c, caller-save.c, calls.c, collect2.c, collect2.h, combine.c, conditions.h, config.gcc, configure.frag, configure.in, conflict.c, convert.c, convert.h, cppspec.c, crtstuff.c, cse.c, cselib.c, cselib.h, dbxout.c, dbxout.h, defaults.h, dependence.c, df.c, df.h, diagnostic.c, diagnostic.h, doloop.c, dominance.c, dwarf.h, dwarf2.h, dwarf2asm.c, dwarf2asm.h, dwarf2out.c, dwarf2out.h, dwarfout.c, emit-rtl.c, errors.c, errors.h, except.c, except.h, exgettext, explow.c, expmed.c, expr.c, expr.h, final.c, fixproto, flags.h, flow.c, fold-const.c, fp-test.c, function.c, function.h, gbl-ctors.h, gcc.c, gcc.h, gcc.hlp, gccspec.c, gcov-io.h, gcse.c, genattr.c, genattrtab.c, gencheck.c, gencodes.c, genconfig.c, genemit.c, genextract.c, genflags.c, gengenrtl.c, genmultilib, genopinit.c, genoutput.c, genpeep.c, genrecog.c, gensupport.c, gensupport.h, ggc-callbacks.c, ggc-common.c, ggc-none.c, ggc-page.c, ggc-simple.c, ggc.h, global.c, graph.c, graph.h, gthr-aix.h, gthr-dce.h, gthr-posix.h, gthr-rtems.h, gthr-single.h, gthr-solaris.h, gthr-vxworks.h, gthr-win32.h, gthr.h, haifa-sched.c, halfpic.c, halfpic.h, hard-reg-set.h, hwint.h, ifcvt.c, input.h, insn-addr.h, integrate.c, integrate.h, jump.c, lcm.c, libgcc2.c, libgcc2.h, lists.c, local-alloc.c, loop.c, loop.h, machmode.def, machmode.h, main.c, mbchar.c, mbchar.h, mips-tdump.c, mips-tfile.c, mklibgcc.in, mkmap-flat.awk, mkmap-symver.awk, optabs.c, output.h, params.c, params.def, params.h, predict.c, predict.def, predict.h, prefix.c, prefix.h, print-rtl.c, print-tree.c, profile.c, protoize.c, read-rtl.c, real.c, real.h, recog.c, recog.h, reg-stack.c, regclass.c, regmove.c, regrename.c, regs.h, reload.c, reload.h, reload1.c, reorg.c, resource.c, resource.h, rtl.c, rtl.def, rtl.h, rtlanal.c, sbitmap.c, sbitmap.h, sched-deps.c, sched-ebb.c, sched-int.h, sched-rgn.c, sched-vis.c, sdbout.c, sdbout.h, sibcall.c, simplify-rtx.c, ssa-ccp.c, ssa-dce.c, ssa.c, ssa.h, stmt.c, stor-layout.c, stringpool.c, system.h, timevar.c, timevar.def, timevar.h, tlink.c, toplev.c, toplev.h, tree.c, tree.def, tree.h, tsystem.h, unroll.c, unwind-dw2-fde.c, unwind-dw2-fde.h, unwind-dw2.c, unwind-pe.h, unwind-sjlj.c, unwind.h, unwind.inc, varasm.c, varray.c, varray.h, xcoffout.c, xcoffout.h: replace "GNU CC" with "GCC". From-SVN: r45105
2001-07-22regrename.c (regrename_optimize): Compute nregs for each potential target ↵Richard Henderson1-4/+4
register. * regrename.c (regrename_optimize): Compute nregs for each potential target register. From-SVN: r44234
2001-05-19regrename.c (regrename_optimize): frame pointer register can use a few hardregs.Denis Chertykov1-3/+8
* regrename.c (regrename_optimize): frame pointer register can use a few hardregs. From-SVN: r42305
2001-05-14regrename.c (regrename_optimize): Do not rename registers to leaf registers.Mark Mitchell1-0/+6
* regrename.c (regrename_optimize): Do not rename registers to leaf registers. From-SVN: r42066
2001-01-04Some tidyups for ia64 problemsBernd Schmidt1-2/+9
From-SVN: r38682
2000-12-29Introduce ORIGINAL_REGNO macroBernd Schmidt1-1/+3
From-SVN: r38546
2000-12-22Renamer improvements.Bernd Schmidt1-75/+164
From-SVN: r38463
2000-11-21regrename.c (scan_rtx_reg): Terminate the chain rather than abort on ↵Richard Henderson1-15/+25
mark_read with NO_REGS. * regrename.c (scan_rtx_reg): Terminate the chain rather than abort on mark_read with NO_REGS. From-SVN: r37644
2000-11-15regrename.c (scan_rtx_rtx): Skip to the next chain on encountering a ↵Graham Stott1-48/+61
terminated chain. * regrename.c (scan_rtx_rtx): Skip to the next chain on encountering a terminated chain. From-SVN: r37473
2000-11-10Fix REG_INC note handling in register renamer.Bernd Schmidt1-3/+8
From-SVN: r37364
2000-10-28regrename.c (scan_rtx_address): Frob action, not class, when trying to ↵Richard Henderson1-1/+3
disable optimization. * regrename.c (scan_rtx_address): Frob action, not class, when trying to disable optimization. From-SVN: r37117
2000-10-28regrename.c (regrename_optimize): Verify that all registers of a multiple ↵Richard Henderson1-20/+29
register mode are available. * regrename.c (regrename_optimize): Verify that all registers of a multiple register mode are available. (scan_rtx_address): Accept the mode of the address; all callers changed. From-SVN: r37109
2000-10-27regrename.c: Rewrite to handle multi-register modes and cond_exec instructions.Bernd Schmidt1-907/+644
* regrename.c: Rewrite to handle multi-register modes and cond_exec instructions. * Makefile.in (regrename.o): Update dependancies. * recog.h (struct operand_alternative): Add is_address. * recog.c (preprocess_constraints) [case 'p']: Set it. Co-Authored-By: Richard Henderson <rth@redhat.com> From-SVN: r37089
2000-10-20regrename.c (rr_replace_reg): Rewrite to use recog_data to perform ↵Richard Henderson1-112/+58
substitutions... * regrename.c (rr_replace_reg): Rewrite to use recog_data to perform substitutions, and apply_change_group to see if it worked. From-SVN: r36971
2000-08-04alias.c (mark_constant_function): Use INSN_P.Rodney Brown1-3/+3
* alias.c (mark_constant_function): Use INSN_P. (init_alias_analysis): Likewise. * combine.c (combine_instructions): Use INSN_P. (can_combine_p): Likewise. (try_combine): Likewise. (distribute_notes): Likewise. (distribute_links): Likewise. * cse.c (cse_around_loop): Use INSN_P. (invalidate_skipped_block): Likewise. (cse_set_around_loop): Likewise. (cse_end_of_basic_block): Likewise. (delete_trivially_dead_insns): Likewise. * emit-rtl.c (unshare_all_rtl_again): Use INSN_P. (unshare_all_rtl_1): Likewise. (next_cc0_user): Likewise. (try_split make_insn_raw): Likewise. (remove_unnecessary_notes): Likewise. * final.c (shorten_branches): Use INSN_P. (leaf_renumber_regs): Likewise. (leaf_renumber_regs_insn): Likewise. * flow.c (find_label_refs): Use INSN_P. (verify_wide_reg): Likewise. (notice_stack_pointer_modification): Likewise. (count_or_remove_death_notes): Likewise. (verify_flow_info): Likewise. (clear_log_links): Likewise. * function.c (fixup_var_refs_insns): Use INSN_P. (compute_insns_for_mem): Likewise. * gcse.c (alloc_gcse_mem): Use INSN_P. (compute_sets): Likewise. (compute_hash_table): Likewise. (classic_gcse): Likewise. (cprop): Likewise. (insert_insn_end_bb): Likewise. (delete_null_pointer_checks_1): Likewise. * global.c (expand_preferences): Use INSN_P. (build_insn_chain): Likewise. * graph.c (node_data): Use INSN_P. * haifa-sched.c (priority): Use INSN_P. (rm_line_notes): Likewise. (rm_other_notes): Likewise. (find_insn_reg_weight): Likewise. (init_target_units): Likewise. (schedule_block): Likewise. (compute_block_forward_dependences): Likewise. (debug_dependencies): Likewise. (set_priorities): Likewise. * integrate.c (function_cannot_inline_p): Use INSN_P. (save_parm_insns): Likewise. (copy_insn_list): Likewise. * jump.c (mark_all_labels): Use INSN_P. (never_reached_warning): Likewise. * lcm.c (optimize_mode_switching): Use INSN_P. * local-alloc.c (validate_equiv_mem): Use INSN_P. (memref_used_between_p): Likewise. (update_equiv_regs): Likewise. (block_alloc): Likewise. (no_conflict_p): Likewise. * loop.c (scan_loop): Use INSN_P. (find_and_verify_loops): Likewise. (count_loop_regs_set): Likewise. (loop_reg_used_before_p): Likewise. (strength_reduce): Likewise. (recombine_givs): Likewise. (check_dbra_loop): Likewise. (load_mems): Likewise. (try_copy_prop): Likewise. * print-rtl.c (print_rtx): Use INSN_P. * recog.c (find_single_use): Use INSN_P. * reg-stack.c (stack_regs_mentioned): Use INSN_P. (next_flags_user): Likewise. (swap_rtx_condition): Likewise. * regmove.c (mark_flags_life_zones): Use INSN_P. (optimize_reg_copy_1): Likewise. (optimize_reg_copy_2): Likewise. (optimize_reg_copy_3): Likewise. (reg_is_remote_constant_p): Likewise. (fixup_match_2): Likewise. (regmove_optimize): Likewise. (fixup_match_1): Likewise. * regrename.c (build_def_use): Use INSN_P. (replace_reg_in_block): Likewise. (consider_use): Likewise. * reload.c (find_equiv_reg): Use INSN_P. * reload1.c (reload): Use INSN_P. (maybe_fix_stack_asms): Likewise. (calculate_needs_all_insns): Likewise. (reload_as_needed): Likewise. (emit_output_reload_insns): Likewise. (delete_address_reloads_1): Likewise. (reload_cse_regs_1): Likewise. (reload_combine): Likewise. (reload_cse_move2add): Likewise. * reorg.c (redundant_insn): Use INSN_P. (dbr_schedule): Likewise. * resource.c (find_dead_or_set_registers): Use INSN_P. (mark_target_live_regs): Likewise. * rtlanal.c (reg_used_between_p): Use INSN_P. (reg_referenced_between_p): Likewise. (reg_set_between_p): Likewise. (reg_set_p): Likewise. (single_set): Likewise. (multiple_sets): Likewise. (find_last_value): Likewise. (reg_set_last): Likewise. (find_reg_note): Likewise. (find_regno_note): Likewise. * sibcall.c (sequence_uses_addressof): Use INSN_P. * simplify-rtx.c (cselib_process_insn): Use INSN_P. * ssa.c (find_evaluations): Use INSN_P. (rename_block): Likewise. (rename_equivalent_regs): Likewise. * unroll.c (loop_find_equiv_value): Use INSN_P. (set_dominates_use): Likewise. * varasm.c (mark_constant_pool): Use INSN_P. (mark_constants): Likewise. * config/alpha/alpha.c (alpha_does_function_need_gp): Use INSN_P. (alphaev4_next_group): Likewise. (alphaev5_next_group): Likewise. * config/c4x/c4x.c (c4x_process_after_reload): Use INSN_P. (c4x_rptb_rpts_p): Likewise. * config/mips/mips.c (mips16_optimize_gp): Use INSN_P. * config/rs6000/rs6000.c (uses_TOC): Use INSN_P. (rs6000_adjust_priority): Likewise. * config/sh/sh.c (sh_loop_align): Use INSN_P. (machine_dependent_reorg): Likewise. (split_branches): Likewise. * config/tahoe/tahoe.c (tahoe_cmp_check): Use INSN_P. From-SVN: r35494
2000-08-02c-common.h: Prototype min_precision and c_build_qualified_type here...Zack Weinberg1-20/+14
* c-common.h: Prototype min_precision and c_build_qualified_type here... * c-tree.h: ... not here. * errors.h: Prototype fancy_abort. * emit-rtl.c (gen_lowpart_common): Move variable 'c' into HOST_BITS_PER_WIDE_INT == 64 ifdef block. * regrename.c (regrename_optimize): Make control flow explicit. (replace_reg_in_block): Initialize reg_use to 0. * i386.c (legitimate_address_p): Rename error label to report_error to avoid namespace clash. cp: * cp-tree.h: Don't prototype min_precision here. (my_friendly_assert): Cast expression to void. * semantics.c (do_poplevel): Initialize scope_stmts. f: * expr.c (ffeexpr_finished_): Cast signed side of ?: expression to bool. java: * class.c (build_dtable_decl): Initialize dummy. intl: * dcgettext.c (find_msg): Initialize act before loop. (guess_category_value): Add dummy uses of both parameters. * localealias.c (read_alias_file): Cast arg of strchr to char *. From-SVN: r35427
2000-06-11Warning fixes:Kaveh R. Ghazi1-1/+1
* bb-reorder.c (build_scope_forest): Initialize variable `curr_scope'. * calls.c (expand_call): Likewise for variables `save_pending_stack_adjust' and `save_stack_pointer_delta'. * i386.c (function_arg_advance, function_arg): Cast to avoid signed/unsigned warnings. * i386.h (MEMORY_MOVE_COST): Likewise. * ifcvt.c (cond_exec_process_if_block): Initialize variables `else_start' and `else_end'. * libgcc2.h (__eh_alloc, __eh_free): Prototype. * regrename.c (rr_replace_reg): Initialize variable `dest_subregno'. ch: * Makefile.in (EXPR_H): New dependency variable. (actions.o, expr.o): Use EXPR_H. (lang.o): Depend on RTL_H and EXPR_H. * lang.c: Include rtl.h and expr.h. (lang_get_alias_set): Mark parameter with ATTRIBUTE_UNUSED. cp: * decl2.c (compare_options): Don't needlessly cast away const-ness. f: * com.c (lang_get_alias_set): Mark parameter with ATTRIBUTE_UNUSED. java: * decl.c (create_primitive_vtable): Prototype. * jcf-write.c (generate_bytecode_insns): Initialize variable `saved_context'. * lang.c (lang_get_alias_set): Mark parameter with ATTRIBUTE_UNUSED. From-SVN: r34490
2000-05-19cse.c (cse_basic_block): Only call find_reg_note if REG_NOTES not 0.Richard Kenner1-1/+1
* cse.c (cse_basic_block): Only call find_reg_note if REG_NOTES not 0. * reload.c (find_equiv_reg): Likewise. * alias.c (init_alias_analysis): Likewise. Only call prologue_epilogue_contains on insns. * basic-block.h (REG_SET_TO_HARD_REG_SET): Call new function. * bb-reorder.c (hard-reg-set.h): Include earlier. * haifa-sched.c (hard-reg-set.h): Likewise. * ifcvt.c (hard-reg-set.h): Likewise. * local-alloc.c (hard-reg-set.h): Likewise. * loop.c (hard-reg-set.h): Likewise. * predict.c (hard-reg-set.h): Likewise. * regrename.c (hard-reg-set.h): Likewise. * flow.c (hard-reg-set.h): Likewise. (reg_set_to_hard_reg_set): New function. * bitmap.c (regs.h, basic-block.h): No longer include. (bitmap.h): Now include. * conflict.c (hard-reg-set.h): Include. * profile.c (hard-reg-set.h): Likewise. * print-rtl.c (hard-reg-set.h): Likewise. * sbitmap.c (hard-reg-set.h): Likewise. * toplev.c (hard-reg-set.h): Likewise. * unroll.c (hard-reg-set.h, basic-block.h): Likewise. * hard-reg-set.h (reg_names): Now constant. * regs.h (reg_names): Likewise. * regclass.c (reg_names): Likewise. * loop.h (basic-block.h): No longer include. (bitmap.h): Now include. * reload1.c (order_regs_for_reload): Avoid loop over reg sets. * Makefile.in (LOOP_H, sbitmap.o, profile.o): Reflect above changes. (toplev.o, print-rtl.o, conflict.o, unroll.o, bitmap.o): Likewise. From-SVN: r34039
2000-05-11regrename.c (replace_reg_in_block): Improve REG_DEAD handling.Stan Cox1-15/+64
* regrename.c (replace_reg_in_block): Improve REG_DEAD handling. * timevar.def (TV_RENAME_REGISTERS): Move before TV_SCHED2. * toplev.c (rest_of_compilation): Call regrename_optimize before sched2. From-SVN: r33845
2000-04-10regrename.c: Minor cleanups, including changing some variables to unsigned int.Richard Kenner1-226/+249
* regrename.c: Minor cleanups, including changing some variables to unsigned int. From-SVN: r33053
2000-04-06* regrename.c (regrename_optimize): Handle no REG_ALLOC_ORDER.Clinton Popetz1-0/+4
From-SVN: r32969
2000-04-05regrename.c (regno_first_use_in): Wrap prototype in PARAMS.Kaveh R. Ghazi1-55/+55
* regrename.c (regno_first_use_in): Wrap prototype in PARAMS. (regrename_optimize): Rename variables `def_uses' and `ext_basic_blocks' to avoid conflicts with similarly named typedefs in traditional C. From-SVN: r32921
2000-04-04regrename.c (consider_available): Test fixed_regs not PIC_OFFSET_TABLE_REGNUM.Richard Henderson1-3/+4
* regrename.c (consider_available): Test fixed_regs not PIC_OFFSET_TABLE_REGNUM. From-SVN: r32919
2000-04-05Makefile.in: Add rules for regrename.oStan Cox1-0/+1050
* Makefile.in: Add rules for regrename.o * regrename.c: New file. * rtl.h (regrename_optimize): Add prototype. * toplev.c (rename_registers_dump, flag_rename_registers): New variables (compile_file, decode_d_option): Add support for -frename-registers. (rest_of_compilation): Call regrename_optimize. * config/ia64/ia64.h (HARD_REGNO_RENAME_OK, RENAME_EXTENDED_BLOCKS): New macros. From-SVN: r32916