if (! TEST_HARD_REG_BIT (not_usable, regno)
&& ! TEST_HARD_REG_BIT (used_by_other_reload, regno)
- && HARD_REGNO_MODE_OK (regno, rl->mode))
+ && targetm.hard_regno_mode_ok (regno, rl->mode))
{
int this_cost = spill_cost[regno];
int ok = 1;
static int
set_reload_reg (int i, int r)
{
- /* regno is 'set but not used' if HARD_REGNO_MODE_OK doesn't use its first
- parameter. */
- int regno ATTRIBUTE_UNUSED;
+ int regno;
rtx reg = spill_reg_rtx[i];
if (reg == 0 || GET_MODE (reg) != rld[r].mode)
/* Detect when the reload reg can't hold the reload mode.
This used to be one `if', but Sequent compiler can't handle that. */
- if (HARD_REGNO_MODE_OK (regno, rld[r].mode))
+ if (targetm.hard_regno_mode_ok (regno, rld[r].mode))
{
machine_mode test_mode = VOIDmode;
if (rld[r].in)
to reload from or into have modes which are valid for this
reload register. Otherwise the reload insns would be invalid. */
if (! (rld[r].in != 0 && test_mode != VOIDmode
- && ! HARD_REGNO_MODE_OK (regno, test_mode)))
+ && !targetm.hard_regno_mode_ok (regno, test_mode)))
if (! (rld[r].out != 0
- && ! HARD_REGNO_MODE_OK (regno, GET_MODE (rld[r].out))))
+ && !targetm.hard_regno_mode_ok (regno, GET_MODE (rld[r].out))))
{
/* The reg is OK. */
last_spill_reg = i;
rld[r].when_needed, rld[r].in,
rld[r].out, r, 1)))
&& TEST_HARD_REG_BIT (reg_class_contents[rclass], regnum)
- && HARD_REGNO_MODE_OK (regnum, rld[r].mode)
+ && targetm.hard_regno_mode_ok (regnum, rld[r].mode)
/* Look first for regs to share, then for unshared. But
don't share regs used for inherited reloads; they are
the ones we want to preserve. */
if (reg_reloaded_contents[i] == regno
&& TEST_HARD_REG_BIT (reg_reloaded_valid, i)
- && HARD_REGNO_MODE_OK (i, rld[r].mode)
+ && targetm.hard_regno_mode_ok (i, rld[r].mode)
&& (TEST_HARD_REG_BIT (reg_class_contents[(int) rclass], i)
/* Even if we can't use this register as a reload
register, we might use it for reload_override_in,
equiv = 0;
}
- if (equiv != 0 && ! HARD_REGNO_MODE_OK (regno, rld[r].mode))
+ if (equiv != 0
+ && !targetm.hard_regno_mode_ok (regno, rld[r].mode))
equiv = 0;
/* We found a register that contains the value we need.
continue;
if (GET_MODE (reg) != new_mode)
{
- if (!HARD_REGNO_MODE_OK (regno, new_mode))
+ if (!targetm.hard_regno_mode_ok (regno, new_mode))
continue;
if (hard_regno_nregs[regno][new_mode]
> hard_regno_nregs[regno][GET_MODE (reg)])