X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Fmips%2Fsystem.lisp;h=b31d80d9d661f0b6acafc8b97164287990ed370a;hb=df06965814a879aa8ccd9367f2b1c450daccc601;hp=8bc6987c8bc8a18561c3db6f5447773e5a75d8a8;hpb=4ae1b794a5d6a90794468cf8017f5307f2c30dfe;p=sbcl.git diff --git a/src/compiler/mips/system.lisp b/src/compiler/mips/system.lisp index 8bc6987..b31d80d 100644 --- a/src/compiler/mips/system.lisp +++ b/src/compiler/mips/system.lisp @@ -1,32 +1,15 @@ -(in-package "SB!VM") +;;;; MIPS VM definitions of various system hacking operations - -;;;; Random pointer comparison VOPs - -(define-vop (pointer-compare) - (:args (x :scs (sap-reg)) - (y :scs (sap-reg))) - (:arg-types system-area-pointer system-area-pointer) - (:temporary (:scs (non-descriptor-reg)) temp) - (:conditional) - (:info target not-p) - (:policy :fast-safe) - (:note "inline comparison") - (:variant-vars condition) - (:generator 3 - (three-way-comparison x y condition :unsigned not-p target temp))) - -#+nil -(macrolet ((frob (name cond) - `(progn - (def-primitive-translator ,name (x y) `(,',name ,x ,y)) - (defknown ,name (t t) boolean (movable foldable flushable)) - (define-vop (,name pointer-compare) - (:translate ,name) - (:variant ,cond))))) - (frob pointer< :lt) - (frob pointer> :gt)) +;;;; This software is part of the SBCL system. See the README file for +;;;; more information. +;;;; +;;;; This software is derived from the CMU CL system, which was +;;;; written at Carnegie Mellon University and released into the +;;;; public domain. The software is in the public domain and is +;;;; provided with absolutely no warranty. See the COPYING and CREDITS +;;;; files for more information. +(in-package "SB!VM") ;;;; Type frobbing VOPs @@ -80,7 +63,7 @@ OTHER-PTR (load-type result object (- other-pointer-lowtag)) (inst nop) - + DONE)) (define-vop (fun-subtype) @@ -97,7 +80,7 @@ (:translate (setf fun-subtype)) (:policy :fast-safe) (:args (type :scs (unsigned-reg) :target result) - (function :scs (descriptor-reg))) + (function :scs (descriptor-reg))) (:arg-types positive-fixnum *) (:results (result :scs (unsigned-reg))) (:result-types positive-fixnum) @@ -130,7 +113,7 @@ (:translate set-header-data) (:policy :fast-safe) (:args (x :scs (descriptor-reg) :target res) - (data :scs (any-reg immediate zero))) + (data :scs (any-reg immediate zero))) (:arg-types * positive-fixnum) (:results (res :scs (descriptor-reg))) (:temporary (:scs (non-descriptor-reg)) t1 t2) @@ -159,8 +142,8 @@ (define-vop (make-other-immediate-type) (:args (val :scs (any-reg descriptor-reg)) - (type :scs (any-reg descriptor-reg immediate) - :target temp)) + (type :scs (any-reg descriptor-reg immediate) + :target temp)) (:results (res :scs (any-reg descriptor-reg))) (:temporary (:scs (non-descriptor-reg)) temp) (:generator 2 @@ -219,7 +202,7 @@ (define-vop (compute-fun) (:args (code :scs (descriptor-reg)) - (offset :scs (signed-reg unsigned-reg))) + (offset :scs (signed-reg unsigned-reg))) (:arg-types * positive-fixnum) (:results (func :scs (descriptor-reg))) (:temporary (:scs (non-descriptor-reg)) ndescr) @@ -235,17 +218,17 @@ ;;;; Other random VOPs. -(defknown sb!unix::do-pending-interrupt () (values)) -(define-vop (sb!unix::do-pending-interrupt) +(defknown sb!unix::receive-pending-interrupt () (values)) +(define-vop (sb!unix::receive-pending-interrupt) (:policy :fast-safe) - (:translate sb!unix::do-pending-interrupt) + (:translate sb!unix::receive-pending-interrupt) (:generator 1 - (inst break pending-interrupt-trap))) + (inst break 0 pending-interrupt-trap))) (define-vop (halt) (:generator 1 - (inst break halt-trap))) + (inst break 0 halt-trap))) ;;;; Dynamic vop count collection support @@ -256,7 +239,7 @@ (:temporary (:scs (non-descriptor-reg)) count) (:generator 1 (let ((offset - (- (* (+ index vector-data-offset) n-word-bytes) other-pointer-lowtag))) + (- (* (+ index vector-data-offset) n-word-bytes) other-pointer-lowtag))) (inst lw count count-vector offset) (inst nop) (inst addu count 1)