aboutsummaryrefslogtreecommitdiff
path: root/gcc/combine.c
AgeCommit message (Collapse)AuthorFilesLines
2001-06-15combine.c (nonzero_bits): Don't optimize away division by zero.Andrew Haley1-0/+8
2001-06-14 Andrew Haley <aph@redhat.com> * combine.c (nonzero_bits): Don't optimize away division by zero. From-SVN: r43398
2001-06-09predict.def: New file.Jan Hubicka1-0/+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
2001-06-04rtlanal.c (operand_preference): Fix preference for objects.Jan Hubicka1-20/+7
* rtlanal.c (operand_preference): Fix preference for objects. * gcse.c (handle_avail_expr): Be prepared to handle single_set parallels. * combine.c (if_then_else_cond): Use simplify_subreg instead of operand_subword. * integreate.c (sub_constants): Likewise. * emit-rtl.c (constant_subword): Deprecate; remove most of code and use simplify_gen_subreg. Mon Jun 4 19:55:23 CEST 2001 Lars Brinkhoff <lars@nocrew.org> * sibcall.c (skip_copy_to_return_value): recognize the situation when the called function's return value is copied into an intermediate pseudo, and then into the calling functions return value register. From-SVN: r42864
2001-06-04simplify_rtx.c (simplify_subreg): Keep subregs on return values...Jan Hubicka1-13/+8
* simplify_rtx.c (simplify_subreg): Keep subregs on return values, check CLASS_CANNOT_CHANGE_MODE before avoiding subreg on hard reg, in case register wasn't OK previously, accept it now; allow subregs of frame pointer if reload completed and frame pointer is not needed. * combine.c (sombine_simplify_rtx): Fix comment; use subreg_lowpart_offset instead of subreg_lowpart_p (gen_lowpart_for_combine): Use subreg_lowpart_offset. * rtl.h (subreg_lowpart_parts_p): Kill. (subreg_lowpart_offset, subreg_highpart_offset): Declare. * simplify-rtx.c (simplify_subreg): Use subreg_lowpart_offset. * emit-rtl.c (gen_lowpart_SUBREG): Use subreg_lowpart_offset; (gen_lowpart_common): Likewise. (subreg_lowpart_p): Likewise. (subreg_lowpart_parts_p): Kill. (subreg_lowpart_offset, subreg_highpart_offset): New function. * emit-rtl.c (gen_lowpart_common): Use simplify_gen_subreg to simplify SUBREG and REG. (gen_highpart): Use simplify_gen_subreg for all simplifications. * emit-rtl.c (gen_realpart, gen_imagpart): Do not handle CONCAT specially. * rtlanal.c (replace_regs): Use simplify_gen_subreg From-SVN: r42850
2001-05-27combine.c (try_combine): Fix typo in comment.Lars Brinkhoff1-1/+1
* combine.c (try_combine): Fix typo in comment. * expr.c (expand_expr): Likewise. * config/i370/i370.md (untyped_call): Likewise. From-SVN: r42655
2001-05-22combine.c (gen_binary): Use swap_commutative_operands_pJan Hubicka1-3/+2
* combine.c (gen_binary): Use swap_commutative_operands_p (simplify_comparison): Likewise. * expmed.c (emit_store_flag): Likewise. * expr.c (compare_from_rtx): Likewise. (do_compare_rtx_and_jump): Likewise. * optabs.c (emit_cmp_and_jump_insn): Revert last patch; abort if not emitting a branch and operands want swapping. From-SVN: r42433
2001-05-21combine.c (subst): Do not substitute for a register as a destination...Richard Henderson1-1/+10
* combine.c (subst): Do not substitute for a register as a destination subreg/strict_low_part/zero_extract. From-SVN: r42429
2001-05-21combine.c (simplify_comparison): Update op1 after constant extension.Richard Henderson1-0/+1
* combine.c (simplify_comparison): Update op1 after constant extension. * recog.c (const_int_operand): Accept only constants valid for the given mode. * genrecog.c: Update comments wrt const_int_operand. From-SVN: r42427
2001-05-18combine.c (combine_simplify_rtx): Clear op0_mode if simplification suceeded.Jan Hubicka1-1/+1
* combine.c (combine_simplify_rtx): Clear op0_mode if simplification suceeded. From-SVN: r42286
2001-05-17integrate.c (copy_rtx_and_substitute): Use simplify_gen_subreg.Jan Hubicka1-12/+2
* integrate.c (copy_rtx_and_substitute): Use simplify_gen_subreg. (simplify_subreg): Handle complex types represented as CONCAT. * recog.c (validate_replace_rtx_1): Properly canonicalize expression * rtl.h (swap_commutative_operands_p): Declare. * rtlanal.c (swap_commutative_operands_p): New. (operand_preference): New static function. * combine.c (combine_simplify_rtx): Use swap_commutative_operands_p. (gen_binary): Likewise. * optabs.c (emit_cmp_and_jump_insns, emit_conditional_move): Likewise. * simplify-rtx.c (simplify_gen_binary, simplify_gen_relational): Likewise. From-SVN: r42224
2001-05-17simplify-rtx.c (simplify_subreg): Break out from ...Jan Hubicka1-151/+11
* simplify-rtx.c (simplify_subreg): Break out from ... * combine.c (combine_splify_rtx) ... here and ... * recog.c (validate_replace_rtx_1): ... here; * rtl.h (subreg_lowpart_parts_p, simplify_subreg): Declare. * emit-rtl.c (subreg_lowpart_parts_p): Break out from ... (subreg_lowpart_p): ... here. From-SVN: r42199
2001-05-16combine.c (combine_simplify_rtx): Set op0_mode to VOIDmode after applying ↵Jan Hubicka1-0/+1
distributive law. * combine.c (combine_simplify_rtx): Set op0_mode to VOIDmode after applying distributive law. From-SVN: r42159
2001-05-11* combine.c (simplify_comparison): Fix typo.Graham Stott1-1/+1
From-SVN: r41967
2001-05-01bitmap.c: Change NULL_PTR to NULL or "(rtx*)0".Kaveh R. Ghazi1-2/+2
* bitmap.c: Change NULL_PTR to NULL or "(rtx*)0". * c-common.c: Likewise. * c-decl.c: Likewise. * combine.c: Likewise. * rs6000.c: Likewise. * except.c: Likewise. * explow.c: Likewise. * expr.c: Likewise. * fold-const.c: Likewise. * function.c: Likewise. * gcc.c: Likewise. * gcse.c: Likewise. * integrate.c: Likewise. * loop.c: Likewise. * objc/objc-act.c: Likewise. * recog.c: Likewise. * reg-stack.c: Likewise. * reload.c: Likewise. * reload1.c: Likewise. * simplify-rtx.c: Likewise. * stmt.c: Likewise. * varasm.c: Likewise. From-SVN: r41722
2001-04-03Use byte offsets in SUBREGs instead of words.Jakub Jelinek1-56/+109
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
2001-03-27combine.c (distribute_notes): If non-call exceptions, put the note on the ↵Richard Henderson1-0/+19
trapping instruction. * combine.c (distribute_notes) [REG_EH_REGION]: If non-call exceptions, put the note on the trapping instruction. From-SVN: r40907
2001-03-26combine.c (try_combine): Use memcpy, not bcopy.Kaveh R. Ghazi1-2/+2
* combine.c (try_combine): Use memcpy, not bcopy. * genattrtab.c (expand_units): Likewise. From-SVN: r40849
2001-03-22mkconfig.sh: Include insn-flags.h.Richard Henderson1-2/+0
* mkconfig.sh: Include insn-flags.h. * Makefile.in (CONFIG_H): Include insn-flags.h. (lots of objects): Remove insn-codes.h and insn-flags.h. * alias.c, bb-reorder.c, calls.c, do-loop.c, flow.c, haifa-sched.c, integrate.c, jump.c, loop.c, predict.c, profile.c, reg-stack.c, regmove.c, reorg.c, a29k/a29k.c, alpha/alpha.c, arc/arc.c, arm/arm.c, avr/avr.c, clipper/clipper.c, convex/convex.c, d30v/d30v.c, dsp16xx/dsp16xx.c, fr30/fr30.c, h8300/h8300.c, i370/i370.c, i386/i386.c, i860/i860.c, ia64/ia64.c, m32r/m32r.c, m68hc11/m68hc11.c, m68k/m68k.c, m88k/m88k.c, mcore/mcore.c, mn10200/mn10200.c, mn10300/mn10300.c, ns32k/ns32k.c, pa/pa.c, pdp11/pdp11.c, pj/pj.c, romp/romp.c, rs6000/rs6000.c, sh/sh.c, sparc/sparc.c, v850/v850.c, vax/vax.c: Don't include insn-flags.h. * diagnostic.c, expr.h, reload.c, toplev.c: Don't include insn-codes.h. * builtins.c, combine.c, except.c, explow.c, expmed.c, expr.c, final.c, function.c, optabs.c, recog.c, reload1.c, stmt.c, c4x/c4x.c, i960/i960.c, mips/mips.c: Don't include insn-codes.h or insn-flags.h. * genemit.c, genopinit.c, genoutput.c: Don't include insn-codes.h or insn-flags.h in the generated code. * genflags.c (gen_proto): Use "struct rtx_def *" instead of "rtx". (main): Forward declare struct rtx_def. From-SVN: r40754
2001-03-18defaults.h (ACCUMULATE_OUTGOING_ARGS, PUSH_ARGS): Move from ...Richard Henderson1-13/+0
* defaults.h (ACCUMULATE_OUTGOING_ARGS, PUSH_ARGS): Move from ... * calls.c: ... here. * combine.c, expr.c, final.c, function.c toplev.c: Don't provide defaults for them here. From-SVN: r40603
2001-03-17combine.c (undobuf): Remove field previous_undos; all refs deleted.Richard Kenner1-243/+168
* combine.c (undobuf): Remove field previous_undos; all refs deleted. (gen_rtx_combine): Deleted; all references changed as appropriate. (gen_unary): Deleted; all refs changed to call simplify_gen_unary. From-SVN: r40577
2001-03-11combine.c (try_combine): Fix error in change to try original register.Richard Kenner1-22/+9
* combine.c (try_combine): Fix error in change to try original register. (gen_rtx_combine): Do same as gen_rtx for now. From-SVN: r40390
2001-03-07Brad's -ffast-math breakup.Brad Lucier1-5/+5
From-SVN: r40300
2001-03-03combine.c (try_combine): If split with mode-changed scratch register didn't ↵J"orn Rennecke1-0/+9
work, try the original mode. * combine.c (try_combine): If split with mode-changed scratch register didn't work, try the original mode. From-SVN: r40201
2001-03-02xm-lynx.h, [...]: Do not define TRUE or FALSE.Zack Weinberg1-85/+92
* config/xm-lynx.h, config/xm-std32.h, config/a29k/xm-a29k.h, config/a29k/xm-unix.h, config/alpha/xm-alpha.h, config/arc/xm-arc.h, config/arm/xm-arm.h, config/c4x/xm-c4x.h, config/clipper/xm-clix.h, config/convex/xm-convex.h, config/d30v/xm-d30v.h, config/dsp16xx/xm-dsp16xx.h, config/elxsi/xm-elxsi.h, config/fr30/xm-fr30.h, config/h8300/xm-h8300.h, config/i370/xm-i370.h, config/i370/xm-linux.h, config/i370/xm-mvs.h, config/i370/xm-oe.h, config/i386/xm-aix.h, config/i386/xm-i386.h, config/i386/xm-osf.h, config/i860/xm-i860.h, config/i960/xm-i960.h, config/ia64/xm-ia64.h, config/m32r/xm-m32r.h, config/m68k/xm-m68k.h, config/m88k/xm-m88k.h, config/mcore/xm-mcore.h, config/mips/xm-mips.h, config/mn10200/xm-mn10200.h, config/mn10300/xm-mn10300.h, config/ns32k/xm-ns32k.h, config/pa/xm-linux.h, config/pa/xm-pa.h, config/pa/xm-pa64hpux.h, config/pa/xm-pahpux.h, config/pa/xm-papro.h, config/pj/xm-pj.h, config/romp/xm-romp.h, config/rs6000/xm-beos.h, config/rs6000/xm-rs6000.h, config/rs6000/xm-sysv4.h, config/sh/xm-sh.h, config/sparc/xm-sparc.h, config/sparc/xm-sysv4.h, config/v850/xm-v850.h, config/vax/xm-vax.h, config/vax/xm-vms.h, config/we32k/xm-we32k.h: Do not define TRUE or FALSE. * config/i386/xm-aix.h, config/i386/xm-osf.h: Delete; made empty by above change. * config.gcc: Remove references to these files. * configure.in: Detect stdbool.h. * configure, config.in: Regenerate. * system.h: Include stddef.h here if available. Set HAVE__BOOL based on GCC_VERSION and __STDC_VERSION__. Then set up a sensible boolean type at the very end. * combine.c, cse.c, expr.c, fold-const.c, gensupport.c, f/com.c, config/mcore/mcore.c: Rename variables named 'true' and/or 'false'. * hash.h: Delete 'boolean' typedef and related #undefs. * f/proj.h: Delete 'bool' type. Don't include stddef.h here. * function.c, ggc-common.c, hash.h, hash.c, tlink.c, cp/decl.c, java/class.c, java/decl.c, java/java-tree.h: Replace all uses of 'boolean' with 'bool'. From-SVN: r40176
2001-02-27combine.c (known_cond): Do not reverse the condition when SMAX/UMAX is being ↵Jason Eckhardt1-1/+6
considered and the... * combine.c (known_cond): Do not reverse the condition when SMAX/UMAX is being considered and the condition is for equality or inequality. * testsuite/gcc.c-torture/execute/20010221-1.c: New test. From-SVN: r40077
2001-02-18optabs.c (expand_abs): Remove reference to HAVE_contitional_arithmetic.Lars Brinkhoff1-63/+0
* optabs.c (expand_abs): Remove reference to HAVE_contitional_arithmetic. * combine.c (simplify_set): Likewise. From-SVN: r39844
2001-02-13combine.c (UWIDE_SHIFT_LEFT_BY_BITS_PER_WORD): New macro.Alexandre Oliva1-4/+11
* combine.c (UWIDE_SHIFT_LEFT_BY_BITS_PER_WORD): New macro. (try_combine): Use it. From-SVN: r39624
2001-02-06combine.c (nonzero_bits, case PLUS): If pointers extend unsigned and this is ↵Richard Kenner1-1/+24
the sum of a pointer and a constant... * combine.c (nonzero_bits, case PLUS): If pointers extend unsigned and this is the sum of a pointer and a constant, we know the result did not overflow. (num_sign_bit_copies, case PLUS): Likewise. * explow.c (convert_memory_address): Remove opposite SUBREG. * function.c (instantiate_new_reg): New function (from common code). (instantiate_virtual_regs_1): Call it. For PLUS, handle if (plus (subreg (virt-reg) (const_int)) if pointers sign- or zero-extend. * simplify-rtx.c (simplify_unary_operation, case ZERO_EXTEND): If pointers extend unsigned, use inside of SUBREG. (simplify_unary_operation, case SIGN_EXTEND): Likewise, if sign extend. From-SVN: r39489
2001-01-30combine.c (try_combine): Fix SUBREG setting for HOST_BITS_PER_WIDE_INT >= 2 ↵Alexandre Oliva1-2/+25
* BITS_PER_WORD. * combine.c (try_combine): Fix SUBREG setting for HOST_BITS_PER_WIDE_INT >= 2 * BITS_PER_WORD. From-SVN: r39355
2001-01-29combine.c (if_then_else_cond): Pass the correct mode to operand_subword() ↵DJ Delorie1-2/+4
for constants. * combine.c (if_then_else_cond): Pass the correct mode to operand_subword() for constants. From-SVN: r39342
2001-01-28configure.in: Arrange to include defaults.h in [ht]config.h/tm.h.Kaveh R. Ghazi1-1/+0
* configure.in: Arrange to include defaults.h in [ht]config.h/tm.h. * Makefile.in: Remove all dependencies on defaults.h. * builtins.c: Don't include defaults.h. * c-common.c: Likewise. * c-decl.c: Likewise. * c-pragma.c: Likewise. * c-typeck.c: Likewise. * combine.c: Likewise. * i386.c: Likewise. * frame-ia64.c: Likewise. * cppexp.c: Likewise. * crtstuff.c: Likewise. * dbxout.c: Likewise. * dwarf2out.c: Likewise. * dwarfout.c: Likewise. * emit-rtl.c: Likewise. * except.c: Likewise. * expr.c: Likewise. * final.c: Likewise. * frame-dwarf2.c: Likewise. * libgcc2.c: Likewise. * optabs.c: Likewise. * profile.c: Likewise. * sdbout.c: Likewise. * toplev.c: Likewise. * tradcif.y: Likewise. * tree.c: Likewise. * varasm.c: Likewise. ch: * Makefile.in: Remove all dependencies on defaults.h. * decl.c: Don't include defaults.h. * timing.c: Likewise. cp: * Make-lang.in: Remove all dependencies on defaults.h. * call.c: Don't include defaults.h. * decl.c: Likewise. * decl2.c: Likewise. * except.c: Likewise. * pt.c: Likewise. * rtti.c: Likewise. * tree.c: Likewise. * typeck.c: Likewise. f: * Make-lang.in: Remove all dependencies on defaults.h. * com.c: Don't include defaults.h. java: * Make-lang.in: Remove all dependencies on defaults.h. * decl.c: Don't include defaults.h. * expr.c: Likewise. * parse.y: Likewise. From-SVN: r39308
2001-01-24combine.c (combine_simplify_rtx): If the modes are all VOIDmode, check the ↵DJ Delorie1-1/+5
original operand's mode also. * combine.c (combine_simplify_rtx): If the modes are all VOIDmode, check the original operand's mode also. * simplify-rtx.c (simplify_ternary_operation): Ditto. From-SVN: r39247
2001-01-17combine.c (try_combine): Don't set i3_subst_into_i2 for case of making new ↵Richard Kenner1-3/+5
double-word constant. * combine.c (try_combine): Don't set i3_subst_into_i2 for case of making new double-word constant. Revert last change: instead just test i3_subst_into_i2. From-SVN: r39094
2001-01-16combine.c (try_combine): If i3_subst_into_i2, properly check for I3 having ↵Richard Kenner1-1/+1
more than one SET. * combine.c (try_combine): If i3_subst_into_i2, properly check for I3 having more than one SET. From-SVN: r39077
2001-01-14combine.c (simplify_comparison): Don't change `code' when can't reverse ↵Geoffrey Keating1-5/+11
comparison. * combine.c (simplify_comparison): Don't change `code' when can't reverse comparison. From-SVN: r39007
2001-01-12combine.c (reversed_comparison): Fix typo in last patch.Andreas Jaeger1-3/+3
* combine.c (reversed_comparison): Fix typo in last patch. Check X for NULL. (combine_reversed_comparison_code): Make static to follow prototype declaration. Co-Authored-By: Jan Hubicka <jh@suse.cz> From-SVN: r38942
2001-01-11i386.c (ix86_comparison_operator, [...]): Convert fp comparison codes to ↵Jan Hubicka1-90/+86
integer before handling. * i386.c (ix86_comparison_operator, fcmov_comparison_operator, put_condition_code): Convert fp comparison codes to integer before handling. (ix86_expand_fp_compare): Postnote the fp comparison code converison to final. * i386.c (unsigned_comparison, no_comparison_operator): Kill. * i386-protos.h (no_comparison_operator): Kill. * i386.c (ix86_expand_fp_compare): Fix ordered/unordered confussion. * combine.c (REVERSIBLE_CC_MODE): Remove. (reversible_comparison_p): Remove. (combine_reversed_comparison_code): New. (reversed_comparison): New. (combine_simplify_rtx): Use combine_reversed_comparison_code/reversed_comparison instead of reversible_comparison_p. (simplify_if_then_else): Likewise. (simplify_set): Likewise. (simplify_logical): Likewise. (if_then_else_cond): Likewise. (known_cond): Likewise. (simplify_comparison): Likewise. From-SVN: r38930
2001-01-07combine.c (combine_simplify_rtx): Recognize the unordered compares.Jan Hubicka1-9/+27
* combine.c (combine_simplify_rtx): Recognize the unordered compares. (nonzero_bits): Likewise. (simplify_comparison): Likewise. (num_sign_bit_copies): Likewise; return more sane value depending on STORE_FLAG_VALUE. (known_cond): Do not assume EQ to be always true for equivalent operands. From-SVN: r38774
2001-01-03combine.c (simplify_shift_const): Even if we're sign-extracting...Alexandre Oliva1-4/+9
* combine.c (simplify_shift_const): Even if we're sign-extracting, don't discard an ASHIFTRT if we're shifting in a wider mode. From-SVN: r38648
2000-12-21* combine.c (distribute_notes): Handle REG_NON_LOCAL_GOTO notes.Graham Stott1-0/+9
From-SVN: r38422
2000-12-15combine.c (cant_combine_insn_p): Get around SUBREGs when determining ↵Jan Hubicka1-0/+4
hardreg<->reg moves. * combine.c (cant_combine_insn_p): Get around SUBREGs when determining hardreg<->reg moves. From-SVN: r38285
2000-12-01Further tweak cant_combine_insn_pBernd Schmidt1-38/+13
From-SVN: r37915
2000-12-01combine.c (try_combine): Disregard USEs when updating LOG_LINKS of ↵Alexandre Oliva1-1/+2
subsequent insns. * combine.c (try_combine): Disregard USEs when updating LOG_LINKS of subsequent insns. From-SVN: r37905
2000-11-29function.h (emit_status): Delete member regno_pointer_flag and rename ↵John David Anglin1-2/+2
regno_pointer_flag_length to... * function.h (emit_status): Delete member regno_pointer_flag and rename regno_pointer_flag_length to regno_pointer_align_length. Delete define for REGNO_POINTER_FLAG. * integrate.h (inline_remap): Delete member regno_pointer_flag. Add member x_regno_reg_rtx. * rtl.h (rtx_def): Use frame_related bit to indicate register is a pointer in REG expressions. Define REG_POINTER macro. * alias.c (find_base_value, find_base_term): Use REG_POINTER instead of REGNO_POINTER_FLAG. * combine.c (nonzero_bits, num_sign_bit_copies): Likewise. * emit-rtl.c (gen_reg_rtx): Use regno_pointer_align_length instead of regno_pointer_flag_length. Remove code which refers to regno_pointer_flag. (mark_reg_pointer): Use REG_POINTER. (free_emit_status): Remove code which refers to regno_pointer_flag. (init_emit, mark_emit_status): Likewise. * flow.c (dump_flow_info): Likewise. * function.c (preserve_temp_slots): Likewise. * integrate.c (expand_inline_function, copy_rtx_and_substitute): Use x_regno_reg_rtx instead of regno_pointer_flag for function pointer determination in map. * loop.c (strength_reduce, maybe_eliminate_biv_1): Use REG_POINTER. * predict.c (estimate_probability): Likewise. * regclass.c (record_address_regs, reg_scan_mark_refs): Likewise. * unroll.c (unroll_loop): Use x_regno_reg_rtx instead of regno_pointer_flag for function pointer determination in map. * convex.h (RTX_COSTS): Don't test regno_pointer_flag and use REG_POINTER. * pa.c (hppa_legitimize_address, emit_move_sequence, basereg_operand): Use REG_POINTER. (restore_unscaled_index_insn_codes): Revise comment. From-SVN: r37863
2000-11-26* combine.c (try_combine): Remove redundant test.Zack Weinberg1-16/+13
From-SVN: r37750
2000-11-24Avoid hard register combinationsBernd Schmidt1-7/+49
From-SVN: r37704
2000-11-07alias.c [...] (init_alias_analysis, [...]): Use memset () instead of bzero ().Joseph Myers1-9/+9
* alias.c (init_alias_analysis), calls.c (expand_call, emit_library_call_value_1), combine.c (init_reg_last_arrays), cse.c (new_basic_block), dbxout.c (dbxout_type), diagnostic.c (init_output_buffer, set_diagnostic_context), dwarf2out.c (equate_decl_number_to_die, build_abbrev_table), emit-rtl.c (init_emit_once), fold-const.c (mul_double, div_and_round_double), function.c (assign_parms), gcse.c (compute_can_copy, alloc_gcse_mem, alloc_reg_set_mem, record_one_set, compute_hash_table, compute_set_hash_table, compute_expr_hash_table), genattrtab.c (optimize_attrs), global.c (global_alloc, global_conflicts), haifa-sched.c (compute_trg_info, clear_units, schedule_block), integrate.c (initialize_for_inline, expand_inline_function), jump.c (thread_jumps), local-alloc.c (local_alloc), loop.c (combine_movables, count_loop_regs_set, load_mems_and_recount_loop_regs_set), print-tree.c (debug_tree), regclass.c (init_reg_sets, init_reg_sets_1, regclass, record_reg_classes, allocate_reg_info), reload.c (get_secondary_mem, remove_address_replacements, find_reloads), reload1.c (reload, set_initial_label_offsets, finish_spills, reload_as_needed, choose_reload_regs_init, reload_cse_simplify_operands), reorg.c (dbr_schedule), sbitmap.c (sbitmap_zero), simplify-rtx.c (simplify_plus_minus), ssa.c (rename_registers), stmt.c (expand_end_case), unroll.c (unroll_loop), varray.c (varray_grow), objc/objc-act.c: Use memset () instead of bzero (). ch: * actions.c (check_missing_cases), typeck.c (build_chill_slice, build_chill_cast): Use memset () instead of bzero (). cp: * class.c (duplicate_tag_error, build_vtbl_initializer), decl.c (push_binding_level), error.c (cp_tree_printer), pt.c (process_partial_specialization, tsubst_template_arg_vector), search.c (lookup_member): Use memset () instead of bzero (). java: * expr.c (note_instructions), jcf-io.c (find_class), jcf-parse.c (init_outgoing_cpool), lex.c (java_init_lex): Use memset () instead of bzero (). From-SVN: r37303
2000-11-07* combine.c (distribute_notes): Fix typo in last change.J"orn Rennecke1-1/+1
From-SVN: r37296
2000-11-07combine.c (recog_for_combine): Allocate uninitialized vector with rtvec_alloc.J"orn Rennecke1-4/+4
* combine.c (recog_for_combine): Allocate uninitialized vector with rtvec_alloc. * recog.c (apply_change_group): Likewise. From-SVN: r37285
2000-11-07flow.c (verify_local_live_at_start): Back out last change.J"orn Rennecke1-0/+29
* flow.c (verify_local_live_at_start): Back out last change. * combine.c (distribute_notes): When parts of a hard reg are neither set nor referenced in PLACE, search backwards for a place to put a REG_UNUSED note; if none found, ask for flow info refresh. From-SVN: r37284