1.0.13.44: bug #414 has disappeared
[sbcl/simd.git] / src / compiler / ppc / show.lisp
blob429ea974ba89a3dda2c83b48b3f8561db86e9b4f
1 ;;; Written by William Lott.
3 (in-package "SB!VM")
6 (define-vop (print)
7 (:args (object :scs (descriptor-reg any-reg) :target nl0))
8 (:results (result :scs (descriptor-reg)))
9 (:save-p t)
10 (:temporary (:sc any-reg :offset nl0-offset :from (:argument 0)) nl0)
11 (:temporary (:sc any-reg :offset cfunc-offset) cfunc)
12 (:temporary (:sc interior-reg :offset lip-offset) lip)
13 (:temporary (:scs (non-descriptor-reg)) temp)
14 (:temporary (:sc control-stack :offset nfp-save-offset) nfp-save)
15 (:vop-var vop)
16 (:generator 100
17 (let ((cur-nfp (current-nfp-tn vop)))
18 (when cur-nfp
19 (store-stack-tn nfp-save cur-nfp))
20 (move nl0 object)
21 (inst lr temp (make-fixup "call_into_c" :foreign))
22 (inst mr lip temp)
23 (inst mtctr lip)
24 (inst lr cfunc (make-fixup "debug_print" :foreign))
25 (inst bctrl)
26 (when cur-nfp
27 (load-stack-tn cur-nfp nfp-save))
28 (move result nl0))))