[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] 20/27: Scalar replacement for f64->scm

From: Andy Wingo
Subject: [Guile-commits] 20/27: Scalar replacement for f64->scm
Date: Wed, 11 Nov 2015 11:39:14 +0000

wingo pushed a commit to branch master
in repository guile.

commit c438998e481ae329c29bf70de4cc40a783e0baf0
Author: Andy Wingo <address@hidden>
Date:   Wed Oct 28 22:27:46 2015 +0000

    Scalar replacement for f64->scm
    * module/language/cps/cse.scm (compute-equivalent-subexpressions):
      Scalar replacement for float boxes.
 module/language/cps/cse.scm |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/module/language/cps/cse.scm b/module/language/cps/cse.scm
index 894f779..2e47f37 100644
--- a/module/language/cps/cse.scm
+++ b/module/language/cps/cse.scm
@@ -299,6 +299,14 @@ false.  It could be that both true and false proofs are 
              (add-def! `(primcall struct-ref ,struct ,n) val))
             (('primcall 'struct-set!/immediate struct n val)
              (add-def! `(primcall struct-ref/immediate ,struct ,n) val))
+            (('primcall 'scm->f64 scm)
+             (match defs
+               ((f64)
+                (add-def! `(primcall f64->scm ,f64) scm))))
+            (('primcall 'f64->scm f64)
+             (match defs
+               ((scm)
+                (add-def! `(primcall scm->f64 ,scm) f64))))
             (_ #t))))
       (define (visit-label label equiv-labels var-substs)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]