;; Else, value not immediate.
(storew value object offset lowtag))))
;; Else, value not immediate.
(storew value object offset lowtag))))
(define-vop (compare-and-swap-slot)
(:args (object :scs (descriptor-reg) :to :eval)
(old :scs (descriptor-reg any-reg) :target rax)
(define-vop (compare-and-swap-slot)
(:args (object :scs (descriptor-reg) :to :eval)
(old :scs (descriptor-reg any-reg) :target rax)
;; it is a fixnum. The lowtag selection magic that is required to
;; ensure this is explained in the comment in objdef.lisp
(loadw res symbol symbol-hash-slot other-pointer-lowtag)
;; it is a fixnum. The lowtag selection magic that is required to
;; ensure this is explained in the comment in objdef.lisp
(loadw res symbol symbol-hash-slot other-pointer-lowtag)
(:args (function :scs (descriptor-reg) :target result)
(fdefn :scs (descriptor-reg)))
(:temporary (:sc unsigned-reg) raw)
(:args (function :scs (descriptor-reg) :target result)
(fdefn :scs (descriptor-reg)))
(:temporary (:sc unsigned-reg) raw)
NORMAL-FUN
(storew function fdefn fdefn-fun-slot other-pointer-lowtag)
(storew raw fdefn fdefn-raw-addr-slot other-pointer-lowtag)
NORMAL-FUN
(storew function fdefn fdefn-fun-slot other-pointer-lowtag)
(storew raw fdefn fdefn-raw-addr-slot other-pointer-lowtag)
(loadw tls-index symbol symbol-tls-index-slot other-pointer-lowtag)
(inst add bsp (* binding-size n-word-bytes))
(store-binding-stack-pointer bsp)
(loadw tls-index symbol symbol-tls-index-slot other-pointer-lowtag)
(inst add bsp (* binding-size n-word-bytes))
(store-binding-stack-pointer bsp)
- (inst lea temp-reg-tn
- (make-ea :qword :disp
- (make-fixup (ecase (tn-offset tls-index)
- (#.rax-offset 'alloc-tls-index-in-rax)
- (#.rcx-offset 'alloc-tls-index-in-rcx)
- (#.rdx-offset 'alloc-tls-index-in-rdx)
- (#.rbx-offset 'alloc-tls-index-in-rbx)
- (#.rsi-offset 'alloc-tls-index-in-rsi)
- (#.rdi-offset 'alloc-tls-index-in-rdi)
- (#.r8-offset 'alloc-tls-index-in-r8)
- (#.r9-offset 'alloc-tls-index-in-r9)
- (#.r10-offset 'alloc-tls-index-in-r10)
- (#.r12-offset 'alloc-tls-index-in-r12)
- (#.r13-offset 'alloc-tls-index-in-r13)
- (#.r14-offset 'alloc-tls-index-in-r14)
- (#.r15-offset 'alloc-tls-index-in-r15))
- :assembly-routine)))
+ (inst mov temp-reg-tn
+ (make-fixup (ecase (tn-offset tls-index)
+ (#.rax-offset 'alloc-tls-index-in-rax)
+ (#.rcx-offset 'alloc-tls-index-in-rcx)
+ (#.rdx-offset 'alloc-tls-index-in-rdx)
+ (#.rbx-offset 'alloc-tls-index-in-rbx)
+ (#.rsi-offset 'alloc-tls-index-in-rsi)
+ (#.rdi-offset 'alloc-tls-index-in-rdi)
+ (#.r8-offset 'alloc-tls-index-in-r8)
+ (#.r9-offset 'alloc-tls-index-in-r9)
+ (#.r10-offset 'alloc-tls-index-in-r10)
+ (#.r12-offset 'alloc-tls-index-in-r12)
+ (#.r13-offset 'alloc-tls-index-in-r13)
+ (#.r14-offset 'alloc-tls-index-in-r14)
+ (#.r15-offset 'alloc-tls-index-in-r15))
+ :assembly-routine))
(inst call temp-reg-tn)
(emit-label tls-index-valid)
(inst push (make-ea :qword :base thread-base-tn :scale 1 :index tls-index))
(inst call temp-reg-tn)
(emit-label tls-index-valid)
(inst push (make-ea :qword :base thread-base-tn :scale 1 :index tls-index))
(inst jmp :z SKIP)
;; Bind stack debug sentinels have the unbound marker in the symbol slot
(inst cmp symbol unbound-marker-widetag)
(inst jmp :z SKIP)
;; Bind stack debug sentinels have the unbound marker in the symbol slot
(inst cmp symbol unbound-marker-widetag)
(if (integerp instance-length)
;; For RAW-INSTANCE-INIT/* VOPs, which know the exact instance length
;; at compile time.
(if (integerp instance-length)
;; For RAW-INSTANCE-INIT/* VOPs, which know the exact instance length
;; at compile time.