Skip to content
Snippets Groups Projects
Commit 04e1b8ee authored by rtoy's avatar rtoy
Browse files

Use allocation macro instead of modifying alloc-tn directly.

parent f7fb2b82
No related branches found
No related tags found
No related merge requests found
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
;;; Scott Fahlman or slisp-group@cs.cmu.edu. ;;; Scott Fahlman or slisp-group@cs.cmu.edu.
;;; ;;;
(ext:file-comment (ext:file-comment
"$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/ppc/alloc.lisp,v 1.6 2004/08/08 11:15:11 rtoy Exp $") "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/ppc/alloc.lisp,v 1.7 2004/08/09 01:36:47 rtoy Exp $")
;;; ;;;
;;; ********************************************************************** ;;; **********************************************************************
;;; ;;;
...@@ -145,9 +145,9 @@ ...@@ -145,9 +145,9 @@
(:ignore dynamic-extent) (:ignore dynamic-extent)
(:generator 10 (:generator 10
(let ((size (+ length closure-info-offset))) (let ((size (+ length closure-info-offset)))
(pseudo-atomic (pa-flag :extra (pad-data-block size)) (pseudo-atomic (pa-flag)
(inst clrrwi. result alloc-tn lowtag-bits)
(inst ori result result function-pointer-type) (allocation result (pad-data-block size) function-pointer-type :temp-tn temp)
(inst lr temp (logior (ash (1- size) type-bits) closure-header-type)) (inst lr temp (logior (ash (1- size) type-bits) closure-header-type))
(storew temp result 0 function-pointer-type))) (storew temp result 0 function-pointer-type)))
#+PPC-FUN-HACK #+PPC-FUN-HACK
...@@ -186,12 +186,9 @@ ...@@ -186,12 +186,9 @@
(:temporary (:scs (non-descriptor-reg)) temp) (:temporary (:scs (non-descriptor-reg)) temp)
(:temporary (:sc non-descriptor-reg :offset nl3-offset) pa-flag) (:temporary (:sc non-descriptor-reg :offset nl3-offset) pa-flag)
(:generator 4 (:generator 4
(pseudo-atomic (pa-flag :extra (pad-data-block words)) ;; Could this be replaced with with-fixed-allocation?
(cond ((logbitp 2 lowtag) (pseudo-atomic (pa-flag)
(inst ori result alloc-tn lowtag)) (allocation result (pad-data-block words) lowtag :temp-tn temp)
(t
(inst clrrwi result alloc-tn lowtag-bits)
(inst ori result result lowtag)))
(when type (when type
(inst lr temp (logior (ash (1- words) type-bits) type)) (inst lr temp (logior (ash (1- words) type-bits) type))
(storew temp result 0 lowtag))))) (storew temp result 0 lowtag)))))
...@@ -210,10 +207,5 @@ ...@@ -210,10 +207,5 @@
(inst addi header header (+ (ash -2 type-bits) type)) (inst addi header header (+ (ash -2 type-bits) type))
(inst clrrwi bytes bytes lowtag-bits) (inst clrrwi bytes bytes lowtag-bits)
(pseudo-atomic (pa-flag) (pseudo-atomic (pa-flag)
(cond ((logbitp 2 lowtag) (allocation result bytes lowtag :temp-tn temp)
(inst ori result alloc-tn lowtag)) (storew header result 0 lowtag))))
(t
(inst clrrwi result alloc-tn lowtag-bits)
(inst ori result result lowtag)))
(storew header result 0 lowtag)
(inst add alloc-tn alloc-tn bytes))))
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
;;; Scott Fahlman or slisp-group@cs.cmu.edu. ;;; Scott Fahlman or slisp-group@cs.cmu.edu.
;;; ;;;
(ext:file-comment (ext:file-comment
"$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/ppc/call.lisp,v 1.5 2004/07/25 18:15:52 pmai Exp $") "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/ppc/call.lisp,v 1.6 2004/08/09 01:36:47 rtoy Exp $")
;;; ;;;
;;; ********************************************************************** ;;; **********************************************************************
;;; ;;;
...@@ -1198,11 +1198,9 @@ default-value-8 ...@@ -1198,11 +1198,9 @@ default-value-8
(pseudo-atomic (pa-flag) (pseudo-atomic (pa-flag)
(assemble () (assemble ()
;; Allocate a cons (2 words) for each item. ;; Allocate a cons (2 words) for each item.
(inst clrrwi result alloc-tn lowtag-bits)
(inst ori result result list-pointer-type)
(move dst result)
(inst slwi temp count 1) (inst slwi temp count 1)
(inst add alloc-tn alloc-tn temp) (allocation result temp list-pointer-type :temp-tn dst)
(move dst result)
(inst b enter) (inst b enter)
;; Compute the next cons and store it in the current one. ;; Compute the next cons and store it in the current one.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment