[Git][cmucl/cmucl][issue-90-remove-unused-static-float-syms] Rename *fp-constant-0s0* to *fp-constant-0f0*

Raymond Toy gitlab at common-lisp.net
Mon Jan 4 17:20:22 UTC 2021



Raymond Toy pushed to branch issue-90-remove-unused-static-float-syms at cmucl / cmucl


Commits:
852e455b by Raymond Toy at 2021-01-04T09:18:59-08:00
Rename *fp-constant-0s0* to *fp-constant-0f0*

Besides the obvious, we need to update genesis to fill in the slot
with the correct value.

- - - - -


4 changed files:

- src/code/x86-vm.lisp
- src/compiler/generic/new-genesis.lisp
- src/compiler/x86/float-sse2.lisp
- src/compiler/x86/parms.lisp


Changes:

=====================================
src/code/x86-vm.lisp
=====================================
@@ -430,7 +430,7 @@
 ;;; cases. Note these are initialise by genesis as they are needed
 ;;; early.
 ;;;
-(defvar *fp-constant-0s0*)
+(defvar *fp-constant-0f0*)
 (defvar *fp-constant-0d0*)
 
 ;;; The current alien stack pointer; saved/restored for non-local


=====================================
src/compiler/generic/new-genesis.lisp
=====================================
@@ -914,22 +914,8 @@
       (macrolet ((frob (name pkg value)
 		   `(cold-setq (cold-intern (intern ,name ,pkg)) ,value)))
 	(frob "*FP-CONSTANT-0D0*" "X86" (number-to-core 0d0))
-	(frob "*FP-CONSTANT-1D0*" "X86" (number-to-core 1d0))
-	(frob "*FP-CONSTANT-0S0*" "X86" (number-to-core 0s0))
-	(frob "*FP-CONSTANT-1S0*" "X86" (number-to-core 1s0))
-	#+long-float
-	(when (c:backend-featurep :long-float)
-	  (frob "*FP-CONSTANT-0L0*" "X86" (number-to-core 0l0))
-	  (frob "*FP-CONSTANT-1L0*" "X86" (number-to-core 1l0))
-	  (frob "*FP-CONSTANT-PI*" "X86" (number-to-core pi))
-	  (frob "*FP-CONSTANT-L2T*" "X86" (number-to-core (log 10l0 2l0)))
-	  (frob "*FP-CONSTANT-L2E*" "X86"
-		(number-to-core
-		 (log 2.718281828459045235360287471352662L0 2l0)))
-	  (frob "*FP-CONSTANT-LG2*" "X86" (number-to-core (log 2l0 10l0)))
-	  (frob "*FP-CONSTANT-LN2*" "X86"
-		(number-to-core
-		 (log 2l0 2.718281828459045235360287471352662L0))))
+	(frob "*FP-CONSTANT-0F0*" "X86" (number-to-core 0f0))
+
 	(when (c:backend-featurep :gencgc)
 	  (frob "*SCAVENGE-READ-ONLY-SPACE*" "X86" (cold-intern nil)))))
 


=====================================
src/compiler/x86/float-sse2.lisp
=====================================
@@ -449,7 +449,7 @@
   (:results (y :scs (descriptor-reg)))
   (:generator 2
      (ecase (c::constant-value (c::tn-leaf x))
-       (0f0 (load-symbol-value y *fp-constant-0s0*))
+       (0f0 (load-symbol-value y *fp-constant-0f0*))
        #+nil
        (1f0 (load-symbol-value y *fp-constant-1s0*))
        (0d0 (load-symbol-value y *fp-constant-0d0*))


=====================================
src/compiler/x86/parms.lisp
=====================================
@@ -351,7 +351,7 @@
 
       ;; The FP constants
       *fp-constant-0d0*
-      *fp-constant-0s0*
+      *fp-constant-0f0*
 
       ;; Multi-process support.
       *control-stacks*



View it on GitLab: https://gitlab.common-lisp.net/cmucl/cmucl/-/commit/852e455b2a027776b8e50bd8dfee308ad41937e3

-- 
View it on GitLab: https://gitlab.common-lisp.net/cmucl/cmucl/-/commit/852e455b2a027776b8e50bd8dfee308ad41937e3
You're receiving this email because of your account on gitlab.common-lisp.net.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/cmucl-cvs/attachments/20210104/8af238cc/attachment-0001.html>


More information about the cmucl-cvs mailing list