⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 cell.lisp

📁 开源跨平台Lisp编译器
💻 LISP
📖 第 1 页 / 共 3 页
字号:
    (inst shr tmp n-widetag-bits)    (inst movss value (make-ea-for-raw-slot object index tmp))))(define-vop (raw-instance-set/single)  (:translate %raw-instance-set/single)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (index :scs (any-reg))         (value :scs (single-reg) :target result))  (:arg-types * positive-fixnum single-float)  (:temporary (:sc unsigned-reg) tmp)  (:results (result :scs (single-reg)))  (:result-types single-float)  (:generator 5    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst shl tmp 3)    (inst sub tmp index)    (inst movss (make-ea-for-raw-slot object index tmp) value)   (unless (location= result value)     (inst movss result value))))(define-vop (raw-instance-set-c/single)  (:translate %raw-instance-set/single)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (value :scs (single-reg) :target result))  (:arg-types * (:constant (load/store-index #.sb!vm:n-word-bytes                                             #.instance-pointer-lowtag                                             #.instance-slots-offset))              single-float)  (:info index)  (:temporary (:sc unsigned-reg) tmp)  (:results (result :scs (single-reg)))  (:result-types single-float)  (:generator 4    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst movss (make-ea-for-raw-slot object index tmp) value)   (unless (location= result value)     (inst movss result value))))(define-vop (raw-instance-init/single)  (:args (object :scs (descriptor-reg))         (value :scs (single-reg)))  (:arg-types * single-float)  (:info instance-length index)  (:generator 4    (inst movss (make-ea-for-raw-slot object index instance-length) value)))(define-vop (raw-instance-ref/double)  (:translate %raw-instance-ref/double)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (index :scs (any-reg)))  (:arg-types * positive-fixnum)  (:temporary (:sc unsigned-reg) tmp)  (:results (value :scs (double-reg)))  (:result-types double-float)  (:generator 5    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst shl tmp 3)    (inst sub tmp index)    (inst movsd value (make-ea-for-raw-slot object index tmp))))(define-vop (raw-instance-ref-c/double)  (:translate %raw-instance-ref/double)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg)))  (:arg-types * (:constant (load/store-index #.sb!vm:n-word-bytes                                             #.instance-pointer-lowtag                                             #.instance-slots-offset)))  (:info index)  (:temporary (:sc unsigned-reg) tmp)  (:results (value :scs (double-reg)))  (:result-types double-float)  (:generator 4    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst movsd value (make-ea-for-raw-slot object index tmp))))(define-vop (raw-instance-set/double)  (:translate %raw-instance-set/double)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (index :scs (any-reg))         (value :scs (double-reg) :target result))  (:arg-types * positive-fixnum double-float)  (:temporary (:sc unsigned-reg) tmp)  (:results (result :scs (double-reg)))  (:result-types double-float)  (:generator 5    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst shl tmp 3)    (inst sub tmp index)    (inst movsd (make-ea-for-raw-slot object index tmp) value)   (unless (location= result value)     (inst movsd result value))))(define-vop (raw-instance-set-c/double)  (:translate %raw-instance-set/double)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (value :scs (double-reg) :target result))  (:arg-types * (:constant (load/store-index #.sb!vm:n-word-bytes                                             #.instance-pointer-lowtag                                             #.instance-slots-offset))              double-float)  (:info index)  (:temporary (:sc unsigned-reg) tmp)  (:results (result :scs (double-reg)))  (:result-types double-float)  (:generator 4    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst movsd (make-ea-for-raw-slot object index tmp) value)   (unless (location= result value)     (inst movsd result value))))(define-vop (raw-instance-init/double)  (:args (object :scs (descriptor-reg))         (value :scs (double-reg)))  (:arg-types * double-float)  (:info instance-length index)  (:generator 4    (inst movsd (make-ea-for-raw-slot object index instance-length) value)))(define-vop (raw-instance-ref/complex-single)  (:translate %raw-instance-ref/complex-single)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (index :scs (any-reg)))  (:arg-types * positive-fixnum)  (:temporary (:sc unsigned-reg) tmp)  (:results (value :scs (complex-single-reg)))  (:result-types complex-single-float)  (:generator 5    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst shl tmp 3)    (inst sub tmp index)    (let ((real-tn (complex-single-reg-real-tn value)))      (inst movss real-tn (make-ea-for-raw-slot object index tmp)))    (let ((imag-tn (complex-single-reg-imag-tn value)))      (inst movss imag-tn (make-ea-for-raw-slot object index tmp 4)))))(define-vop (raw-instance-ref-c/complex-single)  (:translate %raw-instance-ref/complex-single)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg)))  (:arg-types * (:constant (load/store-index #.sb!vm:n-word-bytes                                             #.instance-pointer-lowtag                                             #.instance-slots-offset)))  (:info index)  (:temporary (:sc unsigned-reg) tmp)  (:results (value :scs (complex-single-reg)))  (:result-types complex-single-float)  (:generator 4    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (let ((real-tn (complex-single-reg-real-tn value)))      (inst movss real-tn (make-ea-for-raw-slot object index tmp)))    (let ((imag-tn (complex-single-reg-imag-tn value)))      (inst movss imag-tn (make-ea-for-raw-slot object index tmp 4)))))(define-vop (raw-instance-set/complex-single)  (:translate %raw-instance-set/complex-single)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (index :scs (any-reg))         (value :scs (complex-single-reg) :target result))  (:arg-types * positive-fixnum complex-single-float)  (:temporary (:sc unsigned-reg) tmp)  (:results (result :scs (complex-single-reg)))  (:result-types complex-single-float)  (:generator 5    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst shl tmp 3)    (inst sub tmp index)    (let ((value-real (complex-single-reg-real-tn value))          (result-real (complex-single-reg-real-tn result)))      (inst movss (make-ea-for-raw-slot object index tmp) value-real)      (unless (location= value-real result-real)        (inst movss result-real value-real)))    (let ((value-imag (complex-single-reg-imag-tn value))          (result-imag (complex-single-reg-imag-tn result)))      (inst movss (make-ea-for-raw-slot object index tmp 4) value-imag)      (unless (location= value-imag result-imag)        (inst movss result-imag value-imag)))))(define-vop (raw-instance-set-c/complex-single)  (:translate %raw-instance-set/complex-single)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (value :scs (complex-single-reg) :target result))  (:arg-types * (:constant (load/store-index #.sb!vm:n-word-bytes                                             #.instance-pointer-lowtag                                             #.instance-slots-offset))              complex-single-float)  (:info index)  (:temporary (:sc unsigned-reg) tmp)  (:results (result :scs (complex-single-reg)))  (:result-types complex-single-float)  (:generator 4    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (let ((value-real (complex-single-reg-real-tn value))          (result-real (complex-single-reg-real-tn result)))      (inst movss (make-ea-for-raw-slot object index tmp) value-real)      (unless (location= value-real result-real)        (inst movss result-real value-real)))    (let ((value-imag (complex-single-reg-imag-tn value))          (result-imag (complex-single-reg-imag-tn result)))      (inst movss (make-ea-for-raw-slot object index tmp 4) value-imag)      (unless (location= value-imag result-imag)        (inst movss result-imag value-imag)))))(define-vop (raw-instance-init/complex-single)  (:args (object :scs (descriptor-reg))         (value :scs (complex-single-reg)))  (:arg-types * complex-single-float)  (:info instance-length index)  (:generator 4    (let ((value-real (complex-single-reg-real-tn value)))      (inst movss (make-ea-for-raw-slot object index instance-length) value-real))    (let ((value-imag (complex-single-reg-imag-tn value)))      (inst movss (make-ea-for-raw-slot object index instance-length 4) value-imag))))(define-vop (raw-instance-ref/complex-double)  (:translate %raw-instance-ref/complex-double)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (index :scs (any-reg)))  (:arg-types * positive-fixnum)  (:temporary (:sc unsigned-reg) tmp)  (:results (value :scs (complex-double-reg)))  (:result-types complex-double-float)  (:generator 5    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst shl tmp 3)    (inst sub tmp index)    (let ((real-tn (complex-double-reg-real-tn value)))      (inst movsd real-tn (make-ea-for-raw-slot object index tmp -8)))    (let ((imag-tn (complex-double-reg-imag-tn value)))      (inst movsd imag-tn (make-ea-for-raw-slot object index tmp)))))(define-vop (raw-instance-ref-c/complex-double)  (:translate %raw-instance-ref/complex-double)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg)))  (:arg-types * (:constant (load/store-index #.sb!vm:n-word-bytes                                             #.instance-pointer-lowtag                                             #.instance-slots-offset)))  (:info index)  (:temporary (:sc unsigned-reg) tmp)  (:results (value :scs (complex-double-reg)))  (:result-types complex-double-float)  (:generator 4    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (let ((real-tn (complex-double-reg-real-tn value)))      (inst movsd real-tn (make-ea-for-raw-slot object index tmp -8)))    (let ((imag-tn (complex-double-reg-imag-tn value)))      (inst movsd imag-tn (make-ea-for-raw-slot object index tmp)))))(define-vop (raw-instance-set/complex-double)  (:translate %raw-instance-set/complex-double)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (index :scs (any-reg))         (value :scs (complex-double-reg) :target result))  (:arg-types * positive-fixnum complex-double-float)  (:temporary (:sc unsigned-reg) tmp)  (:results (result :scs (complex-double-reg)))  (:result-types complex-double-float)  (:generator 5    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (inst shl tmp 3)    (inst sub tmp index)    (let ((value-real (complex-double-reg-real-tn value))          (result-real (complex-double-reg-real-tn result)))      (inst movsd (make-ea-for-raw-slot object index tmp -8) value-real)      (unless (location= value-real result-real)        (inst movsd result-real value-real)))    (let ((value-imag (complex-double-reg-imag-tn value))          (result-imag (complex-double-reg-imag-tn result)))      (inst movsd (make-ea-for-raw-slot object index tmp) value-imag)      (unless (location= value-imag result-imag)        (inst movsd result-imag value-imag)))))(define-vop (raw-instance-set-c/complex-double)  (:translate %raw-instance-set/complex-double)  (:policy :fast-safe)  (:args (object :scs (descriptor-reg))         (value :scs (complex-double-reg) :target result))  (:arg-types * (:constant (load/store-index #.sb!vm:n-word-bytes                                             #.instance-pointer-lowtag                                             #.instance-slots-offset))              complex-double-float)  (:info index)  (:temporary (:sc unsigned-reg) tmp)  (:results (result :scs (complex-double-reg)))  (:result-types complex-double-float)  (:generator 4    (loadw tmp object 0 instance-pointer-lowtag)    (inst shr tmp n-widetag-bits)    (let ((value-real (complex-double-reg-real-tn value))          (result-real (complex-double-reg-real-tn result)))      (inst movsd (make-ea-for-raw-slot object index tmp -8) value-real)      (unless (location= value-real result-real)        (inst movsd result-real value-real)))    (let ((value-imag (complex-double-reg-imag-tn value))          (result-imag (complex-double-reg-imag-tn result)))      (inst movsd (make-ea-for-raw-slot object index tmp) value-imag)      (unless (location= value-imag result-imag)        (inst movsd result-imag value-imag)))))(define-vop (raw-instance-init/complex-double)  (:args (object :scs (descriptor-reg))         (value :scs (complex-double-reg)))  (:arg-types * complex-double-float)  (:info instance-length index)  (:generator 4    (let ((value-real (complex-double-reg-real-tn value)))      (inst movsd (make-ea-for-raw-slot object index instance-length -8) value-real))    (let ((value-imag (complex-double-reg-imag-tn value)))      (inst movsd (make-ea-for-raw-slot object index instance-length) value-imag))))

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -