X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Fgeneric%2Ftarget-core.lisp;h=55808d89f601fb8dc6370be0421ef741145c2f6e;hb=2372ff8da6e1099e8840b0815d75c414fff2f302;hp=c07f5e55ec934490faa776ece0a1991e6ae30ef3;hpb=cb83aa22932bf4b9bc74ac6f0fcd91db1702ad33;p=sbcl.git diff --git a/src/compiler/generic/target-core.lisp b/src/compiler/generic/target-core.lisp index c07f5e5..55808d8 100644 --- a/src/compiler/generic/target-core.lisp +++ b/src/compiler/generic/target-core.lisp @@ -16,6 +16,17 @@ (in-package "SB!C") +(declaim (ftype (function (fixnum fixnum) (values code-component &optional)) + allocate-code-object)) +(defun allocate-code-object (boxed unboxed) + #!+gencgc + (without-gcing + (%make-lisp-obj + (alien-funcall (extern-alien "alloc_code_object" (function unsigned unsigned unsigned)) + boxed unboxed))) + #!-gencgc + (%primitive allocate-code-object boxed unboxed)) + ;;; Make a function entry, filling in slots from the ENTRY-INFO. (defun make-fun-entry (entry-info code-obj object) (declare (type entry-info entry-info) (type core-object object)) @@ -30,7 +41,7 @@ (setf (%simple-fun-name res) (entry-info-name entry-info)) (setf (%simple-fun-arglist res) (entry-info-arguments entry-info)) (setf (%simple-fun-type res) (entry-info-type entry-info)) - (setf (%simple-fun-xrefs res) (entry-info-xref entry-info)) + (setf (%simple-fun-info res) (entry-info-info entry-info)) (note-fun entry-info res object)))) @@ -51,8 +62,7 @@ (total-length (+ length (ceiling trace-table-bits sb!vm:n-byte-bits))) (box-num (- (length constants) sb!vm:code-trace-table-offset-slot)) - (code-obj - (%primitive allocate-code-object box-num total-length)) + (code-obj (allocate-code-object box-num total-length)) (fill-ptr (code-instructions code-obj))) (declare (type index box-num total-length))