Skip to content

Commit

Permalink
Pass through DX-P to INIT-SLOT vop
Browse files Browse the repository at this point in the history
This allows using smaller-than-lispobj writes for pre-zeroed memory,
if the backend so chooses.
  • Loading branch information
snuglas committed Jul 31, 2017
1 parent 246cc4c commit 3721262
Show file tree
Hide file tree
Showing 10 changed files with 29 additions and 12 deletions.
4 changes: 3 additions & 1 deletion src/compiler/alpha/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@
#!-gengc
(storew value object offset lowtag)))

(define-vop (init-slot set-slot))
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:ignore name dx-p))

;;;; symbol hacking VOPs

Expand Down
4 changes: 3 additions & 1 deletion src/compiler/arm/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@
(:generator 1
(storew value object offset lowtag)))

(define-vop (init-slot set-slot))
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:ignore name dx-p))

;;;; Symbol hacking VOPs:

Expand Down
4 changes: 3 additions & 1 deletion src/compiler/arm64/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@
(:generator 1
(storew value object offset lowtag)))

(define-vop (init-slot set-slot))
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:ignore name dx-p))

(define-vop (compare-and-swap-slot)
(:args (object :scs (descriptor-reg))
Expand Down
6 changes: 3 additions & 3 deletions src/compiler/generic/vm-ir2tran.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
`(ecase raw-type
((t)
(vop init-slot node block object arg-tn
name (+ sb!vm:instance-slots-offset slot) lowtag))
name dx-p (+ sb!vm:instance-slots-offset slot) lowtag))
,@(map 'list
(lambda (rsd)
`(,(sb!kernel::raw-slot-data-raw-type rsd)
Expand All @@ -111,7 +111,7 @@
(:dd
(vop init-slot node block object
(emit-constant (sb!kernel::dd-layout-or-lose slot))
name
name dx-p
;; Layout has no index if compact headers.
(or #!+compact-instance-header :layout sb!vm:instance-slots-offset)
lowtag))
Expand Down Expand Up @@ -148,7 +148,7 @@
(sc-number-or-lose 'sb!vm::any-reg))))
(vop make-funcallable-instance-tramp node block tn)
tn)))))
name slot lowtag))))))))
name dx-p slot lowtag))))))))
(unless (null args)
(bug "Leftover args: ~S" args)))

Expand Down
4 changes: 3 additions & 1 deletion src/compiler/hppa/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@
(:generator 1
(storew value object offset lowtag)))

(define-vop (init-slot set-slot))
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:ignore name dx-p))

;;;; Symbol hacking VOPs:

Expand Down
4 changes: 3 additions & 1 deletion src/compiler/mips/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@
(:generator 1
(storew value object offset lowtag)))

(define-vop (init-slot set-slot))
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:ignore name dx-p))

;;;; Symbol hacking VOPs:

Expand Down
4 changes: 3 additions & 1 deletion src/compiler/ppc/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@
(:generator 1
(storew value object offset lowtag)))

(define-vop (init-slot set-slot))
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:ignore name dx-p))

#!+compare-and-swap-vops
(define-vop (compare-and-swap-slot)
Expand Down
4 changes: 3 additions & 1 deletion src/compiler/sparc/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@
(:generator 1
(storew value object offset lowtag)))

(define-vop (init-slot set-slot))
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:ignore name dx-p))

;;;; Symbol hacking VOPs:

Expand Down
3 changes: 2 additions & 1 deletion src/compiler/x86-64/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,9 @@

;; INIT-SLOT has to know about the :COMPACT-INSTANCE-HEADER feature.
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:generator 1
(progn name)
(progn name dx-p)
(if (or #!+compact-instance-header
(and (eq name '%make-structure-instance) (eql offset :layout)))
;; The layout is in the upper half of the header word.
Expand Down
4 changes: 3 additions & 1 deletion src/compiler/x86/cell.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@
(:generator 1
(storew (encode-value-if-immediate value) object offset lowtag)))

(define-vop (init-slot set-slot))
(define-vop (init-slot set-slot)
(:info name dx-p offset lowtag)
(:ignore name dx-p))

(define-vop (compare-and-swap-slot)
(:args (object :scs (descriptor-reg) :to :eval)
Expand Down

0 comments on commit 3721262

Please sign in to comment.