diff --git a/code/kernel.lisp b/code/kernel.lisp index 833a0b6d2c3575df9fd422eb93d80f6a98404c2d..8b6d90bd7ecec4085d37ba5a3ec9854fd2454ddd 100644 --- a/code/kernel.lisp +++ b/code/kernel.lisp @@ -7,7 +7,7 @@ ;;; Scott Fahlman (FAHLMAN@CMUC). ;;; ********************************************************************** ;;; -;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/kernel.lisp,v 1.1 1990/07/13 16:36:18 wlott Exp $ +;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/kernel.lisp,v 1.2 1990/10/03 09:57:49 wlott Exp $ ;;; (in-package "KERNEL") @@ -29,3 +29,65 @@ "Returns the length of the closure X. This is one more than the number of variables closed over." (get-closure-length x)) + +(defun get-lowtag (x) + "Returns the three-bit lowtag for the object X." + (get-lowtag x)) + +(defun get-type (x) + "Returns the 8-bit header type for the object X." + (get-type x)) + +(defun vector-sap (x) + "Return a System-Area-Pointer pointing to the data for the vector X, which + must be simple." + (declare (type (simple-unboxed-array (*)) x)) + (vector-sap x)) + + +(defun c::binding-stack-pointer-sap () + "Return a System-Area-Pointer pointing to the end of the binding stack." + (c::binding-stack-pointer-sap)) + +(defun c::dynamic-space-free-pointer () + "Returns a System-Area-Pointer pointing to the next free work of the current + dynamic space." + (c::dynamic-space-free-pointer)) + +(defun c::control-stack-pointer-sap () + "Return a System-Area-Pointer pointing to the end of the control stack." + (c::control-stack-pointer-sap)) + +(defun %function-header-arglist (func) + "Extracts the arglist from the function header FUNC." + (%function-header-arglist func)) + +(defun %function-header-name (func) + "Extracts the name from the function header FUNC." + (%function-header-name func)) + +(defun %function-header-type (func) + "Extracts the type from the function header FUNC." + (%function-header-type func)) + +(defun %closure-function (closure) + "Extracts the function from CLOSURE." + (%closure-function closure)) + +(defun c::vector-length (vector) + "Return the length of VECTOR. There is no reason to use this, 'cause + (length (the vector foo)) is the same." + (c::vector-length vector)) + +(defun %sxhash-simple-string (string) + "Return the SXHASH for the simple-string STRING." + (%sxhash-simple-string string)) + +(defun %sxhash-simple-substrubg (string length) + "Return the SXHASH for the first LENGTH characters of the simple-string + STRING." + (%sxhash-simple-substring string length)) + +(defun %closure-index-ref (closure index) + "Extract the INDEXth slot from CLOSURE." + (%closure-index-ref closure index))