X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Fx86-64%2Fmacros.lisp;h=32b3923b908cc517547b26fe7242ff129f6ff6e9;hb=ec2e02db335d1545b3c18233bf440ca4160f780d;hp=be94d71a3ae0d9c55f6cd6a3ac1f0a4d3190d322;hpb=906ecd4ef2d10aca23e1081f03c13fe2f932ed89;p=sbcl.git diff --git a/src/compiler/x86-64/macros.lisp b/src/compiler/x86-64/macros.lisp index be94d71..32b3923 100644 --- a/src/compiler/x86-64/macros.lisp +++ b/src/compiler/x86-64/macros.lisp @@ -125,7 +125,8 @@ (make-ea :byte :base ,n-source :disp ,n-offset))) (:big-endian `(inst mov ,n-target - (make-ea :byte :base ,n-source :disp (+ ,n-offset 4))))))) + (make-ea :byte :base ,n-source + :disp (+ ,n-offset (1- n-word-bytes)))))))) ;;;; allocation helpers @@ -225,13 +226,13 @@ ;;; Allocate an other-pointer object of fixed SIZE with a single word ;;; header having the specified WIDETAG value. The result is placed in ;;; RESULT-TN. -(defmacro with-fixed-allocation ((result-tn widetag size &optional inline) +(defmacro with-fixed-allocation ((result-tn widetag size &optional inline stack-allocate-p) &body forms) (unless forms (bug "empty &body in WITH-FIXED-ALLOCATION")) - (once-only ((result-tn result-tn) (size size)) - `(pseudo-atomic - (allocation ,result-tn (pad-data-block ,size) ,inline) + (once-only ((result-tn result-tn) (size size) (stack-allocate-p stack-allocate-p)) + `(maybe-pseudo-atomic ,stack-allocate-p + (allocation ,result-tn (pad-data-block ,size) ,inline ,stack-allocate-p) (storew (logior (ash (1- ,size) n-widetag-bits) ,widetag) ,result-tn) (inst lea ,result-tn