X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Fgeneric%2Fvm-ir2tran.lisp;h=c9e064aaecf3385078d71615ad78dd6a27ab8aa7;hb=5c41b6d95580938db33efd4640c2947b9e51e723;hp=1ca4e97a6a7df0020a6ca51e7f96eeba1ffa3051;hpb=f1ffbf976aaa50b7b22f126b97e34afe06a91210;p=sbcl.git diff --git a/src/compiler/generic/vm-ir2tran.lisp b/src/compiler/generic/vm-ir2tran.lisp index 1ca4e97..c9e064a 100644 --- a/src/compiler/generic/vm-ir2tran.lisp +++ b/src/compiler/generic/vm-ir2tran.lisp @@ -32,8 +32,9 @@ name offset lowtag) (move-lvar-result node block (list value-tn) (node-lvar node)))) -(defun do-inits (node block name result lowtag inits args) - (let ((unbound-marker-tn nil)) +(defun emit-inits (node block name result lowtag inits args) + (let ((unbound-marker-tn nil) + (funcallable-instance-tramp-tn nil)) (dolist (init inits) (let ((kind (car init)) (slot (cdr init))) @@ -51,35 +52,41 @@ (vop make-unbound-marker node block tn) tn)))) (:null - (emit-constant nil))) + (emit-constant nil)) + (:funcallable-instance-tramp + (or funcallable-instance-tramp-tn + (setf funcallable-instance-tramp-tn + (let ((tn (make-restricted-tn + nil + (sc-number-or-lose 'sb!vm::any-reg)))) + (vop make-funcallable-instance-tramp node block tn) + tn))))) name slot lowtag)))) (aver (null args))) -(defun do-fixed-alloc (node block name words type lowtag result) +(defun emit-fixed-alloc (node block name words type lowtag result) (vop fixed-alloc node block name words type lowtag result)) (defoptimizer ir2-convert-fixed-allocation ((&rest args) node block name words type lowtag inits) (let* ((lvar (node-lvar node)) - (locs (lvar-result-tns lvar - (list *backend-t-primitive-type*))) + (locs (lvar-result-tns lvar (list *backend-t-primitive-type*))) (result (first locs))) - (do-fixed-alloc node block name words type lowtag result) - (do-inits node block name result lowtag inits args) + (emit-fixed-alloc node block name words type lowtag result) + (emit-inits node block name result lowtag inits args) (move-lvar-result node block locs lvar))) (defoptimizer ir2-convert-variable-allocation ((extra &rest args) node block name words type lowtag inits) (let* ((lvar (node-lvar node)) - (locs (lvar-result-tns lvar - (list *backend-t-primitive-type*))) + (locs (lvar-result-tns lvar (list *backend-t-primitive-type*))) (result (first locs))) (if (constant-lvar-p extra) (let ((words (+ (lvar-value extra) words))) - (do-fixed-alloc node block name words type lowtag result)) + (emit-fixed-alloc node block name words type lowtag result)) (vop var-alloc node block (lvar-tn node block extra) name words type lowtag result)) - (do-inits node block name result lowtag inits args) + (emit-inits node block name result lowtag inits args) (move-lvar-result node block locs lvar))) ;;; :SET-TRANS (in objdef.lisp DEFINE-PRIMITIVE-OBJECT) doesn't quite