diff --git a/compiler/mips/call.lisp b/compiler/mips/call.lisp index ff7cff347c677d53915ff6ebccb3ad3e91d24703..63a311600d4444a1836d1f5171a95b4a5a84c36d 100644 --- a/compiler/mips/call.lisp +++ b/compiler/mips/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/call.lisp,v 1.43 1992/04/01 19:56:11 wlott Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/call.lisp,v 1.44 1992/04/27 20:03:15 wlott Exp $") ;;; ;;; ********************************************************************** ;;; -;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/call.lisp,v 1.43 1992/04/01 19:56:11 wlott Exp $ +;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/call.lisp,v 1.44 1992/04/27 20:03:15 wlott Exp $ ;;; ;;; This file contains the VM definition of function call for the MIPS. ;;; @@ -915,6 +915,29 @@ default-value-8 ;;;; Unknown values return: +;;; Return a single value using the unknown-values convention. +;;; +(define-vop (return-single) + (:args (old-fp :scs (any-reg)) + (return-pc :scs (descriptor-reg)) + (value)) + (:ignore value) + (:temporary (:scs (interior-reg)) lip) + (:vop-var vop) + (:generator 6 + ;; Clear the number stack. + (trace-table-entry trace-table-function-epilogue) + (let ((cur-nfp (current-nfp-tn vop))) + (when cur-nfp + (inst addu nsp-tn cur-nfp + (bytes-needed-for-non-descriptor-stack-frame)))) + ;; Clear the control stack, and restore the frame pointer. + (move csp-tn cfp-tn) + (move cfp-tn old-fp) + ;; Out of here. + (lisp-return return-pc lip :offset 2) + (trace-table-entry trace-table-normal))) + ;;; Do unknown-values return of a fixed number of values. The Values are ;;; required to be set up in the standard passing locations. Nvals is the diff --git a/compiler/sparc/call.lisp b/compiler/sparc/call.lisp index aab999a77c929cd01db52f6ff631876a4da0e6d6..eb47ee8f1c972fd396892224ee5fda62c9ad5319 100644 --- a/compiler/sparc/call.lisp +++ b/compiler/sparc/call.lisp @@ -1,13 +1,15 @@ ;;; -*- Package: SPARC -*- ;;; ;;; ********************************************************************** -;;; This code was written as part of the Spice Lisp project at -;;; Carnegie-Mellon University, and has been placed in the public domain. -;;; If you want to use this code or any part of Spice Lisp, please contact -;;; Scott Fahlman (FAHLMAN@CMUC). -;;; ********************************************************************** +;;; This code was written as part of the CMU Common Lisp project at +;;; Carnegie Mellon University, and has been placed in the public domain. +;;; If you want to use this code or any part of CMU Common Lisp, please contact +;;; Scott Fahlman or slisp-group@cs.cmu.edu. +;;; +(ext:file-comment + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/sparc/call.lisp,v 1.11 1992/04/27 20:03:45 wlott Exp $") ;;; -;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/sparc/call.lisp,v 1.10 1992/04/01 20:11:48 wlott Exp $ +;;; ********************************************************************** ;;; ;;; This file contains the VM definition of function call for the SPARC. ;;; @@ -896,6 +898,29 @@ default-value-8 ;;;; Unknown values return: +;;; Return a single value using the unknown-values convention. +;;; +(define-vop (return-single) + (:args (old-fp :scs (any-reg)) + (return-pc :scs (descriptor-reg)) + (value)) + (:ignore value) + (:vop-var vop) + (:generator 6 + (trace-table-entry trace-table-function-epilogue) + ;; Clear the number stack. + (let ((cur-nfp (current-nfp-tn vop))) + (when cur-nfp + (inst add nsp-tn cur-nfp + (- (bytes-needed-for-non-descriptor-stack-frame) + number-stack-displacement)))) + ;; Clear the control stack, and restore the frame pointer. + (move csp-tn cfp-tn) + (move cfp-tn old-fp) + ;; Out of here. + (lisp-return return-pc :offset 2))) + (trace-table-entry trace-table-normal))) + ;;; Do unknown-values return of a fixed number of values. The Values are ;;; required to be set up in the standard passing locations. Nvals is the ;;; number of values returned.