]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Fix for proprietary testcase that fails at -m5-compact...
authorJames E Wilson <wilson@tuliptree.org>
Sat, 8 Mar 2003 00:21:23 +0000 (16:21 -0800)
committerJim Wilson <wilson@gcc.gnu.org>
Sat, 8 Mar 2003 00:21:23 +0000 (16:21 -0800)
Fix for proprietary testcase that fails at -m5-compact
����������������* config/sh/sh.h (HARD_REGNO_NREGS): Round up the XD register count.

From-SVN: r63963

gcc/ChangeLog
gcc/config/sh/sh.h

index 0802120fbfd14f33637e3becb97bfbc88fca1d88..34e2ada85ca2aca1d957c1ef67b067b1262f3788 100644 (file)
@@ -1,3 +1,7 @@
+2003-03-07  James E Wilson  <wilson@tuliptree.org>
+
+        * config/sh/sh.h (HARD_REGNO_NREGS): Round up the XD register count.
+
 2003-03-07  Geoffrey Keating  <geoffk@apple.com>
 
        * objc/lang-specs.h (objective-c-header): Use .gch not .pch;
index 49503d180efe5946470916b7358ebdd54f5e92a9..c2f3160dfc511f5af3e9864b2671f6a1374744f0 100644 (file)
@@ -937,10 +937,10 @@ extern char sh_additional_register_names[ADDREGNAMES_SIZE] \
 
 #define HARD_REGNO_NREGS(REGNO, MODE) \
    (XD_REGISTER_P (REGNO) \
-    ? (GET_MODE_SIZE (MODE) / (2 * UNITS_PER_WORD)) \
+    ? ((GET_MODE_SIZE (MODE) + (2*UNITS_PER_WORD - 1)) / (2*UNITS_PER_WORD)) \
     : (TARGET_SHMEDIA && FP_REGISTER_P (REGNO)) \
     ? ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD/2 - 1) / (UNITS_PER_WORD/2)) \
-    : ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD - 1) / UNITS_PER_WORD)) \
+    : ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD - 1) / UNITS_PER_WORD))
 
 /* Value is 1 if hard register REGNO can hold a value of machine-mode MODE.
    We can allow any mode in any general register.  The special registers