Jeff Law [Wed, 31 Mar 1993 08:48:22 +0000 (01:48 -0700)]
pa.c (output_cbranch): New function.
* pa.c (output_cbranch): New function. Given the operands of the
branch, possible nullification, length of the branch, possible branch
negation, and the branch insn itself, return the output template for
the desired conditional branch.
(output_bb): Likewise, but for branch on bit.
Richard Stallman [Wed, 31 Mar 1993 05:50:11 +0000 (05:50 +0000)]
(real_value_truncate): If REAL_ARITHMETIC, replace by routine of same name in real.c.
(real_value_truncate): If REAL_ARITHMETIC, replace
by routine of same name in real.c.
target_isinf, target_isnan, target_negative): Likewise.
(const_binop): Delete `register' from decls using REAL_VALUE_TYPE.
(fold_convert): Use REAL_VALUE_TO_INT.
Richard Stallman [Wed, 31 Mar 1993 05:48:38 +0000 (05:48 +0000)]
(operand_subword): Use REAL_VALUE_TO_TARGET_SINGLE to convert to target float.
If REAL_ARITHMETIC is defined, let real.c handle incompatible host
and target floating point bit patterns.
(init_emit_once): Add machine_mode argument to REAL_VALUE_ATOF.
Richard Stallman [Wed, 31 Mar 1993 05:44:03 +0000 (05:44 +0000)]
(yylex): Convert real decimal constants directly to the precision specified by the letter at the end of the number.
(yylex): Convert real decimal constants directly
to the precision specified by the letter at the end of the number.
Pass mode arg to REAL_VALUE_ATOF to specify precision.
Move the "out of range of double" error check.
Richard Stallman [Wed, 31 Mar 1993 05:39:37 +0000 (05:39 +0000)]
If REAL_ARITHMETIC is defined or if LONG_DOUBLE_TYPE_SIZE is 96...
If REAL_ARITHMETIC is defined or if LONG_DOUBLE_TYPE_SIZE
is 96, then define REAL_VALUE_ macros to invoke functions in real.c.
(REAL_VALUE_RNDZINT, REAL_VALUE_UNSIGNED_RNDZINT):
New macros truncate toward zero to integer value but
return REAL_VALUE_TYPE.
(REAL_VALUE_TO_DECIMAL): New macro defaults to
fprintf if no REAL_ARITHMETIC, otherwise uses real.c for
binary to decimal conversion. Used in ASM_OUTPUT_ macros.
Richard Kenner [Tue, 30 Mar 1993 20:37:29 +0000 (15:37 -0500)]
(record_dead_and_set_regs): Record death of all hard regs when a multi-reg object in hard regs dies.
(record_dead_and_set_regs): Record death of all hard regs when a multi-reg
object in hard regs dies.
(move_deaths): Handle the case when we only have to move part of a
multi-register death note.
Richard Kenner [Tue, 30 Mar 1993 20:29:35 +0000 (15:29 -0500)]
(extendtab, fixtab, fixtrunctab, floattab): Not static.
(init_extends, init_fixtab, init_floattab): Deleted.
(init_optabs): Move active stuff from above functions in.
Delete filling of optabs.
Call init_all_optabs.
Richard Kenner [Mon, 29 Mar 1993 21:16:35 +0000 (16:16 -0500)]
Add prototypes for all functions defined in file.
Change a few occurrences of RTX_CODE to enum rtx_code for consistency.
(merge_trees): Add casts of args to mybcopy.
(write_tree_1): Now static.
(fatal): Always called with one arg, so define that way.
Richard Kenner [Mon, 29 Mar 1993 11:28:45 +0000 (06:28 -0500)]
Add missing declarations for external functions in reload.c, reload1.c,
and caller-save.c.
(reload_strict_low, reload_needed_for_multiple, reload_needed_for): Deleted.
(reload_opnum): New array.
(enum reload_type): Renamed from reload_when_needed and expanded to include
more reload types.
(reload_n_operands): New variable.
Richard Kenner [Mon, 29 Mar 1993 11:27:52 +0000 (06:27 -0500)]
Add prototypes for all static functions and clean up some definitions.
(struct decompose): Move to before function declarations.
(secondary_memlocs_elim): One per operand, not per mode.
(get_secondary_mem): Accept and use reload description (opnum and type).
(push_reload): Accept and use new reload description instead of old NEEDED_FOR.
Define two new macros: MERGEABLE_RELOADS and MERGE_TO_OTHER.
Use these macros to see if reloads can be merged and how to do it.
(transfer_replacements): New function.
(combine_reloads): Refine when we can combine reloads.
(find_reloads): Use new method of tracking what a reload is for.
When we make a CLOBBER insn, do so with DImode.
Merge cases of making optional reloads, avoid making output-only optional
reloads, refine when we may not make in-out optional reloads, and make an
optional reload for a pair of matching operands.
(find_reloads_toplev, find_reloads_address{,_1, part}): Accept and use reload
description.
(forget_volatility): Delete long-obsolete function.
Richard Kenner [Mon, 29 Mar 1993 11:24:36 +0000 (06:24 -0500)]
Add prototypes for static functions.
(REGISTER_MOVE_COST, MEMORY_MOVE_COST): Include default definitions.
(reload): Count number of registers needed for insn using new reload type
information.
If mode of insn is DImode, don't change it.
Refine the way we handle conflict with the return value register.
Don't try to account for needs already covered by previously spilled
registers; instead, put them back in the front of potential_reload_regs and
let them be allocated again.
(order_regs_for_reload): Don't restrict regs explicitly used if we have
SMALL_REGISTER_CLASSES defined.
(reload_as_needed): Don't need to deactivate optional reloads ever; if they
inherit, it must have been safe.
Call merge_assigned_reloads if SMALL_REGISTER_CLASSES.
(reload_reg_used_*): Refine our tracking of reload reg usage by defining more
of these HARD_REG_SETs.
(mark_reload_reg_in_use, reload_reg_free_p): Rework to use new method of
describing where a reload register is used.
(reload_reg_free_before_p, reload_reg_reaches_end_p): Likewise.
(allocate_reload_reg): Pass new reload descriptions.
(choose_reload_regs): Likewise.
Save and restore the new HARD_REG_SETs.
Remove now-redundant code to prevent conflicts.
(merge_assigned_reloads): New function.
(emit_reload_insns): Output each reload type into its own sequence, then
output the sequences in the proper order.
Put our output reloads after a CLOBBER made by find_reloads.
Pass ALL_REGS to find_equiv_regs; nothing special about GENERAL_REGS.
Don't use an old equivalence if doing so would be more expensive.
Clean up tracking of values still in reload regs using reload description
info to see if the reload reaches the end of the insn.
(gen_input_reload): Pass reload description and emit insns to end of current
sequence.
(inc_for_reload): Return void; no longer need INSN as operand.
Emit insns to end of current sequence.
Jeff Law [Sun, 28 Mar 1993 23:56:26 +0000 (16:56 -0700)]
pa.md (smin, [...]): New patterns.
* pa.md (smin, umin, smax, umax): New patterns.
* pa.md (cbranch define_delay): Enable nullification of
conditional branch delay slots (based upon branch direction).
(conditional branch patterns): Call output_cbranch to get the
correct output template. Long conditional branches with an
annulled delay slot have a length of 3.
(branch on bit patterns): Call output_bb to get the correct
output template. Long branches with an annulled delay slot have
a length of 3.
(decrement and branch pattern): Handle nullification of long
Jeff Law [Sun, 28 Mar 1993 21:25:08 +0000 (14:25 -0700)]
reorg.c (ANNUL_IFTRUE_SLOTS, [...]): Add new flags variable to these dummy macros.
* reorg.c (ANNUL_IFTRUE_SLOTS, ANNUL_IFFALSE_SLOTS): Add new
flags variable to these dummy macros.
(get_jump_flags): New function.
(optimize_skip): Get jump flags information from the delay insn.
(steal_delay_list_from_target): Get jump flags information from the
delay insn and the label of the trial jump.
(steal_delay_list_from_fallthrough): Get jump flags information
from the delay insn.
(try_merge_delay_insns): Likewise.
(fill_simple_delay_slots): Likewise.
(fill_slots_from_thread): Likewise.
(make_return_insn): Likewise.