Index: /branches/ia32/compiler/X86/x862.lisp
===================================================================
--- /branches/ia32/compiler/X86/x862.lisp	(revision 9585)
+++ /branches/ia32/compiler/X86/x862.lisp	(revision 9586)
@@ -9240,10 +9240,13 @@
     (when vreg
       (cond ((eq resultspec :void) (<- nil))
-	    ;; the ffcall subprim copies st[0] into fp0 for us
-	    ;; so that we don't have to worry about the x87 fpu stack
+	    ;; Floating-point results are returned on the x87 stack.
 	    ((eq resultspec :double-float)
-	     (<- ($ x8632::fp0 :class :fpr :mode :double-float)))
+	     (let ((fpreg ($ x8632::fp0 :class :fpr :mode :double-float)))
+	       (! fp-stack-to-double fpreg)
+	       (<- fpreg)))
 	    ((eq resultspec :single-float)
-	     (<- ($ x8632::fp0 :class :fpr :mode :single-float)))
+	     (let ((fpreg ($ x8632::fp0 :class :fpr :mode :single-float)))
+	       (! fp-stack-to-single fpreg)
+	       (<- fpreg)))
 	    ((eq resultspec :unsigned-doubleword)
 	     (ensuring-node-target (target vreg)
