(left_shift_overflows, same_sign, overflow_sum_sign): New macros.
(add_double, div_and_round_double, lshift_double, mul_double):
(neg_double, const_binop, fold): Check for signed integer overflow.
Propagate overflow flags from operands to result.
(const_binop, fold_convert): Use pedwarn for overflow warnings.
Say `constant expression', not `constant folding', for user's sake.
(install): Add semicolon to make an empty command.
(SYSTEM_HEADER_DIR): New variable.
(xlimits.h): New target, broken out from install-limits-h.
Look in SYSTEM_HEADER_DIR for system's limits.h.
(start.encap): Dep on xlimits.h.
(install-limits-h): Install xlimits.h already made.
If we find a link pointing to ., make a similar link to ., not a link to an absolute name.
If we find a link pointing to ., make a similar
link to ., not a link to an absolute name.
(stdio.h): Change stdio.h to use stdarg.h to get va_list.
When link points to a dir $dirname outside $INPUT,
copy that dir into $LIB/root$dirname. Translate the link itself
into a link to that new dir. Make a file DONE in each treetop dir
so no treetop is scanned twice. Improve progress messages.
(default_compilers): Add missing comma between strings, so that traditional compilers can compile gcc.c.
(default_compilers): Add missing comma between strings, so
that traditional compilers can compile gcc.c.
(main): Don't pass strcpy or strlen a NULL pointer if some of the
spec strings in default_compilers are NULL.
(validate_all_switches): Don't dereference a NULL pointer if some of
the spec strings in defalut_compilers are NULL.
Jeff Law [Wed, 2 Sep 1992 23:08:44 +0000 (17:08 -0600)]
caller-save.c (init_caller_save): If we were unable to find a simple insn which meets all its constraints to save...
* caller-save.c (init_caller_save): If we were unable to
find a simple insn which meets all its constraints to save
and restore with a single insn in a mode, then set
regno_save_mode to VOIDmode to insure that this mode is never
used to caller-save the current register.
Richard Kenner [Wed, 2 Sep 1992 10:37:38 +0000 (06:37 -0400)]
(make_compound_operation...
(make_compound_operation, case ASHIFTRT): Add new code to
handle (ashiftrt (neg (ashift FOO C1) C2)) just like we currently
handle (ashiftrt (OP (ashiftrt FOO C1) C2) C2).
(expand_fixup): Create a BLOCK node (via pushlevel/poplevel) to represent an...
(expand_fixup): Create a BLOCK node (via pushlevel/poplevel)
to represent an artificial scope containing all of the fixup code.
Also emit NOTE_INSN_BLOCK_BEG/NOTE_INSN_BLOCK_END for that block.
(fixup_gotos): Declaration of NEWBLOCK deleted.
Call `set_block' to use the BLOCK made in expand_fixup.
Deleted code to insert NEWBLOCK into block hierarchy.
Jim Wilson [Tue, 1 Sep 1992 01:26:25 +0000 (18:26 -0700)]
(sched_analyze_2): Remove an explicit dependence between an insn that uses CC0 and the immediately previous insn.
(sched_analyze_2): Remove an explicit dependence between an insn
that uses CC0 and the immediately previous insn.
(SCHED_GROUP_P represents the dependence.)
(schedule_block): Only check sets_cc0_p on an insn.
Richard Stallman [Mon, 31 Aug 1992 20:00:19 +0000 (20:00 +0000)]
(struct compiler): spec field is now array of 4 elements.
(read_specs): Clear the entire new element of compilers.
(lookup_compiler): Copy all of spec array. Check element 0 for @.
(main): Concatenate all elements of compiler spec.
(validate_all_switches): Validate from all elements of compiler spec.
(default_compilers): Split CPP commands into separate strings.
Jeff Law [Mon, 31 Aug 1992 14:05:07 +0000 (08:05 -0600)]
caller-save.c (restore_referenced_regs): When restoring a referenced hard register...
* caller-save.c (restore_referenced_regs): When restoring a
referenced hard register, use CEIL instead of truncating
divide to determine the maximum number of registers to
restore.
(insert_save_restore): Document maxrestore parameter.
(CEIL): Define.
(TARGET_SWITCHES): Add "no-80387", "no-soft-float", "fp-ret-in-387", and
"no-fp-ret-in-387".
Change no* switches to no-*.
(CONDITIONAL_REGISTER_USAGE): Make 387 regs fixed if the 387 is not used
at all.
(REG_CLASS_FROM_LETTER): Constraint letters 'f', 't' and 'u' are NO_REGS
if the 387 is not used.
(TRAMPOLINE_TEMPLATE): Use GEN_INT to generate const_int rtx.
(TARGET_DEFAULT,VALUE_REGNO,FUNCTION_VALUE_REGNO): Moved from unix target files (aix386.h...
(TARGET_DEFAULT,VALUE_REGNO,FUNCTION_VALUE_REGNO): Moved from unix target
files (aix386.h, i386gas.h, i386sun.h, i386v.h, i386v4.h, i386vgas.h,
seq386.h).
(TARGET_DEFAULT): Make TARGET_IEEE_FP default on.
(VALUE_REGNO): Test for MODE_FLOAT instead of specific modes.
(VALUE_REGNO,FUNCTION_VALUE_REGNO): MODE_FLOAT return reg depends on
TARGET_FLOAT_RETURNS_IN_80387.
Richard Stallman [Sat, 29 Aug 1992 03:21:11 +0000 (03:21 +0000)]
(adjust_copied_decl_tree): New function.
(save_for_inline_copying): When making copies of NOTE_INSN_BLOCK_END
notes, stash a "forwarding" pointer in the original to point to the
copy. Also, when all BLOCKs & insns for a function have been copied,
call `adjust_copied_decl_tree' to fixup the end_note pointers in the
copied BLOCKs.
Richard Stallman [Sat, 29 Aug 1992 03:20:43 +0000 (03:20 +0000)]
(last_block_end_note): New variable.
(remember_end_note): New function.
(expand_end_bindings): Save NOTE_INSN_BLOCK_END in last_block_end_note.
(struct goto_fixup): New field context.
(fixup_cleanups): Function deleted.
(fixup_gotos): Put the fixup in a block, and put that block
into its proper place. Use sequences, not reorder_insns.
(all patterns): Use GEN_INT instead of gen_rtx to get const_ints.
Avoid double-negative "! NON_*" constructs for clarity.
Pass NULL_PTR as null parameter instead of 0.
(sqrtM2): Patterns are only valid if IEEE FP or -ffast-math.
(sinM2,cosM2): New patterns.
(zero_extract test): New pattern.
(record_reg_life_pat): Rewrite to handle any sort of pattern.
(record_reg_life): Change interface to record_reg_life_pat.
(stack_reg_life_analysis): Don't assume that MODE_FLOAT values are
always returned in a float reg.
(subst_stack_regs_pat): Add support for sin and cos insns.
Tom Wood [Wed, 26 Aug 1992 22:19:37 +0000 (22:19 +0000)]
Enhance to fill the last delay slot of a call with an unconditional jump.
Enhance to fill the last delay slot of a call with an
unconditional jump.
(fill_simple_delay_slots): Look for the case of a call/branch
first. If this applies, record the jump as `last_delay_insn'.
Later, don't look for additional delay insns if the last one has
alreay been filled.
(mark_target_live_regs): A sequence may end in an unconditional
branch.
Jeff Law [Wed, 26 Aug 1992 19:41:20 +0000 (13:41 -0600)]
Major rework to have caller-saves emit load/store double insns when...
Major rework to have caller-saves emit load/store double insns when
possible and to avoid useless resaving of registers restored for
source accesses only.
* caller-save.c (toplevel): All arrays are multi-dimensional to
hold information for multiple save/restore insns. New variable
hard_regs_need_restore.
(choose_hard_reg_mode): New argument `nregs' indicating how many
hard registers are desired. All callers changed.
(init_caller_save): Change initialization to handle multiple
register saves. A call-used register can not be live across
if we can not find a single register mode to save it in.
(multiple register saves are optional)
(init_save_areas): Change initialization of regno_save_mem to
handle multiple register saves.
(setup_save_areas): Allocate space for consecutive hard registers
in aligned consecutive memory locations. When allocating space
for consecutive hard registers, also initialize regno_save_mem
for each hard register stored as a single word.
(save_call_clobbered_regs): Initialize hard_regs_need_restore.
Set hard_regs_need_restore to hard_regs_saved after crossing
a call. Also recompute n_regs_saved. At the end of a basic block
we need only restore registers in hard_regs_need_restore.
(set_reg_live, clear_reg_live): Do the right thing for
hard_regs_need_restore and hard_regs_saved.
(restore_referenced_regs): Just return if X is a clobber.
Test hard_regs_need_restore to determine when to restore a hard
register from the save area.
(insert_save_restore): Now returns the number of extra registers
saved/restored. New argument `maxrestore' which constrains how
many hard registers should be restored. All callers changed.
Do stores of consecutive registers with double store insns if
possible. Else do them with single word insns. Likewise for
loads, except constrained by maxrestore. Set hard_regs_saved
and hard_regs_need_restore appropriately to minimize useless
saves into the save area. Test against hard_regs_need_restore
when trying to restore multiple regs and similarly test against
hard_regs_saved when storing multiple regs.
Richard Stallman [Wed, 26 Aug 1992 06:03:24 +0000 (06:03 +0000)]
(poplevel): Store into BLOCK iff it is non-null.
(current_block): New function.
(struct binding_level): New field this_block.
(poplevel): Use this_block if nonzero, rather than making new BLOCK.
(insert_block, delete_block): New functions.
Jim Wilson [Wed, 26 Aug 1992 03:24:03 +0000 (20:24 -0700)]
(float*, fix*): Rewrite to match hardware...
(float*, fix*): Rewrite to match hardware; take/put
integer input/output from/to fp register instead of memory or
general register. Delete 6 now obsolete combiner patterns.