X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Fload.lisp;h=f7a45a6c955f220713bfeb59f3c94333546b57cb;hb=6a9bbe6f36179cee92001a1f9ed5ff38be512644;hp=02a029393eb9b285ba883aa499047a350680146e;hpb=1b778d435773891979dab6d442c19f2b7b62b869;p=sbcl.git diff --git a/src/code/load.lisp b/src/code/load.lisp index 02a0293..f7a45a6 100644 --- a/src/code/load.lisp +++ b/src/code/load.lisp @@ -348,31 +348,26 @@ (loop (let ((byte (read-byte stream))) - ;; stale code from before rewrite of *FOP-STACK* as - ;; adjustable vector (probably worth rewriting when next - ;; anyone needs to debug FASL stuff) - #| ;; Do some debugging output. #!+sb-show (when *show-fops-p* - (let ((ptr *fop-stack-pointer*) - (stack *fop-stack*)) - (fresh-line *trace-output*) - ;; The FOP operations are stack based, so it's sorta - ;; logical to display the operand before the operator. - ;; ("reverse Polish notation") - (unless (= ptr (length stack)) - (write-char #\space *trace-output*) - (prin1 (svref stack ptr) *trace-output*) - (terpri *trace-output*)) - ;; Display the operator. - (format *trace-output* - "~&~S (#X~X at ~D) (~S)~%" - (svref *fop-names* byte) - byte - (1- (file-position stream)) - (svref *fop-funs* byte)))) - |# + (let* ((stack *fop-stack*) + (ptr (1- (fill-pointer *fop-stack*)))) + (fresh-line *trace-output*) + ;; The FOP operations are stack based, so it's sorta + ;; logical to display the operand before the operator. + ;; ("reverse Polish notation") + (unless (= ptr -1) + (write-char #\space *trace-output*) + (prin1 (aref stack ptr) *trace-output*) + (terpri *trace-output*)) + ;; Display the operator. + (format *trace-output* + "~&~S (#X~X at ~D) (~S)~%" + (aref *fop-names* byte) + byte + (1- (file-position stream)) + (svref *fop-funs* byte)))) ;; Actually execute the fop. (funcall (the function (svref *fop-funs* byte))))))))) @@ -406,7 +401,7 @@ ;;; code for foreign symbol lookup should be here. (defun find-foreign-symbol-in-table (name table) (let ((prefixes - #!+(or osf1 sunos linux freebsd darwin) #("" "ldso_stub__") + #!+(or osf1 sunos linux freebsd netbsd darwin) #("" "ldso_stub__") #!+openbsd #(""))) (declare (notinline some)) ; to suppress bug 117 bogowarning (some (lambda (prefix)