aboutsummaryrefslogtreecommitdiff
path: root/gcc/combine.c
AgeCommit message (Collapse)AuthorFilesLines
2005-09-26Check for valid use of subreg.Fariborz Jahanian1-1/+1
Oked by Richard Henderson. From-SVN: r104649
2005-08-26combine.c (make_extraction): Avoid reference outside object.Ian Lance Taylor1-3/+5
2005-08-26 Ian Lance Taylor <ian@airs.com> * combine.c (make_extraction): Avoid reference outside object. From-SVN: r103537
2005-08-08re PR rtl-optimization/23241 (Invalid code generated for comparison of uchar ↵Josh Conner1-1/+1
to 255) PR rtl-optimization/23241 * combine.c (simplify_comparison): Fix error in determining whether to lift a subreg from comparison. From-SVN: r102869
2005-08-03combine.c (can_change_dest_mode): New function.Paul Brook1-24/+38
2005-08-03 Paul Brook <paul@codesourcery.com> * combine.c (can_change_dest_mode): New function. (try_combine, simplify_set): Use it. From-SVN: r102686
2005-08-02combine.c (combine_instructions): Don't use reg_equal/equiv results if the ↵Richard Henderson1-3/+6
mode doesn't match. * combine.c (combine_instructions): Don't use reg_equal/equiv results if the mode doesn't match. From-SVN: r102679
2005-07-22re PR rtl-optimization/22258 (combine causes spill failure on return value ↵J"orn Rennecke1-0/+80
register) PR rtl-optimization/22258 * combine.c (likely_spilled_retval_1, likely_spilled_retval_p): New functions. (try_combine): Use likely_spilled_retval_p. From-SVN: r102279
2005-07-19bt-load.c (link_btr_uses): Fix uninitialised warnings.Ben Elliston1-1/+1
* bt-load.c (link_btr_uses): Fix uninitialised warnings. * cfganal.c (find_edge_index): Ditto. * combine.c (combine_instructions): Ditto. * ddg.c (create_scc): Ditto. (find_successors): Ditto. (find_predecessors): Ditto. (find_nodes_on_paths): Ditto. (longest_simple_path): Ditto. * flow.c (update_life_info): Ditto. (count_or_remove_death_notes): Ditto. (clear_log_links): Ditto. * modulo-sched.c (generate_reg_moves): Ditto. (find_max_asap): Ditto. (find_max_hv_min_mob): Ditto. (find_max_dv_min_mob): Ditto. * sbitmap.c (sbitmap_first_set_bit): Ditto. * sched-rgn.c (extract_edgelst): Ditto. * tree-into-ssa.c (prepare_names_to_update): Ditto. (dump_update_ssa): Ditto. (ssa_names_to_replace) Ditto. (switch_virtuals_to_full_rewrite): Ditto. (update_ssa): Ditto. * tree-vect-transform.c (vect_create_epilog_for_reduction): Ditto. From-SVN: r102151
2005-07-05Makefile.in: Adjust dependencies.Paolo Bonzini1-0/+49
2005-07-05 Paolo Bonzini <bonzini@gnu.org> * Makefile.in: Adjust dependencies. * tree-pass.h: Add new passes and passes formerly in tree-optimize.c. * basic-block.h (duplicate_computed_gotos): Remove, it is now static. * alias.c (rest_of_handle_cfg, pass_cfg): New. * bb-reorder.c (duplicate_computed_gotos): Make it static. * cfgexpand.c (tree_expand_cfg): Add code formerly at the beginning of rest_of_compilation. * bb-reorder.c (gate_duplicate_computed_gotos, pass_duplicate_computed_gotos, gate_handle_reorder_blocks, rest_of_handle_reorder_blocks, pass_reorder_blocks, gate_handle_partition_blocks, rest_of_handle_partition_blocks, pass_partition_blocks): New. * bt-load.c (gate_handle_branch_target_load_optimize, rest_of_handle_branch_target_load_optimize, pass_branch_target_load_optimize): New. * cfgcleanup.c (rest_of_handle_jump, pass_jump, rest_of_handle_jump2, pass_jump2): New. * cfglayout.c (pass_insn_locators_initialize): New. * cfgrtl.c (pass_free_cfg): New. * combine.c (gate_handle_combine, rest_of_handle_combine, pass_combine): New. * cse.c (gate_handle_cse, rest_of_handle_cse, pass_cse, gate_handle_cse2, rest_of_handle_cse2, pass_cse2): New. * emit-rtl.c (pass_unshare_all_rtl, pass_remove_unnecessary_notes): New. * except.c (pass_set_nothrow_function_flags, pass_convert_to_eh_region_ranges, gate_handle_eh, rest_of_handle_eh, pass_rtl_eh): New. * final.c (pass_compute_alignments, rest_of_handle_final, pass_final, rest_of_handle_shorten_branches, pass_shorten_branches, rest_of_clean_state, pass_clean_state): New. * flow.c (pass_recompute_reg_usage, gate_remove_death_notes, rest_of_handle_remove_death_notes, pass_remove_death_notes, rest_of_handle_life, pass_life, rest_of_handle_flow2, pass_flow2): New. * function.c (pass_instantiate_virtual_regs, pass_init_function, rest_of_handle_check_leaf_regs, pass_leaf_regs): New. * gcse.c (gate_handle_jump_bypass, rest_of_handle_jump_bypass, pass_jump_bypass, gate_handle_gcse, rest_of_handle_gcse, pass_gcse): New. * global.c (rest_of_handle_global_alloc, pass_global_alloc): New. * ifcvt.c (gate_handle_if_conversion, rest_of_handle_if_conversion, pass_rtl_ifcvt, gate_handle_if_after_combine, rest_of_handle_if_after_combine, pass_if_after_combine, gate_handle_if_after_reload, rest_of_handle_if_after_reload, pass_if_after_reload): New. * integrate.c (pass_initial_value_sets): New. * jump.c (pass_cleanup_barriers, purge_line_number_notes, pass_purge_lineno_notes): New. * mode-switching.c (rest_of_handle_mode_switching, pass_mode_switching): New. * local-alloc.c (rest_of_handle_local_alloc, pass_local_alloc): New. * loop-init.c (gate_handle_loop2, rest_of_handle_loop2, pass_loop2): New. * loop.c (gate_handle_loop_optimize, rest_of_handle_loop_optimize, pass_loop_optimize): New. * modulo-sched.c (gate_handle_sms, rest_of_handle_sms, pass_sms): New. * postreload-gcse.c (gate_handle_gcse2, rest_of_handle_gcse2, pass_gcse2): New. * postreload.c (gate_handle_postreload, rest_of_handle_postreload, pass_postreload_cse): New. * profile.c (gate_handle_profiling, pass_profiling, rest_of_handle_branch_prob, pass_branch_prob): New. * recog.c (pass pass_split_for_shorten_branches, gate_do_final_split, pass_split_before_regstack, gate_handle_split_before_regstack, gate_handle_peephole2, rest_of_handle_peephole2, pass_peephole2, rest_of_handle_split_all_insns, pass_split_all_insns): New. * reg-stack.c (gate_handle_stack_regs, rest_of_handle_stack_regs, pass_stack_regs): New. * regmove.c (gate_handle_regmove, rest_of_handle_regmove, pass_regmove, gate_handle_stack_adjustments, rest_of_handle_stack_adjustments, pass_stack_adjustments): New. * regrename.c (gate_handle_regrename, rest_of_handle_regrename, pass_regrename): New. * reorg.c (gate_handle_delay_slots, rest_of_handle_delay_slots, pass_delay_slots, gate_handle_machine_reorg, rest_of_handle_machine_reorg, pass_machine_reorg): New. * rtl.h (extern void purge_line_number_notes): New. * sched-rgn.c (gate_handle_sched, rest_of_handle_sched, gate_handle_sched2, rest_of_handle_sched2, pass_sched, pass_sched2): New. * tracer.c (gate_handle_tracer, rest_of_handle_tracer, pass_tracer): New. * value-prof.c (gate_handle_value_profile_transformations, rest_of_handle_value_profile_transformations, pass_value_profile_transformations): New. * var-tracking.c (gate_handle_var_tracking, pass_variable_tracking): New. * web.c (gate_handle_web, rest_of_handle_web, pass_web): New. * passes.c (open_dump_file, close_dump_file, rest_of_handle_final, rest_of_handle_delay_slots, rest_of_handle_stack_regs, rest_of_handle_variable_tracking, rest_of_handle_machine_reorg, rest_of_handle_old_regalloc, rest_of_handle_regrename, rest_of_handle_reorder_blocks, rest_of_handle_partition_blocks, rest_of_handle_sms, rest_of_handle_sched, rest_of_handle_sched2, rest_of_handle_gcse2, rest_of_handle_regmove, rest_of_handle_tracer, rest_of_handle_if_conversion, rest_of_handle_if_after_combine, rest_of_handle_if_after_reload, rest_of_handle_web, rest_of_handle_branch_prob, rest_of_handle_value_profile_transformations, rest_of_handle_cfg, rest_of_handle_jump_bypass, rest_of_handle_combine, rest_of_handle_life, rest_of_handle_cse, rest_of_handle_cse2, rest_of_handle_gcse, rest_of_handle_loop_optimize, rest_of_handle_loop2, rest_of_handle_branch_target_load_optimize, rest_of_handle_mode_switching, rest_of_handle_jump, rest_of_handle_eh, rest_of_handle_stack_adjustments, rest_of_handle_flow2, rest_of_handle_jump2, rest_of_handle_peephole2, rest_of_handle_postreload, rest_of_handle_shorten_branches, rest_of_clean_state, rest_of_compilation): Remove. * cgraphunit.c (ipa_passes): Moved from tree-optimize.c. * passes.c (dump_flags, in_gimple_form, all_passes, all_ipa_passes, all_lowering_passes, register_one_dump_file, register_dump_files, next_pass_1, last_verified, execute_todo, execute_one_pass, execute_pass_list, execute_ipa_pass_list): Moved from tree-optimize.c. (init_optimization_passes): Moved from tree-optimize.c, adding the RTL optimizations. * tree-dump.h (dump_info_p, dump_flag): Moved from tree.h. * tree-optimize.c (dump_flags, in_gimple_form, all_passes, all_ipa_passes, all_lowering_passes, register_one_dump_file, register_dump_files, next_pass_1, last_verified, execute_todo, execute_one_pass, execute_pass_list, execute_ipa_pass_list, init_tree_optimization_passes, ipa_passes): Delete. * tree-pass.h (enum tree_dump_index): Moved from tree.h, removing the RTL dumps. (TDF_*, get_dump_file_name, dump_enabled_p, dump_initialized_p, dump_begin, dump_end, dump_node, dump_switch_p, dump_flag_name): Moved from tree.h. (ipa_passes): Remove. (all_passes, all_ipa_passes, all_lowering_passes): Now extern. * tree.h (enum tree_dump_index, TDF_*, get_dump_file_name, dump_enabled_p, dump_initialized_p, dump_begin, dump_end, dump_node, dump_switch_p, dump_flag_name): Moved to tree-pass.h. (dump_info_p, dump_flag): Moved to tree-dump.h. * Makefile.in: Adjust dependencies for tree-pretty-print.c, cgraph.c, opts.c. * passes.c (finish_optimization_passes): Use dump_begin and dump_end, TDI_end. (gate_rest_of_compilation): New. (pass_rest_of_compilation): Use it. (gate_postreload, pass_postreload): New. * toplev.c (general_init): Rename init_tree_optimization_passes. * toplev.h (init_tree_optimization_passes): Rename to init_optimizations_passes. * tree-dump.c (dump_flag): Make static. (dump_files): Remove RTL dumps. * tree-optimize.c (pass_all_optimizations, pass_early_local_passes, pass_cleanup_cfg, pass_free_cfg_annotations, pass_cleanup_cfg_post_optimizing, pass_free_datastructures, pass_init_datastructures, pass_fixup_cfg): Make non-static. * tree-pretty-print.c: Include tree-pass.h. * cgraph.c: Include tree-dump.h. cp: 2005-07-05 Paolo Bonzini <bonzini@gnu.org> * Makefile.in (class.o, decl2.o): Adjust dependencies. * class.c: Include tree-dump.h. * decl2.c: Include tree-dump.h. java: 2005-07-05 Paolo Bonzini <bonzini@gnu.org> * Makefile.in (parse.o): Adjust dependencies. * parse.y: Include tree-dump.h. From-SVN: r101627
2005-07-03bb-reorder.c, [...]: Avoid "." or "\n" at end of diagnostics and capital ↵Joseph Myers1-2/+2
letters at start of diagnostics. * bb-reorder.c, c-pch.c, c-pragma.c, c.opt, cfghooks.c, cfgloop.c, cfgrtl.c, cgraphunit.c, config/c4x/c4x.c, config/cris/cris.c, config/frv/frv.c, config/host-darwin.c, config/iq2000/iq2000.c, config/lynx.h, config/m68k/m68k.c, config/pa/pa.c, config/sh/sh.h, config/stormy16/stormy16.c, config/v850/v850.c, config/vax/netbsd-elf.h, coverage.c, dwarf2out.c, emit-rtl.c, except.c, gcc.c, tree-cfg.c, tree-eh.c, tree-ssa.c, xcoffout.c: Avoid "." or "\n" at end of diagnostics and capital letters at start of diagnostics. * combine.c, cse.c: Don't translate dump file output. * toplev.c (print_version): Only translate output if going to stderr. From-SVN: r101561
2005-06-25Update FSF address.Kelley Cook1-2/+2
From-SVN: r101317
2005-06-20re PR target/22077 (vec_all_eq does not produce good result)Fariborz Jahanian1-0/+5
PR 22077. Oked by Roger Sayle. From-SVN: r101211
2005-06-19combine.c (make_compound_operation): Use simplify_subreg.Andreas Krebbel1-31/+23
2005-06-19 Andreas Krebbel <krebbel1@de.ibm.com> * combine.c (make_compound_operation): Use simplify_subreg. Delete a optimization already done by simplify_subreg. From-SVN: r101183
2005-06-16basic-block.h (rtl_bb_info): Break out head_, end_, global_live_at_start, ↵Jan Hubicka1-9/+14
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-07sbitmap.h (sbitmap_iterator, [...]): New.Kazu Hirata1-2/+4
* sbitmap.h (sbitmap_iterator, sbitmap_iter_init, sbitmap_iter_cond, sbitmap_iter_next): New. * bt-load.c, cfganal.c, combine.c, ddg.c, flow.c, modulo-sched.c, sbitmap.c, sched-rgn.c, tree-into-ssa.c, tree-outof-ssa.c, tree-ssa-alias.c, tree-ssa-live.c: Update uses of EXECUTE_IF_SET_IN_SBITMAP to the new style. From-SVN: r100709
2005-06-06combine.c (try_combine): Use hard_regno_nregs array instead of ↵Jakub Jelinek1-2/+2
HARD_REGNO_NREGS macro. * combine.c (try_combine): Use hard_regno_nregs array instead of HARD_REGNO_NREGS macro. * config/rs6000/rs6000.c (rs6000_split_multireg_move, rs6000_register_move_cost, rs6000_memory_move_cost): Likewise. * config/ia64/ia64.c (mark_reg_gr_used_mask): Likewise. From-SVN: r100673
2005-05-04re PR rtl-optimization/21239 (Illegal elimination of SSE2 load/store using ↵Jakub Jelinek1-1/+1
xmm intrinsics) * config/i386/i386.c (ix86_expand_vector_set): Fix setting 3rd and 4th item in V4SF mode. PR rtl-optimization/21239 * combine.c (combine_simplify_rtx) <case VEC_SELECT>: Fix a typo. * gcc.dg/i386-sse-11.c: New test. From-SVN: r99186
2005-04-22builtins.c (gimplify_va_arg_expr): Reword comments to avoid 'abort'.Nathan Sidwell1-3/+2
* builtins.c (gimplify_va_arg_expr): Reword comments to avoid 'abort'. Use gcc_assert and gcc_unreachable as appropriate. * c-format.c (get_constant, decode_format_attr, get_flag_spec, find_char_info_specifier_index, find_length_info_modifier_index): Likewise. * c-typeck.c (composite_type, pop_init_level): Likewise. * combine.c (cant_combine_insn_p, try_combine): Likewise. * cse.c (cse_insn): Likewise * dominance.c (calc_dfs_tree): Likewise dwarf2out.c (loc_descriptor_from_tree_1, add_abstract_origin_attribute, force_decl_die, force_type_die): Likewise emit-rtl.c (operand_subword_force): Likewise explow.c (hard_function_value): Likewise expmed.c (store_bit_field, expand_divmod, emit_store_flag_force): Likewise expr.c (emit_move_multi_word, store_expr, expand_expr_real_1): Likewise final.c (this_is_asm_operands, shorten_branches, final_scan_insn, output_operand): Likewise flow.c (recompute_reg_usage): Likewise * function.c (assign_stack_temp_for_type, assign_temp, handle_epilogue_set): Likewise * genextract.c (main): Likewise * gimplify.c (mostly_copy_tree_r, gimplify_return_expr, gimplify_modify_expr_rhs, gimplify_expr): Likewise * haifa-sched.c (ready_lastpos, ready_remove_first, ready_element, ready_remove, rm_line_notes, rm_other_notes, schedule_block): Likewise mips-tfile.c (copy_object, out_of_bounds): Likewise From-SVN: r98567
2005-04-15cfgrtl.c (purge_all_dead_edge): Remove an unused argument.Kazu Hirata1-1/+1
* cfgrtl.c (purge_all_dead_edge): Remove an unused argument. * basic-block.h: Update the prototype for purge_all_dead_edges. * cfgexpand.c (tree_expand_cfg): Update a call to purge_all_dead_edges. * combine.c (combine_instructions): Likewise. * passes.c (rest_of_handle_old_regalloc, rest_of_handle_cse, rest_of_handle_cse2, rest_of_handle_gcse, rest_of_handle_postreload): likewise. From-SVN: r98168
2005-04-10combine.c (combine_simplify_rtx): Remove a transformation that relies on an ↵Richard Sandiford1-41/+0
invalid assumption about rtl... * combine.c (combine_simplify_rtx): Remove a transformation that relies on an invalid assumption about rtl sign-extension semantics. From-SVN: r97941
2005-04-05combine.c (RTL_HOOKS_GEN_LOWPART_NO_EMIT): Use gen_lowpart_for_combine.Paolo Bonzini1-0/+4
2004-04-05 Paolo Bonzini <bonzini@gnu.org> * combine.c (RTL_HOOKS_GEN_LOWPART_NO_EMIT): Use gen_lowpart_for_combine. * cse.c (gen_lowpart_if_possible): Move... * rtlhooks.c (gen_lowpart_if_possible): ... here. Also try gen_lowpart_SUBREG. (gen_lowpart_no_emit_general): Use it. From-SVN: r97633
2005-03-22re PR rtl-optimization/20527 (Mishandling of postincrement causes bzip2 ↵Hans-Peter Nilsson1-3/+7
miscompilation.) PR rtl-optimization/20527 * combine.c (can_combine_p) [AUTO_INC_DEC]: When INSN has an REG_INC note, test that the register also isn't mentioned in PRED or SUCC. From-SVN: r96853
2005-03-21combine.c (combine_simplify_rtx, [...]): Adjust calls to reverse_comparison.Paolo Bonzini1-58/+14
2005-03-21 Paolo Bonzini <bonzini@gnu.org> * combine.c (combine_simplify_rtx, simplify_if_then_else, simplify_logical, if_then_else_cond, known_cond, simplify_comparison): Adjust calls to reverse_comparison. Don't use combine_reversed_comparison_code). (combine_reversed_comparison_code): Remove. (reversed_comparison): Using reversed_comparison_code, move it... * jump.c (reversed_comparison): ... here. * rtl.h (reversed_comparison): Add prototype. From-SVN: r96801
2005-03-19combine.c (try_combine): When changing the mode of a hard reg, make sure ↵Bernd Schmidt1-3/+9
that doing so is valid. * combine.c (try_combine): When changing the mode of a hard reg, make sure that doing so is valid. From-SVN: r96730
2005-03-18combine.c (gen_binary): Remove.Paolo Bonzini1-289/+304
2005-03-01 Paolo Bonzini <bonzini@gnu.org> * combine.c (gen_binary): Remove. (known_cond, simplify_shift_const, find_split_point, combine_simplify_rtx, simplify_if_then_else, simplify_set, simplify_logical, expand_field_assignment, extract_left_shift, force_to_mode, if_then_else_cond, apply_distributive_law, simplify_and_const_int, simplify_shift_const, gen_lowpart_for_combine, simplify_comparison, reversed_comparison): Replace with simplify_gen_binary, simplify_gen_relational or distribute_and_simplify_rtx. (distribute_and_simplify_rtx): New function. From-SVN: r96681
2005-03-15re PR rtl-optimization/20291 (combine throws away clobbers before trying to ↵J"orn Rennecke1-0/+20
split) PR rtl-optimization/20291 * combine.c (try_combine): If splitting fails, re-try with original combined pattern, i.e. before clobber stripping. From-SVN: r96476
2005-03-10re PR target/20322 (Miscompilation of libcpp/expr.c at -O2+)Jakub Jelinek1-0/+14
PR target/20322 * combine.c (try_combine): If recog_for_combine added CLOBBERs to NEWI2PAT, fail to combine if they are used by NEWPAT. * gcc.dg/20050307-1.c: New test. From-SVN: r96260
2005-03-08c-common.c, [...]: Fix comment formatting.Kazu Hirata1-1/+2
* c-common.c, c-opts.c, combine.c, cse.c, dojump.c, gimplify.c, tree-dfa.c, tree-ssa-loop-ivopts.c, tree-ssa-phiopt.c, tree-ssa-pre.c, tree-ssa-sink.c, tree-vect-analyze.c, tree.def, tree.h: Fix comment formatting. From-SVN: r96104
2005-03-05combine.c (simplify_and_const_int): Use gen_int_mode instead of GEN_INT ↵Kazu Hirata1-1/+1
(trunc_int_for_mode (...)). * combine.c (simplify_and_const_int): Use gen_int_mode instead of GEN_INT (trunc_int_for_mode (...)). * loop-iv.c (iv_number_of_iterations): Likewise. * postreload.c (reload_cse_move2add): Likewise. * simplify-rtx.c (simplify_const_unary_operation, simplify_const_binary_operation): Likewise. * stor-layout.c (get_mode_bounds): Likewise. From-SVN: r95935
2005-02-28calls.c (emit_call_1): Don't use REG_ALWAYS_RETURN.Kazu Hirata1-1/+0
* calls.c (emit_call_1): Don't use REG_ALWAYS_RETURN. (emit_library_call_value_1): Don't use LCT_ALWAYS_RETURN and REG_ALWAYS_RETURN. * cfgrtl.c (need_fake_edge_p): Likewise. * combine.c (distribute_notes): Likewise. * emit-rtl.c (try_split): Likewise. * recog.c (peephole2_opimize): Likewise. * reg-notes.def (ALWAYS_RETURN): Remove. * rtl.h (LCT_ALWAYS_RETURN): Remove. * tree-cfg.c (need_fake_edge_p): Don't use ECF_ALWAYS_RETURN. * tree.h (ECF_ALWAYS_RETURN): Remove. From-SVN: r95690
2005-02-12c-tree.h, [...]: Fix comment typos.Kazu Hirata1-1/+1
* c-tree.h, combine.c, expmed.c, flow.c, libgcc2.c, simplify-rtx.c, tree-ssa-live.h: Fix comment typos. Follow spelling conventions. From-SVN: r94939
2005-02-03combine.c (simplify_comparison, [...]): Do not drop the extend if we'd have ↵Alexandre Oliva1-14/+23
to add a paradoxical subreg later. gcc/ChangeLog: * combine.c (simplify_comparison, case SIGN_EXTEND, ZERO_EXTEND): Do not drop the extend if we'd have to add a paradoxical subreg later. Include optabs.h and insn-codes.h. * Makefile.in (combine.o): Depend on $(OPTABS_H). gcc/testsuite/ChangeLog: * gcc.c-torture/execute/20050203-1.c: New. From-SVN: r94655
2005-01-29combine.c (make_field_assignment): Fix argument order to gen_int_mode.Richard Henderson1-1/+1
* combine.c (make_field_assignment): Fix argument order to gen_int_mode. From-SVN: r94420
2005-01-26re PR middle-end/18008 (Duplicate mask on bitfield insertion)Richard Henderson1-11/+42
PR middle-end/18008 * combine.c (make_field_assignment): Simplify store to zero_extract from a source with an overlapping mask. From-SVN: r94282
2005-01-23combine.c (simplify_logical): Only simplify logical expressions of the form ↵Roger Sayle1-6/+8
ior(and(x,y),z) by the inverse... * combine.c (simplify_logical): Only simplify logical expressions of the form ior(and(x,y),z) by the inverse distributive law if the result is cheaper than the original. Co-Authored-By: Eric Botcazou <ebotcazou@libertysurf.fr> From-SVN: r94114
2005-01-21re PR target/18701 (mmix-knuth-mmixware gcc.c-torture/execute failures: ↵Hans-Peter Nilsson1-6/+2
20010224-1.c, 20020216-1.c, 20040218-1.c, 20040709-2.c) PR target/18701 * combine.c (combine_simplify_rtx): Revert change of 2004-12-31. From-SVN: r94005
2005-01-19re PR rtl-optimization/15139 (cc1 uses excessive amounts of memory compiling ↵Jakub Jelinek1-0/+49
small routine) PR rtl-optimization/15139 * combine.c: Include params.h. (count_rtxs): New function. (record_value_for_reg): If replace_rtx would replace at least 2 occurrences of REG in VALUE and TEM is really large, replace REG with (clobber (const_int 0)) instead of TEM. * params.def (PARAM_MAX_LAST_VALUE_RTL): New. * params.h (MAX_LAST_VALUE_RTL): New. * Makefile.in (combine.o): Depend on $(PARAMS_H). * doc/invoke.texi (--param max-last-value-rtl=N): Document. * gcc.dg/20050111-2.c: New test. From-SVN: r93892
2005-01-18basic-block.h, [...]: Update copyright.Kazu Hirata1-1/+1
* 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-18re PR rtl-optimization/19296 (Range check on short miscompiled at -O)Eric Botcazou1-24/+51
PR rtl-optimization/19296 * combine.c (simplify_comparison): Rewrite the condition under which a non-paradoxical SUBREG of a PLUS can be lifted when compared against a constant. From-SVN: r93818
2005-01-05combine.c (expand_compound_operation): Add comment that we fall through ↵Steven Bosscher1-2/+3
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
2004-12-31re PR target/18701 (mmix-knuth-mmixware gcc.c-torture/execute failures: ↵Hans-Peter Nilsson1-2/+6
20010224-1.c, 20020216-1.c, 20040218-1.c, 20040709-2.c) PR target/18701 * combine.c (combine_simplify_rtx): Do not allow paradoxical subregs of MEM. From-SVN: r92762
2004-12-31re PR target/18701 (mmix-knuth-mmixware gcc.c-torture/execute failures: ↵Hans-Peter Nilsson1-1/+9
20010224-1.c, 20020216-1.c, 20040218-1.c, 20040709-2.c) PR target/18701 * combine.c (gen_lowpart_for_combine): When stripping SUBREG of MEM, adjust imode and isize. From-SVN: r92760
2004-12-15combine.c (combine_validate_cost): Consider cost of undobuf.other_insn ↵Ian Lance Taylor1-2/+17
rather than always allowing the... * combine.c (combine_validate_cost): Consider cost of undobuf.other_insn rather than always allowing the recombination if it is set. From-SVN: r92173
2004-11-27re PR rtl-optimization/17825 (ICE in reg_bitfield_target_p)Jakub Jelinek1-3/+3
PR rtl-optimization/17825 * combine.c (subst): Ignore STRICT_LOW_PART no matter if REG_P (new) or not. * gcc.c-torture/compile/20041119-1.c: New test. From-SVN: r91369
2004-11-23combine.c (gen_lowpart_for_combine): Factor out mode of x as well as mode ↵Richard Henderson1-34/+32
sizes into local temporaries. * combine.c (gen_lowpart_for_combine): Factor out mode of x as well as mode sizes into local temporaries. Unify failure path. From-SVN: r91118
2004-10-22alias.c, [...]: Fix comment formatting.Kazu Hirata1-1/+1
* alias.c, basic-block.h, cgraphunit.c, combine.c, domwalk.h, final.c, gengtype.c, genpreds.c, ggc-page.c, insn-notes.def, lambda-code.c, loop-unroll.c, modulo-sched.c, pointer-set.c, pretty-print.c, ra-colorize.c, sbitmap.c, tree-complex.c, tree-data-ref.c, tree-dfa.c, tree-inline.c, tree-into-ssa.c, tree-scalar-evolution.c, tree-ssa-dom.c, tree-ssa-loop-manip.c, tree-ssa-loop-niter.c, tree-ssa-phiopt.c, tree-ssa-pre.c, tree-ssa-threadupdate.c, tree-vectorizer.c, vec.h: Fix comment formatting. From-SVN: r89453
2004-10-18simplify-rtx.c (mode_signbit_p): Externalize function...Pat Haugen1-0/+20
2004-10-18 Pat Haugen <pthaugen@us.ibm.com> * simplify-rtx.c (mode_signbit_p): Externalize function... * rtl.h (mode_signbit_p): ... to here. * combine.c (simplify_shift_const): Recognize PLUS signbit as canonical form of XOR signbit and move to outer op. From-SVN: r89235
2004-09-30combine.c (force_to_mode): Only convert the expression (AND (NE FOO 0) ↵Roger Sayle1-0/+1
CONST) into (AND FOO CONST) if... * combine.c (force_to_mode) <NE_EXPR>: Only convert the expression (AND (NE FOO 0) CONST) into (AND FOO CONST) if FOO has the same machine mode as the result. From-SVN: r88369
2004-09-28cse.c (cse_insn): Avoid creating direct non-local jumps.Ulrich Weigand1-0/+2
* cse.c (cse_insn): Avoid creating direct non-local jumps. * combine.c (can_combine_p): Likewise. * local-alloc. (update_equiv_regs): Likewise. From-SVN: r88258
2004-09-26re PR rtl-optimization/17151 (x >> (y % WORDSIZE) not optimized)Roger Sayle1-5/+0
PR middle-end/17151 * combine.c (force_to_mode): Remove dubious early return test that inhibits further optimization. From-SVN: r88129
2004-09-24re PR middle-end/17503 (quadratic behaviour in invalid_mode_change_p)Richard Henderson1-7/+2
PR rtl-opt/17503 * regclass.c (subregs_of_mode): Turn into an htab. Make static. (som_hash, som_eq): New. (init_subregs_of_mode, record_subregs_of_mode): New. (cannot_change_mode_set_regs): Rewrite for htab implementation. (invalid_mode_change_p): Likewise. * combine.c (gen_lowpart_for_combine): Use record_subregs_of_mode. * flow.c (mark_used_regs): Likewise. (life_analysis): Use init_subregs_of_mode. * regs.h (subregs_of_mode): Remove. * rtl.h (init_subregs_of_mode, record_subregs_of_mode): Declare. From-SVN: r88067