Commit 894113c3 by Richard Sandiford Committed by Richard Sandiford

mips.c (mips_class_max_nregs): Check that the mode is OK for ST_REGS and FP_REGS…

mips.c (mips_class_max_nregs): Check that the mode is OK for ST_REGS and FP_REGS before taking those classes...

gcc/
	* config/mips/mips.c (mips_class_max_nregs): Check that the mode is
	OK for ST_REGS and FP_REGS before taking those classes into account.

From-SVN: r177931
parent 9e187b31
2011-08-20 Richard Sandiford <rdsandiford@googlemail.com>
* config/mips/mips.c (mips_class_max_nregs): Check that the mode is
OK for ST_REGS and FP_REGS before taking those classes into account.
2011-08-20 Richard Sandiford <rdsandiford@googlemail.com>
* config/mips/mips.c (mips_reorg_process_insns): Check for jumps
before checking for annulled branches.
......
......@@ -10630,12 +10630,14 @@ mips_class_max_nregs (enum reg_class rclass, enum machine_mode mode)
COPY_HARD_REG_SET (left, reg_class_contents[(int) rclass]);
if (hard_reg_set_intersect_p (left, reg_class_contents[(int) ST_REGS]))
{
size = MIN (size, 4);
if (HARD_REGNO_MODE_OK (ST_REG_FIRST, mode))
size = MIN (size, 4);
AND_COMPL_HARD_REG_SET (left, reg_class_contents[(int) ST_REGS]);
}
if (hard_reg_set_intersect_p (left, reg_class_contents[(int) FP_REGS]))
{
size = MIN (size, UNITS_PER_FPREG);
if (HARD_REGNO_MODE_OK (FP_REG_FIRST, mode))
size = MIN (size, UNITS_PER_FPREG);
AND_COMPL_HARD_REG_SET (left, reg_class_contents[(int) FP_REGS]);
}
if (!hard_reg_set_empty_p (left))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment