summaryrefslogtreecommitdiff
path: root/gcc/ifcvt.c
Commit message (Collapse)AuthorAgeFilesLines
* * ifcvt.c (dead_or_predicable): Fix return value last patch.Richard Henderson2001-06-131-1/+1
| | | | From-SVN: r43357
* ifcvt.c (cond_exec_get_condition): Use reversed_comparison_code.Richard Henderson2001-06-131-10/+25
| | | | | | | * ifcvt.c (cond_exec_get_condition): Use reversed_comparison_code. (cond_exec_process_if_block, dead_or_predicable): Likewise. From-SVN: r43336
* ifcvt.c (life_data_ok): New.Richard Henderson2001-06-101-4/+8
| | | | | | | | | * ifcvt.c (life_data_ok): New. (merge_if_block): Use it to determine whether to update global_live_at_end. (if_convert): Set it. From-SVN: r43170
* predict.def: New file.Jan Hubicka2001-06-091-5/+1
| | | | | | | | | | | | | | | | | | | | | | | | | * predict.def: New file. * predict.h: New file. * predict.c: Include predict.h. (predictor_info): New structure and array. (predict_edge, predict_insn): Rewrite; make global. (predict_edge_def, predict_insn_def): New global functions. (dump_prediction, combine_predictions_for_insns): New static functions. (estimate_probability): Change calls to predict_edge to predict_edge_def and calls to predict_insn to predict_insn_def; combine probabilities. (expected_value_to_br_prob): Behave as predictor. * rtl.h (REG_BR_PRED): Update coment. (invert_br_probabilities): New. * jump.c: Include predict.h (duplicate_loop_exit_test): Drop branch prediction notes. (invert_jump): Use invert_br_probabilities. * Makefile.in: Add dependancy on predict.h for jump and predict pass. * ifcvt.c (dead_or_predicable): Use invert_br_probabilities. * combine.c (distribute_notes): Handle BR_PRED. From-SVN: r43115
* ifcvt.c (merge_if_block): Use any_uncondjump_p...Jeffrey A Law2001-05-101-1/+1
| | | | | | | | | | | * ifcvt.c (merge_if_block): Use any_uncondjump_p, not simplejump_p to determine if a block has an unconditional jump at its end. * jump.c (jump_optimize_1): When converting a conditional jump to an unconditional jump, build the jump using gen_jump instead of just modify operands in-place. From-SVN: r41939
* Makefile.in (ifcvt.o): Depend on toplev.h.Kaveh R. Ghazi2001-04-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (ifcvt.o): Depend on toplev.h. * c-semantics.c: Include expr.h. * ifcvt.c: Include toplev.h. * expr.h (rtx_equal_p): Delete prototype. * rtl.h (exact_log2_wide, floor_log2_wide, permalloc, protect_from_queue, gen_jump, gen_beq, gen_bge, gen_ble, eliminate_constant_term, expand_complex_abs, find_single_use, make_tree, init_expr_once, init_optabs, supports_one_only): Likewise. * tree.h (exact_log2_wide, floor_log2_wide, expand_null_return, rest_of_type_compilation, emit_queue, do_pending_stack_adjust, expand_assignment, store_expr, emit_line_note_after, emit_line_note_force, split_specs_attrs, label_rtx): Likewise. * toplev.h (exact_log2_wide, floor_log2_wide): Add prototype. cp: * Make-lang.in (cp/semantics.o): Depend on $(EXPR_H). * semantics.c: Include expr.h. java: * Make-lang.in (java/boehm.o): Depend on toplev.h. * boehm.c: Include toplev.h. From-SVN: r41256
* Use byte offsets in SUBREGs instead of words.Jakub Jelinek2001-04-031-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-04-03 Jakub Jelinek <jakub@redhat.com> David S. Miller <davem@pierdol.cobaltmicro.com> Andrew MacLeod <amacleod@redhat.com> Use byte offsets in SUBREGs instead of words. * alias.c (nonlocal_mentioned_p): Use subreg_regno function. * caller-save.c (mark_set_regs): Change callers of subreg_hard_regno to pass new argument. (add_stored_regs): Use subreg_regno_offset function. * calls.c (expand_call): For non-paradoxical SUBREG take endianess into account. (precompute_arguments): Use gen_lowpart_SUBREG. * combine.c (try_combine): Replace explicit XEXP with SUBREG_REG. (combine_simplify_rtx): Rework to use SUBREG_BYTE. (simplify_set): Rework to use SUBREG_BYTE. (expand_field_assignment): Use SUBREG_BYTE. (make_extraction): Use SUBREG_BYTE. (if_then_else_cond): Use SUBREG_BYTE. (apply_distributive_law): Use SUBREG_BYTE and fixup subreg comments. (gen_lowpart_for_combine): Compute full byte offset. * cse.c (mention_regs): Use SUBREG_BYTE. (remove_invalid_subreg_refs): Rework to use SUBREG_BYTE. (canon_hash): Use SUBREG_BYTE. (fold_rtx): Pass SUBREG_BYTE div UNITS_PER_WORD to operand_subword. (gen_lowpart_if_possible): Formatting. * dbxout.c (dbxout_symbol_location): Compute SUBREG hard regnos correctly. * dwarf2out.c (is_pseudo_reg): Fixup explicit XEXP into SUBREG_REG (mem_loc_descriptor): Fixup explicit XEXP into SUBREG_REG (loc_descriptor): Fixup explicit XEXP into SUBREG_REG * dwarfout.c (is_pseudo_reg): Fixup explicit XEXP into SUBREG_REG (output_mem_loc_descriptor): Fixup explicit XEXP into SUBREG_REG (output_loc_descriptor): Fixup explicit XEXP into SUBREG_REG * emit-rtl.c (gen_rtx_SUBREG): New function, used to verify certain invariants about SUBREGs the compiler creates. (gen_lowpart_SUBREG): New function. (subreg_hard_regno): New function to get the final register number. (gen_lowpart_common): Use SUBREG_BYTE. (gen_imagpart): Spacing nits. (subreg_realpart_p): Use SUBREG_BYTE. (gen_highpart): Use SUBREG_BYTE. (subreg_lowpart_p): Always compute endian corrected goal offset, even at the byte level, then compare against that. (constant_subword): New function, pulled out all constant cases from operand_subword and changed second argument name to offset. (operand_subword): Detect non REG/SUBREG/CONCAT/MEM cases early and call constant_subword to do the work. Return const0_rtx if looking for a word outside of OP. (operand_subword_force): Change second arg name to offset. * expmed.c (store_bit_field): Use SUBREG_BYTE. (store_split_bit_field): Use SUBREG_BYTE. (extract_bit_field): Use SUBREG_BYTE. (extract_split_bit_field): Use SUBREG_BYTE. (expand_shift): Use SUBREG_BYTE. * expr.c (store_expr, expand_expr): Use gen_lowpart_SUBREG. * final.c (alter_subreg) Use subreg_hard_regno and SUBREG_BYTE. * flow.c (set_noop_p): Use SUBREG_BYTE. (mark_set_1): Remove ALTER_HARD_SUBREG. Use subreg_regno_offset instead. * function.c (fixup_var_refs_1): Fixup explicit XEXP into a SUBREG_REG. (fixup_memory_subreg): Use SUBREG_BYTE and remove byte endian correction code. (optimize_bit_field): Use SUBREG_BYTE. (purge_addressof_1): Use SUBREG_BYTE. (purge_single_hard_subreg_set): Use subreg_regno_offset function. (assign_params): Mark arguments SUBREG_PROMOTED_VAR_P if they are actually promoted by the caller and PROMOTE_FOR_CALLS_ONLY is true. * gengenrtl.c (special_rtx): Add SUBREG. * global.c (mark_reg_store): Use SUBREG_BYTE. (set_preference): Rework to use subreg_regno_offset and SUBREG_BYTE. * ifcvt (noce_emit_move_insn): Use SUBREG_BYTE. * integrate.c (copy_rtx_and_substitute): Use SUBREG_BYTE and make sure final byte offset is congruent to subreg's mode size. (subst_constants): Use SUBREG_BYTE. (mark_stores): Use subreg_regno_offset function. * jump.c (rtx_renumbered_equal_p, true_regnum): Use subreg_regno_offset function and SUBREG_BYTE. * local-alloc.c (combine_regs): Use subreg_regno_offset function. (reg_is_born): Use subreg_hard_regno. * recog.c (valid_replace_rtx_1): Use SUBREG_BYTE and remove byte endian correction code. Don't combine subregs unless resulting offset aligns with type. Fix subreg constant extraction for DImode. Simplify SUBREG of VOIDmode CONST_DOUBLE. (general_operand): Remove dead mode_altering_drug code. (indirect_operand): Use SUBREG_BYTE. (constrain_operands): Use subreg_regno_offset function. * reg-stack.c (get_true_reg): Use subreg_regno_offset function. * regmove.c (regmove_optimize): Use SUBREG_BYTE. (optimize_reg_copy_3): Use gen_lowpart_SUBREG. * regs.h (REG_SIZE): Allow target to override. (REGMODE_NATURAL_SIZE): New macro which target can override. * reload.c (reload_inner_reg_of_subreg): subreg_regno should be used on the entire subreg rtx. (push_reload): Use SUBREG_BYTE in comments and code. (find_dummy_reload): Use subreg_regno_offset. Only adjust offsets for hard registers inside subregs. (operands_match_p): Use subreg_regno_offset. (find_reloads): Use SUBREG_BYTE and only advance offset for subregs containing hard regs. (find_reload_toplev): Use SUBREG_BYTE. Remove byte endian corrections when fixing up MEM subregs. (find_reloads_address_1): Use SUBREG_BYTE, subreg_regno, and subreg_regno_offset where appropriate. (find_reloads_subreg_address): Use SUBREG_BYTE. Remove byte endian corrections when fixing up MEM subregs. (subst_reloads): When combining two subregs, make sure final offset is congruent to subreg's mode size. (find_replacement): Use SUBREG_BYTE and subreg_regno_offset. (refers_to_regno_for_reload_p): Use subreg_regno. (reg_overlap_mentioned_for_reload_p): Use subreg_regno_offset. * reload1.c (eliminate_regs) Use SUBREG_BYTE. Remove byte endian correction code for memory subreg fixups. (forget_old_reload_1): Use subreg_regno_offset. (choose_reload_regs): Use subreg_regno. (emit_input_reload_insns): Use SUBREG_BYTE. (reload_combine_note_store): Use subreg_regno_offset. (move2add_note_store): Use subreg_regno_offset. * resource.c (update_live_status, mark_referenced_resources): Use subreg_regno function. (mark_set_resources): Use subreg_regno function. * rtl.h (SUBREG_WORD): Rename to SUBREG_BYTE. (subreg_regno_offset, subreg_regno): Define prototypes. (subreg_hard_regno, constant_subword, gen_rtx_SUBREG): Newi functions. (gen_lowpart_SUBREG): Add prototype. * rtl.texi (subreg): Update to reflect new byte offset representation. Add mentioning of the effect that BYTES_BIG_ENDIAN has on subregs now. * rtlanal.c (refers_to_regno_p): Use subreg_regno. (reg_overlap_mentioned_p): Use subreg_regno. (replace_regs); Make sure final offset of combined subreg is congruent to size of subreg's mode. (subreg_regno_offset): New function. (subreg_regno): New function. * sched-vis.c (print_value): Change SUBREG_WORD to SUBREG_BYTE. * sdbout.c (sdbout_symbol): Compute offset using alter_subreg. * stmt.c (expand_anon_union_decl): Use gen_lowpart_SUBREG. * tm.texi (ALTER_HARD_SUBREG): Remove, it is now dead. (SUBREG_REGNO_OFFSET): Describe SUBREG_REGNO_OFFSET overrides. * config/a29k/a29k.c (gpc_reg_operand): Use subreg_regno. (a29k_get_reloaded_address): Use SUBREG_BYTE. (print_operand): Use SUBREG_BYTE. * config/alpha/alpha.c (print_operand_address): Use SUBREG_BYTE. * config/arm/arm.c (arm_reload_in_hi): Use SUBREG_BYTE. (arm_reload_out_hi): Use SUBREG_BYTE. * config/d30v/d30v.c (d30v_split_double): Use subreg_regno_offset instead of SUBREG_WORD. (d30v_print_operand_memory_reference): Use subreg_regno_offset. * config/dsp16xx/dsp16xx.md (extendqihi2, zero_extendqihi2): Fix SUBREG creation to use byte offset. * config/h8300/h8300.md (Unnamed HImode zero extraction and 16bit inverted load insns): Fix explicit rtl subregs to use byte offsets. * config/i370/i370.md (cmpstrsi, movstrsi, mulsi3, divsi3, udivsi3, umodsi3): Generate SUBREGs with byte offsets. * config/i860/i860.c (single_insn_src_p): Use SUBREG_BYTE. * config/i860/i860.md (mulsi3_big): Fixup explicit SUBREGs in rtl to use byte offsets. (unnamed fmlow.dd insn): Fixup SUBREGS to use byte offsets. * config/i960/i960.md (extendhisi2): Generate SUBREGs with byte offsets, also make sure it is congruent to SUBREG's mode size. (extendqisi2, extendqihi2, zero_extendhisi2, zero_extendqisi2, unnamed ldob insn): Generate SUBREGs with byte offset. (zero_extendqihi2): SUBREG's are byte offsets. * config/m68hc11/m68hc11.c (m68hc11_gen_lowpart): Use SUBREG_BYTE. (m68hc11_gen_highpart): Use SUBREG_BYTE. * config/m68k/m68k.md (zero_extendhisi2, zero_extendqihi2, zero-extendqisi2): Generate SUBREGs with byte offset. (umulsidi3, mulsidi3, subreghi1ashrdi_const32, subregsi1ashrdi_const32, subreg1lshrdi_const32): Fixup explicit subregs in rtl to use byte offsets. * config/m88k/m88k.md (extendsidi2): fixup subregs to use byte offset. * config/mips/mips.c (mips_move_1word): Use subreg_regno_offset. (mips_move_2words): Use subreg_regno_offset. (mips_secondary_reload_class): Use subreg_regno_offset. * config/mips/mips.md (DImode plus, minus, move, and logical op splits): Fixup explicit subregs in rtl to use byte offsets. * config/mn10200/mn10200.c (print_operand): Use subreg_regno function. * config/mn10300/mn10300.c (print_operand): Use subreg_regno function. * config/ns32k/ns32k.md (udivmoddisi4): Fix explicit subregs in rtl to use byte offsets. * config/pa/pa.c (emit_move_sequence): Use SUBREG_BYTE. * config/pa/pa.md (floatunssisf2, floatunssidf2, mulsi3): fix explicit subregs to use byte offsets. * config/pdp11/pdp11.md (zero_extendhisi2, modhi3, modhi3+1): Fixup explicit subregs in rtl to use byte offsets. * config/romp/romp.c (memory_offset_in_range_p): Use SUBREG_BYTE and remove byte endian correction code. * config/sh/sh.c (output_movedouble): Use subreg_regno. (gen_ashift_hi): Use SUBREG_BYTE. (regs_used): Use subreg_regno_offset. (machine_dependent_reorg): Use subreg_regno_offset. * config/sh/sh.h (INDEX_REGISTER_RTX_P): Use SUBREG_BYTE. * config/sh/sh.md (DImode and DFmode move splits): Use subreg_regno. (movdf_i4): Subregs are byte offsets now. * config/sparc/sparc.c (ultra_find_type): Use SUBREG_BYTE. * config/sparc/sparc.h (ALTER_HARD_SUBREG): Removed. (REGMODE_NATURAL_SIZE): Override. (REG_SIZE): For SUBREG check float mode on SUBREG_REG's mode. * config/sparc/sparc.md (TFmode move splits): Generate SUBREGs with byte offsets. (zero_extendhisi2, zero_extendqidi2_insn, extendhisi2, extendqihi2, sign_extendqihi2_insn, sign_extendqisi2_insn, extendqidi2): Generate SUBREGs with byte offsets, also make sure it is congruent to SUBREG's mode size. (smulsi3_highpart_v8plus): Fix explicit subregs in rtl to use byte offsets. (cmp_siqi_trunc, cmp_siqi_trunc_set, cmp_diqi_trunc, cmp_diqi_trunc_set, lshrdi3_v8plus+1, lshrdi3_v8plus+2, lshrdi3_v8plus+3, lshrdi3_v8plus+4): Use proper SUBREG_BYTE offset for non-paradoxical subregs in patterns. * config/v850/v850.c (print_operand, output_move_double): Use subreg_regno function. Co-Authored-By: Andrew MacLeod <amacleod@redhat.com> Co-Authored-By: David S. Miller <davem@pierdol.cobaltmicro.com> From-SVN: r41058
* ifcvt.c (noce_emit_move_insn): New.Jakub Jelinek2001-04-021-11/+41
| | | | | | | | | | | | | | * ifcvt.c (noce_emit_move_insn): New. (noce_try_store_flag, noce_try_store_flag_constants, noce_try_store_flag_inc, noce_try_store_flag_mask, noce_try_cmove, noce_try_cmove_arith, noce_try_minmax, noce_try_abs): Use it. (noce_process_if_block): Likewise. For STRICT_LOW_PART, take mode from its SUBREG. * gcc.c-torture/compile/20010329-1.c: New test. From-SVN: r41001
* IA-64 ABI Exception Handling.Richard Henderson2001-03-281-10/+1
| | | | From-SVN: r40924
* cse.c (find_comparison_args): Remove previous change.Richard Kenner2001-03-211-0/+8
| | | | | | | | * cse.c (find_comparison_args): Remove previous change. * ifcvt.c (noce_process_if_block): When moving an insn, remove any REG_EQUAL notes. From-SVN: r40715
* Brad's -ffast-math breakup.Brad Lucier2001-03-071-3/+3
| | | | From-SVN: r40300
* * ifcvt.c (noce_operand_ok): Handle properly unarry operations.Jan Hubicka2001-03-021-1/+2
| | | | From-SVN: r40181
* ifcvt.c (noce_emit_store_flag, [...]): Use reversed_comparison_code instead ↵Jan Hubicka2001-02-281-15/+16
| | | | | | | | | | | | of reverse_comparison and... * ifcvt.c (noce_emit_store_flag, noce_try_store_flag_constants, noce_try_store_flag_inc, noce_try_store_flag_mask, noce_try_cmove_arith): Use reversed_comparison_code instead of reverse_comparison and can_reverse_comparison_p. From-SVN: r40119
* ifcvt.c (struct noce_if_info): Add test_bb.Richard Henderson2001-02-251-3/+326
| | | | | | | | | | | * ifcvt.c (struct noce_if_info): Add test_bb. (noce_get_alt_condition): New. (noce_try_minmax, noce_try_abs): New. (noce_operand_ok): New. (noce_process_if_block): Use them. * rtlanal.c (may_trap_p): NEG and ABS can never trap. From-SVN: r40060
* ifcvt.c (dead_or_predicable): Don't move code if eh regions would be disrupted.Richard Henderson2001-02-181-0/+9
| | | | | | | * ifcvt.c (dead_or_predicable): Don't move code if eh regions would be disrupted. From-SVN: r39843
* Handle jump insns that are PARALLEL.Nick Clifton2000-12-271-1/+1
| | | | From-SVN: r38501
* While building global lifetime information, keep track of which registers ↵Bernd Schmidt2000-11-271-2/+3
| | | | | | | | | | are only conditionally set. While building global lifetime information, keep track of which registers are only conditionally set. Use this to force rescans in more cases where they are needed. From-SVN: r37801
* Michael Matz <matzmich@cs.tu-berlin.de>Michael Matz2000-11-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | * dominance.c: New file. * Makefile.in (OBJS): Add dominance.o. * flow.c (compute_flow_dominators): Remove. (compute_immediate_dominators): Remove. (compute_immediate_postdominators): Remove. * basic-block.h: Remove their prototypes. (calculate_dominance_info): Add prototype. * dce.c (eliminate_dead_code): Change calls to above functions. Don't compute dominators but only immediate dominators. * flow.c (flow_loops_find): Change callers. * gcse.c (compute_code_hoist_data): Likewise. * haifa-sched.c (schedule_insns): Likewise. * ifcvt.c (if_convert): Likewise. * ssa.c (convert_to_ssa): Likewise, and only compute immediate dominators. From-SVN: r37449
* Fix ia64-linux glibc intl/loadmsgcat.c miscompilation.Jim Wilson2000-09-121-0/+5
| | | | | | | * ifcvt.c (noce_process_if_block): If A and B are the same, and no else block, and X has side-effects, then fail. From-SVN: r36373
* Make sure THEN block has any insns at before testing for indirect jumpMichael Meissner2000-08-201-3/+6
| | | | From-SVN: r35813
* Do not consider a THEN block ending in an indirect jump for conditional ↵Michael Meissner2000-08-191-1/+13
| | | | | | compilation; Fix d30v warning From-SVN: r35812
* ifcvt.c (EDGE_COMPLEX): Move definition ...John Wehle2000-06-141-2/+0
| | | | | | | | | | * ifcvt.c (EDGE_COMPLEX): Move definition ... * basic-block.h (EDGE_COMPLEX): ... here. * loop.c (check_dbra_loop): Specify the register when generating REG_NONNEG notes and don't generate duplicates. From-SVN: r34542
* Do not handle dead code via conditional execution if special handling is neededMichael Meissner2000-06-131-0/+4
| | | | From-SVN: r34512
* Warning fixes:Kaveh R. Ghazi2000-06-111-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 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
* add IFCVT_MODIFY macros for the MD file to tweak the conditional execution ↵Michael Meissner2000-06-041-1/+34
| | | | | | support. From-SVN: r34386
* ifcvt.c (merge_if_block): Be prepared for JOIN to have no remaining edges.Richard Henderson2000-05-311-7/+23
| | | | | | | | | | * ifcvt.c (merge_if_block): Be prepared for JOIN to have no remaining edges. (find_if_block): Allow THEN with no outgoing edges. * flow.c (merge_blocks_nomove): Remove a barrier not following a jump as well. From-SVN: r34317
* * ifcvt.c (cond_exec_process_insns): Don't ever ignore clobbers.Richard Henderson2000-05-311-4/+2
| | | | From-SVN: r34316
* ifcvt.c (cond_exec_process_if_block): Do nothing if the last insn in the ↵Jeffrey A Law2000-05-311-0/+10
| | | | | | | | | | block is more than just a simple conditional... * ifcvt.c (cond_exec_process_if_block): Do nothing if the last insn in the block is more than just a simple conditional branch. (noce_process_if_block): Similarly. From-SVN: r34287
* ifcvt.c (cond_exec_get_condition): Set test_if to the SET_SRC of get_pc.Richard Earnshaw2000-05-261-1/+1
| | | | | | | * ifcvt.c (cond_exec_get_condition): Set test_if to the SET_SRC of get_pc. From-SVN: r34192
* ifcvt.c (seq_contains_jump): New.Richard Henderson2000-05-251-0/+31
| | | | | | | | * ifcvt.c (seq_contains_jump): New. (noce_try_store_flag_constants): Use it to fail conversion. (noce_try_store_flag_inc, noce_try_store_flag_mask): Likewise. From-SVN: r34179
* combine.c (try_combine): Use any_condjump_p...Jan Hubicka2000-05-251-9/+10
| | | | | | | | | | | | | | | | | | | | | | * combine.c (try_combine): Use any_condjump_p, any_uncondjump_p and pc_set at the place of simplejump_p and condjump_p. * cse.c (record_jump_equiv): Likewise. * emit-rtl.c (emit): Likewise. * explow.c (find_next_ref): Likewise. * flow.c (tidy_fallthru_edge): Likewise. (init_propagate_block_info): Likewise. * gcse.c (delete_null_pointer_checks): Likewise. * ifcvt.c (cond_exec_get_condition, noce_get_condition, dead_or_predicable): Likewise. * integrate.c (copy_insn_list): Likewise. * loop.c (scan_loop, verify_dominator, find_and_verify_loops, for_each_insn_in_loop, check_dbra_loop, get_condition, insert_bct, load_mems): Likewise. * resource.c (find_dead_or_set_registers): Likewise. * sibcalls.c (simplejump_p): Likewise. * unroll.c (copy_loop_body, reg_dead_after_loop): Likewise. From-SVN: r34175
* * ifcvt.c (if_convert): Update life info globally.Jakub Jelinek2000-05-241-1/+3
| | | | From-SVN: r34119
* Oops, checked in verify-flow.patch by mistake, revertingAlexandre Oliva2000-05-201-2/+1
| | | | From-SVN: r34063
* * ifcvt.c (if_convert): Scan and kill dead code.Alexandre Oliva2000-05-201-2/+4
| | | | From-SVN: r34057
* cse.c (cse_basic_block): Only call find_reg_note if REG_NOTES not 0.Richard Kenner2000-05-191-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
* * ifcvt.c (find_if_case_2): Don't allow THEN to be EXIT.Richard Henderson2000-05-191-3/+6
| | | | From-SVN: r34036
* ifcvt.c (cond_exec_process_insns): Drop USE and CLOBBER insns that get in ↵Richard Henderson2000-05-151-0/+17
| | | | | | | | | | the way after reload. * ifcvt.c (cond_exec_process_insns): Drop USE and CLOBBER insns that get in the way after reload. (cond_exec_process_if_block): Skip a label heading THEN block. From-SVN: r33923
* * ifcvt.c (if_convert): Do not free NULL.Philippe De Muyter2000-05-131-1/+2
| | | | From-SVN: r33888
* Makefile.in (final.o): Depend on BASIC_BLOCK_H.Richard Henderson2000-05-121-52/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (final.o): Depend on BASIC_BLOCK_H. * final.c (final_end_function): Use app_disable. Rearrange note handling into a switch. Emit deleted labels. (output_asm_label): Generate label strings for deleted labels. * flow.c (tail_recursion_label_list): New. (find_basic_blocks_1): Set label_value_list directly. Collect list of tail recursion labels from call_placeholders. Don't add deleted labels to the label value list. (cleanup_cfg): Use free_EXPR_LIST_list. (flow_delete_insn_chain): Turn non-removable labels into notes. (flow_delete_block): Don't disable deleting the block because of a non-removable label. (tail_recursion_label_p): New. (merge_blocks_move_predecessor_nojumps): Don't disable the merge because of a label. (merge_blocks_move_successor_nojumps): Likewise. Also move a jump table. (merge_blocks): Disable a merge because of tail recursion labels. * ifcvt.c (merge_if_block): Don't disable a merge because of a label. Use a more accurate measure of not merging the join block. (find_if_block): Don't disable conversion because of a label. (find_if_case_1, find_if_case_2): Likewise. * jump.c (duplicate_loop_exit_test): Preserve the kind of list element when copying. (squeeze_notes): Also leave EH notes. (mark_jump_label): Ignore deleted labels. Use an INSN_LIST for REG_LABEL notes. (delete_insn): Preserve LABEL_NAME in NOTE_SOURCE_FILE when deleting a label. * print-rtl.c (print_rtx): Print NOTE_SOURCE_FILE for NOTE_INSN_DELETED_LABEL. Print `[# deleted]' for a label_ref referring to a deleted label. Convert tail handling to a switch. * rtl.def (CODE_LABEL): Rearrange elements to be compatible with NOTE for NOTE_INSN_DELETED_LABEL. (NOTE): Fix commentary. * rtl.h (REG_LABEL): Update commentary wrt INSN_LIST. (REG_CC_SETTER, REG_CC_USER, REG_LIBCALL): Likewise. (CODE_LABEL_NUMBER, LABEL_NAME): Update index. (LABEL_NUSES, LABEL_REFS): Likewise. * unroll.c (copy_loop_body): Don't copy NOTE_INSN_DELETED_LABEL. From-SVN: r33876
* ifcvt.c (cond_exec_process_insns): New argument prob_val.Richard Henderson2000-05-081-9/+35
| | | | | | | | | | * ifcvt.c (cond_exec_process_insns): New argument prob_val. Attach it to call insns. (cond_exec_process_if_block): Track probability for true and false branches. (dead_or_predicable): Likewise. From-SVN: r33791
* ifcvt.c (noce_process_if_block): Don't use an insn_b from test_bb if a or b ↵Richard Henderson2000-05-061-1/+2
| | | | | | | | | uses x. * ifcvt.c (noce_process_if_block): Don't use an insn_b from test_bb if a or b uses x. From-SVN: r33738
* ifcvt.c (noce_process_if_block): Don't use an insn_b from test_bb if insn_a ↵Richard Henderson2000-05-061-1/+2
| | | | | | | | | uses x. * ifcvt.c (noce_process_if_block): Don't use an insn_b from test_bb if insn_a uses x. From-SVN: r33737
* * ifcvt.c (noce_process_if_block): Always reset X in the A == B case.Richard Henderson2000-05-041-1/+1
| | | | From-SVN: r33690
* ifcvt.c (noce_process_if_block): Fail if A or B modified between condition ↵Richard Henderson2000-05-041-5/+11
| | | | | | | | | and jump. * ifcvt.c (noce_process_if_block): Fail if A or B modified between condition and jump. From-SVN: r33689
* ifcvt.c (noce_try_cmove_arith): Use may_trap_p to thest whether address may ↵Jan Hubicka2000-05-031-2/+2
| | | | | | | | | trap. * ifcvt.c (noce_try_cmove_arith): Use may_trap_p to thest whether address may trap. From-SVN: r33627
* ifcvt.c (dead_or_predicable): Set merge_bb->end to the insn before the ↵Richard Henderson2000-05-011-2/+3
| | | | | | | | | sequence we're moving... * ifcvt.c (dead_or_predicable): Set merge_bb->end to the insn before the sequence we're moving, not to merge_bb->head. From-SVN: r33605
* * ifcvt.c (if_convert): Only verify_flow_info if ENABLE_CHECKING.Richard Henderson2000-05-011-0/+2
| | | | From-SVN: r33590
* ifcvt.c (noce_emit_cmove): Conditionally compile call to emit_conditional_move.Richard Henderson2000-05-011-0/+8
| | | | | | | * ifcvt.c (noce_emit_cmove): Conditionally compile call to emit_conditional_move. From-SVN: r33585
* ifcvt.c (noce_process_if_block): Fail the conversion if X is referenced ↵Richard Henderson2000-04-301-6/+11
| | | | | | | | | | bewteen the condition and the jump. * ifcvt.c (noce_process_if_block): Fail the conversion if X is referenced bewteen the condition and the jump. Don't delete anything but the jump. From-SVN: r33563
* ifcvt.c (dead_or_predicable): Manually squeeze non-movable notes from the ↵Richard Henderson2000-04-301-0/+13
| | | | | | | | | last insn in the sequence. * ifcvt.c (dead_or_predicable): Manually squeeze non-movable notes from the last insn in the sequence. From-SVN: r33555