rtl offsets have changed.
authorGuillermo J. Rozas <edu/mit/csail/zurich/gjr>
Thu, 1 Jul 1993 03:27:12 +0000 (03:27 +0000)
committerGuillermo J. Rozas <edu/mit/csail/zurich/gjr>
Thu, 1 Jul 1993 03:27:12 +0000 (03:27 +0000)
v7/src/compiler/rtlgen/rgcomb.scm
v7/src/compiler/rtlgen/rgrval.scm

index 5737950672b174cbf32afd9510ee79b1546b7790..7a885d49d96862a6084b56a1087d67e29dfdd115 100644 (file)
@@ -1,8 +1,8 @@
 #| -*-Scheme-*-
 
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/rtlgen/rgcomb.scm,v 4.17 1992/04/01 19:08:50 arthur Exp $
+$Id: rgcomb.scm,v 4.18 1993/07/01 03:27:04 gjr Exp $
 
-Copyright (c) 1988-1991 Massachusetts Institute of Technology
+Copyright (c) 1988-1993 Massachusetts Institute of Technology
 
 This material was developed by the Scheme project at the Massachusetts
 Institute of Technology, Department of Electrical Engineering and
@@ -133,13 +133,24 @@ MIT in each case. |#
        call-code
        (let ((locative
               (rtl:make-offset (rtl:make-fetch (interpreter-stack-pointer))
-                               (stack->memory-offset 0))))
+                               (rtl:make-machine-constant
+                                (stack->memory-offset 0)))))
          (scfg*scfg->scfg!
           (rtl:make-assignment
            locative
-           (rtl:make-byte-offset-address (rtl:make-fetch locative)
-                                         distance))
+           (rtl:bump-closure (rtl:make-fetch locative)
+                             (rtl:make-machine-constant distance)))
           call-code)))))
+
+(define (rtl:bump-closure closure distance)
+  #|
+  ;; We want this, but it doesn't type check.
+  ;; It is turned into this by a rewrite rule.
+  (rtl:make-byte-offset-address closure distance)
+  |#
+  (rtl:make-typed-cons:procedure
+   (rtl:make-byte-offset-address (rtl:make-object->address closure)
+                                distance)))
 \f
 (define (invocation/apply model operator frame-size continuation prefix)
   model operator                       ; ignored
index 4c8a2a5aa308318ba1c9eac16e9f5ab968aed6d7..284ad7089d7e2674402a35e13f1bbe2aaca8ced4 100644 (file)
@@ -1,8 +1,8 @@
 #| -*-Scheme-*-
 
-$Id: rgrval.scm,v 4.20 1992/11/18 00:47:09 gjr Exp $
+$Id: rgrval.scm,v 4.21 1993/07/01 03:27:12 gjr Exp $
 
-Copyright (c) 1988-1992 Massachusetts Institute of Technology
+Copyright (c) 1988-1993 Massachusetts Institute of Technology
 
 This material was developed by the Scheme project at the Massachusetts
 Institute of Technology, Department of Electrical Engineering and
@@ -276,9 +276,8 @@ MIT in each case. |#
                (closure-environment-adjustment nentries entry))))
          (if (back-end:= distance 0)
              expression
-             ;; This is cheaper than the obvious thing with object->address,
-             ;; etc.
-             (rtl:make-byte-offset-address expression distance)))))))
+             (rtl:bump-closure expression
+                               (rtl:make-machine-constant distance))))))))
 \f
 (define (make-non-trivial-closure-cons procedure block**)
   (let* ((block (procedure-closing-block procedure))