diff --git a/compiler/mips/c-call.lisp b/compiler/mips/c-call.lisp
index 1d0a47dd5e110a4a7bc74b0862eff0d790fe8e62..fdf5cfa3f15760a5f8df294727d4144125c2fbba 100644
--- a/compiler/mips/c-call.lisp
+++ b/compiler/mips/c-call.lisp
@@ -7,11 +7,11 @@
 ;;; Scott Fahlman or slisp-group@cs.cmu.edu.
 ;;;
 (ext:file-comment
-  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/c-call.lisp,v 1.10 1992/03/22 17:30:01 wlott Exp $")
+  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/c-call.lisp,v 1.11 1992/03/27 23:25:38 wlott Exp $")
 ;;;
 ;;; **********************************************************************
 ;;;
-;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/c-call.lisp,v 1.10 1992/03/22 17:30:01 wlott Exp $
+;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/c-call.lisp,v 1.11 1992/03/27 23:25:38 wlott Exp $
 ;;;
 ;;; This file contains the VOPs and other necessary machine specific support
 ;;; routines for call-out to C.
@@ -186,14 +186,26 @@
 (define-vop (alloc-number-stack-space)
   (:info amount)
   (:results (result :scs (sap-reg any-reg)))
+  (:temporary (:scs (unsigned-reg) :to (:result 0)) temp)
   (:generator 0
     (unless (zerop amount)
-      (inst addu nsp-tn nsp-tn (- (logandc2 (+ amount 7) 7))))
+      (let ((delta (logandc2 (+ amount 7) 7)))
+	(cond ((< delta (ash 1 15))
+	       (inst subu nsp-tn delta))
+	      (t
+	       (inst li temp delta)
+	       (inst subu nsp-tn temp)))))
     (move result nsp-tn)))
 
 (define-vop (dealloc-number-stack-space)
   (:info amount)
   (:policy :fast-safe)
+  (:temporary (:scs (unsigned-reg) :to (:result 0)) temp)
   (:generator 0
     (unless (zerop amount)
-      (inst addu nsp-tn nsp-tn (logandc2 (+ amount 7) 7)))))
+      (let ((delta (logandc2 (+ amount 7) 7)))
+	(cond ((< delta (ash 1 15))
+	       (inst addu nsp-tn delta))
+	      (t
+	       (inst li temp delta)
+	       (inst addu nsp-tn temp)))))))
diff --git a/compiler/sparc/c-call.lisp b/compiler/sparc/c-call.lisp
index 0488e0f06c2a6258474a3828ad9a97d22b1d0cf2..ebfcfb496cffb959ad20b48b9bae4093a2011e26 100644
--- a/compiler/sparc/c-call.lisp
+++ b/compiler/sparc/c-call.lisp
@@ -7,7 +7,7 @@
 ;;; Scott Fahlman or slisp-group@cs.cmu.edu.
 ;;;
 (ext:file-comment
-  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/sparc/c-call.lisp,v 1.7 1992/03/22 17:30:14 wlott Exp $")
+  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/sparc/c-call.lisp,v 1.8 1992/03/27 23:26:05 wlott Exp $")
 ;;;
 ;;; **********************************************************************
 ;;;
@@ -148,15 +148,26 @@
 (define-vop (alloc-number-stack-space)
   (:info amount)
   (:results (result :scs (sap-reg any-reg)))
+  (:temporary (:scs (unsigned-reg) :to (:result 0)) temp)
   (:generator 0
     (unless (zerop amount)
-      (inst add nsp-tn nsp-tn (- (logandc2 (+ amount 7) 7))))
-    (unless (location= nsp-tn result)
-      (inst add result nsp-tn number-stack-displacement))))
+      (let ((delta (logandc2 (+ amount 7) 7)))
+	(cond ((< delta (ash 1 12))
+	       (inst sub nsp-tn delta))
+	      (t
+	       (inst li temp delta)
+	       (inst sub nsp-tn temp)))))
+    (inst add result nsp-tn number-stack-displacement)))
 
 (define-vop (dealloc-number-stack-space)
   (:info amount)
   (:policy :fast-safe)
+  (:temporary (:scs (unsigned-reg) :to (:result 0)) temp)
   (:generator 0
     (unless (zerop amount)
-      (inst add nsp-tn nsp-tn (logandc2 (+ amount 7) 7)))))
+      (let ((delta (logandc2 (+ amount 7) 7)))
+	(cond ((< delta (ash 1 12))
+	       (inst add nsp-tn delta))
+	      (t
+	       (inst li temp delta)
+	       (inst add nsp-tn temp)))))))