From: Nathan Froyd Date: Tue, 6 Apr 2010 14:32:42 +0000 (+0000) Subject: 1.0.37.43: add RAW-INSTANCE-INIT/* VOPs for PPC X-Git-Url: http://repo.macrolet.net/gitweb/?a=commitdiff_plain;h=d5e1f093b8ca643ce4f39554232e0a1688e85b7c;p=sbcl.git 1.0.37.43: add RAW-INSTANCE-INIT/* VOPs for PPC --- diff --git a/make-config.sh b/make-config.sh index 9cbfa0d..afa9350 100644 --- a/make-config.sh +++ b/make-config.sh @@ -330,7 +330,7 @@ elif [ "$sbcl_arch" = "mips" ]; then tools-for-build/determine-endianness >> $ltf elif [ "$sbcl_arch" = "ppc" ]; then printf ' :gencgc :stack-allocatable-closures :stack-allocatable-lists' >> $ltf - printf ' :linkage-table' >> $ltf + printf ' :linkage-table :raw-instance-init-vops' >> $ltf if [ "$sbcl_os" = "linux" ]; then # Use a C program to detect which kind of glibc we're building on, # to bandage across the break in source compatibility between diff --git a/src/compiler/ppc/cell.lisp b/src/compiler/ppc/cell.lisp index c3a3fbd..8ac94b3 100644 --- a/src/compiler/ppc/cell.lisp +++ b/src/compiler/ppc/cell.lisp @@ -288,6 +288,19 @@ ;;;; raw instance slot accessors +(defun offset-for-raw-slot (instance-length index n-words) + (+ (* (- instance-length instance-slots-offset index (1- n-words)) + n-word-bytes) + (- instance-pointer-lowtag))) + +(define-vop (raw-instance-init/word) + (:args (object :scs (descriptor-reg)) + (value :scs (unsigned-reg))) + (:arg-types * unsigned-num) + (:info instance-length index) + (:generator 4 + (inst stw value object (offset-for-raw-slot instance-length index 1)))) + (define-vop (raw-instance-ref/word) (:translate %raw-instance-ref/word) (:policy :fast-safe) @@ -332,6 +345,14 @@ (inst stwx value object offset) (move 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 stfs value object (offset-for-raw-slot instance-length index 1)))) + (define-vop (raw-instance-ref/single) (:translate %raw-instance-ref/single) (:policy :fast-safe) @@ -377,6 +398,14 @@ (unless (location= result value) (inst frsp 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 stfd value object (offset-for-raw-slot instance-length index 2)))) + (define-vop (raw-instance-ref/double) (:translate %raw-instance-ref/double) (:policy :fast-safe) @@ -422,6 +451,17 @@ (unless (location= result value) (inst fmr result value)))) +(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 + (inst stfs (complex-single-reg-real-tn value) + object (offset-for-raw-slot instance-length index 2)) + (inst stfs (complex-single-reg-imag-tn value) + object (offset-for-raw-slot instance-length index 1)))) + (define-vop (raw-instance-ref/complex-single) (:translate %raw-instance-ref/complex-single) (:policy :fast-safe) @@ -477,6 +517,17 @@ (unless (location= result-imag value-imag) (inst frsp 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 + (inst stfd (complex-single-reg-real-tn value) + object (offset-for-raw-slot instance-length index 4)) + (inst stfd (complex-double-reg-imag-tn value) + object (offset-for-raw-slot instance-length index 2)))) + (define-vop (raw-instance-ref/complex-double) (:translate %raw-instance-ref/complex-double) (:policy :fast-safe) diff --git a/version.lisp-expr b/version.lisp-expr index d4bb21c..eefb885 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -17,4 +17,4 @@ ;;; checkins which aren't released. (And occasionally for internal ;;; versions, especially for internal versions off the main CVS ;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".) -"1.0.37.42" +"1.0.37.43"