X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Fx86%2Fshow.lisp;h=5fb38b9b5976588754c66979a12b6d3f29f652a7;hb=b28aadc5bd34a0d9fa0ff15c52b2b4164d955831;hp=4d291f10c39ed28f498d48acc5e01de102926426;hpb=0d871fd7a98fc4af92a8b942a1154761466ad8c9;p=sbcl.git diff --git a/src/compiler/x86/show.lisp b/src/compiler/x86/show.lisp index 4d291f1..5fb38b9 100644 --- a/src/compiler/x86/show.lisp +++ b/src/compiler/x86/show.lisp @@ -22,11 +22,20 @@ :from :eval :to (:result 0)) eax) + #!+darwin (:temporary (:sc unsigned-reg + :offset esi-offset) + prev-stack-pointer) (:results (result :scs (descriptor-reg))) (:save-p t) (:generator 100 - (inst push object) + ;; the stack should be 16-byte aligned on Darwin + #!-darwin (inst push object) + #!+darwin (progn (inst mov prev-stack-pointer esp-tn) + (inst sub esp-tn n-word-bytes) + (inst and esp-tn -16) + (storew object esp-tn)) (inst lea eax (make-fixup "debug_print" :foreign)) (inst call (make-fixup "call_into_c" :foreign)) - (inst add esp-tn n-word-bytes) + #!-darwin (inst add esp-tn n-word-bytes) + #!+darwin (inst mov esp-tn prev-stack-pointer) (move result eax)))