[kaffe] CVS kaffe (robilad): Fix for gcc ICE when cross-compiling for xscale

Kaffe CVS cvs-commits at kaffe.org
Tue Oct 19 10:22:42 PDT 2004


PatchSet 5312 
Date: 2004/10/19 17:18:23
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
Fix for gcc ICE when cross-compiling for xscale

2004-10-19  Helmer Kraemer  <hkraemer at freenet.de>

        * config/arm/sysdepCallMethod.h
        (sysdepCallMethod) Use f0 only if we're not using
        soft-float. Fixes ICE in gcc.

        Reported by:  Jari Korva <jpkorva at iki.fi>

Members: 
	ChangeLog:1.2864->1.2865 
	config/arm/sysdepCallMethod.h:1.5->1.6 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.2864 kaffe/ChangeLog:1.2865
--- kaffe/ChangeLog:1.2864	Mon Oct 18 21:39:40 2004
+++ kaffe/ChangeLog	Tue Oct 19 17:18:23 2004
@@ -1,3 +1,11 @@
+2004-10-19  Helmer Kraemer  <hkraemer at freenet.de>
+
+	* config/arm/sysdepCallMethod.h
+	(sysdepCallMethod) Use f0 only if we're not using
+	soft-float. Fixes ICE in gcc.
+
+	Reported by:  Jari Korva <jpkorva at iki.fi>
+
 2004-10-18  Dalibor Topic  <robilad at kaffe.org>
 
 	* libraries/javalib/java/text/RuleBasedCollator.java:
Index: kaffe/config/arm/sysdepCallMethod.h
diff -u kaffe/config/arm/sysdepCallMethod.h:1.5 kaffe/config/arm/sysdepCallMethod.h:1.6
--- kaffe/config/arm/sysdepCallMethod.h:1.5	Mon Jun 28 19:05:20 2004
+++ kaffe/config/arm/sysdepCallMethod.h	Tue Oct 19 17:18:26 2004
@@ -39,7 +39,9 @@
     register int r1 asm("r1");
     register int r2 asm("r2");
     register int r3 asm("r3");
+#ifndef __SOFTFP__
     register double f0 asm("f0");
+#endif
 
   default:
     {
@@ -60,7 +62,10 @@
   case 0:
     asm volatile ("mov lr, pc\n"
 "                    mov pc, %3\n"
-                  : "=r" (r0), "=r" (r1), "=f" (f0)
+                  : "=r" (r0), "=r" (r1)
+#ifndef __SOFTFP__
+		                        , "=f" (f0)
+#endif
                   : "r" (call->function),
                     "0" (r0), "1" (r1), "r" (r2), "r" (r3)
                   : "ip", "lr");
@@ -70,11 +75,20 @@
       break;
 
     case 'D':
+#ifdef __SOFTFP__
+      (&call->ret->i)[1] = r1;
+      (&call->ret->i)[0] = r0;
+#else
       call->ret->d = (double) f0;
+#endif
       break;
 
     case 'F':
+#ifdef __SOFTFP__
+      call->ret->i = r0;
+#else
       call->ret->f = (float) f0;
+#endif
       break;
  
     case 'J':




More information about the kaffe mailing list