From 574c75a3b4ce0f087201efb26f893df20ac3a887 Mon Sep 17 00:00:00 2001 From: Michael Meissner Date: Tue, 30 Mar 1993 21:50:50 +0000 Subject: [PATCH] fkx fix CLASS_MAX_NREGS to reflect -mfloat64 and -msoft-float. From-SVN: r3931 --- gcc/config/mips/mips.h | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/gcc/config/mips/mips.h b/gcc/config/mips/mips.h index 2e67e635918..f3a2ead7bea 100644 --- a/gcc/config/mips/mips.h +++ b/gcc/config/mips/mips.h @@ -645,7 +645,7 @@ while (0) /* Print subsidiary information on the compiler version in use. */ -#define MIPS_VERSION "[AL 1.1, MM 36]" +#define MIPS_VERSION "[AL 1.1, MM 37]" #ifndef MACHINE_TYPE #define MACHINE_TYPE "BSD Mips" @@ -1454,10 +1454,15 @@ extern enum reg_class mips_char_to_class[]; /* Return the maximum number of consecutive registers needed to represent mode MODE in a register of class CLASS. */ +#define CLASS_UNITS(mode, num) \ + ((GET_MODE_SIZE (mode) + ((num) * UNITS_PER_WORD) + 1) / ((num) * UNITS_PER_WORD)) + #define CLASS_MAX_NREGS(CLASS, MODE) \ - ((((MODE) == DFmode) || ((MODE) == SFmode)) ? 2 \ - : ((MODE) == VOIDmode)? ((CLASS) == FP_REGS ? 2 : 1) \ - : ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD - 1) / UNITS_PER_WORD)) + (((CLASS) == FP_REGS && TARGET_FLOAT64) \ + ? CLASS_UNITS (MODE, 2) \ + : (((CLASS) == FP_REGS) \ + ? (2*CLASS_UNITS (MODE, 1)) \ + : CLASS_UNITS (MODE, 1))) /* If defined, this is a C expression whose value should be nonzero if the insn INSN has the effect of mysteriously -- 2.30.2