runtime system's rb-tree and hash-table abstractions.
#| -*-Scheme-*-
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/back/symtab.scm,v 1.44 1990/05/03 14:59:34 jinx Rel $
+$Id: symtab.scm,v 1.45 1993/10/12 07:27:12 cph Exp $
-Copyright (c) 1987, 1990 Massachusetts Institute of Technology
+Copyright (c) 1987-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
(declare (usual-integrations))
\f
(define (make-symbol-table)
- (symbol-hash-table/make 1009))
+ (make-eq-hash-table))
(define (symbol-table-define! table key value)
- (symbol-hash-table/modify! table key
- (lambda (binding)
- (error "symbol-table-define!: Redefining" key)
- (set-binding-value! binding value)
- binding)
- (lambda ()
- (make-binding value))))
+ (let ((binding (hash-table/get table key #f)))
+ (if binding
+ (begin
+ (error "Redefining symbol:" key)
+ (set-binding-value! binding value))
+ (hash-table/put! table key (make-binding value)))))
(define (symbol-table-value table key)
- (symbol-hash-table/lookup* table key
- (lambda (binding)
- (or (binding-value binding)
- (error "SYMBOL-TABLE-VALUE: no value" key)))
- (lambda ()
- (error "SYMBOL-TABLE-VALUE: Undefined key" key))))
+ (let ((binding (hash-table/get table key #f)))
+ (if (not binding)
+ (error "Undefined key:" key))
+ (let ((value (binding-value binding)))
+ (if (not value)
+ (error "Key has no value:" key))
+ value)))
(define (symbol-table->assq-list table)
(map (lambda (pair)
(symbol-table-bindings table)))
(define-integrable (symbol-table-bindings table)
- (symbol-hash-table/bindings table))
+ (hash-table->alist table))
(define-integrable (make-binding initial-value)
(cons initial-value '()))
(car binding))
(define (set-binding-value! binding value)
- (set-car! binding value))
+ (set-car! binding value))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: infnew.scm,v 4.9 1992/12/29 19:51:57 gjr Exp $
+$Id: infnew.scm,v 4.10 1993/10/12 07:27:38 cph Exp $
-Copyright (c) 1988-1992 Massachusetts Institute of Technology
+Copyright (c) 1988-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
(define (info-generation-phase-3 expression procedures continuations
label-bindings external-labels)
- (let ((label-bindings (labels->dbg-labels label-bindings)))
- (let ((labels (make-btree)))
+ (let ((label-bindings (labels->dbg-labels label-bindings))
+ (no-datum '(NO-DATUM)))
+ (let ((labels (make-string-hash-table)))
(for-each (lambda (label-binding)
- (for-each (lambda (name)
- (btree-insert! labels string<? car name
- (lambda (name)
- (cons name (cdr label-binding)))
- (lambda (association)
- (error "redefining label" association))
- (lambda (association)
- association
- unspecific)))
+ (for-each (lambda (key)
+ (let ((datum
+ (hash-table/get labels key no-datum)))
+ (if (not (eq? datum no-datum))
+ (error "Redefining label:" key datum)))
+ (hash-table/put! labels
+ key
+ (cdr label-binding)))
(car label-binding)))
label-bindings)
(let ((map-label/fail
(lambda (label)
- (btree-lookup labels string<? car (system-pair-car label)
- cdr
- (lambda (name)
- (error "Missing label" name)))))
+ (let ((key (system-pair-car label)))
+ (let ((datum (hash-table/get labels key no-datum)))
+ (if (eq? datum no-datum)
+ (error "Missing label:" key))
+ datum))))
(map-label/false
(lambda (label)
- (btree-lookup labels string<? car (system-pair-car label)
- cdr
- (lambda (name)
- name ; ignored
- false)))))
+ (hash-table/get labels (system-pair-car label) #f))))
(for-each (lambda (label)
(set-dbg-label/external?! (map-label/fail label) true))
external-labels)
(set-dbg-procedure/label! procedure mapped-label)
(cond ((dbg-procedure/external-label procedure)
=> (lambda (label)
- (set-dbg-procedure/external-label! procedure
- (map-label/fail label))))
+ (set-dbg-procedure/external-label!
+ procedure
+ (map-label/fail label))))
((not mapped-label)
(error "Missing label" internal-label)))))
procedures)
(cons names
(make-dbg-label-2 (choose-distinguished-label names)
(car offset-binding)))))
- (let ((offsets (make-btree)))
+ (let ((offsets (make-rb-tree = <)))
(for-each (lambda (binding)
- (let ((name (system-pair-car (car binding))))
- (btree-insert! offsets < car (cdr binding)
- (lambda (offset)
- (list offset name))
- (lambda (offset-binding)
- (set-cdr! offset-binding
- (cons name (cdr offset-binding))))
- (lambda (offset-binding)
- offset-binding
- unspecific))))
+ (let ((offset (cdr binding))
+ (name (system-pair-car (car binding))))
+ (let ((datum (rb-tree/lookup offsets offset #f)))
+ (if datum
+ (set-cdr! datum (cons name (cdr datum)))
+ (rb-tree/insert! offsets offset (list name))))))
label-bindings)
- (btree-fringe offsets))))
+ (rb-tree->alist offsets))))
(define (choose-distinguished-label names)
(if (null? (cdr names))
#| -*-Scheme-*-
-$Id: make.scm,v 4.99 1993/07/01 03:11:07 gjr Exp $
+$Id: make.scm,v 4.100 1993/10/12 07:27:58 cph Exp $
Copyright (c) 1988-1993 Massachusetts Institute of Technology
(declare (usual-integrations))
(lambda (architecture-name)
+ (load-option 'HASH-TABLE)
+ (load-option 'RB-TREE)
(package/system-loader "comp" '() 'QUERY)
(let ((initialize-package!
(lambda (package-name)
(initialize-package! '(COMPILER DECLARATIONS)))
(add-system!
(make-system (string-append "Liar (" architecture-name ")")
- 4 99
+ 4 100
'())))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: compiler.cbf,v 1.1 1993/06/08 06:13:32 gjr Exp $
+$Id: compiler.cbf,v 1.2 1993/10/12 07:28:43 cph Exp $
-Copyright (c) 1992 Massachusetts Institute of Technology
+Copyright (c) 1992-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
;;;; Script to incrementally compile the compiler (from .bins)
-(for-each compile-directory
- '("back"
- "base"
- "fggen"
- "fgopt"
- "machines/C"
- "rtlbase"
- "rtlgen"
- "rtlopt"))
\ No newline at end of file
+(fluid-let ((compiler:coalescing-constant-warnings? #f))
+ (for-each compile-directory
+ '("back"
+ "base"
+ "fggen"
+ "fgopt"
+ "machines/C"
+ "rtlbase"
+ "rtlgen"
+ "rtlopt")))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: compiler.pkg,v 1.3 1993/08/26 06:29:30 gjr Exp $
+$Id: compiler.pkg,v 1.4 1993/10/12 07:28:44 cph Exp $
Copyright (c) 1992-1993 Massachusetts Institute of Technology
(define-package (compiler)
(files "base/switch"
- "base/hashtb"
"base/object" ;tagged object support
"base/enumer" ;enumerations
"base/sets" ;set abstraction
reference-context?
set-reference-context/offset!))
-(define-package (compiler balanced-binary-tree)
- (files "base/btree")
- (parent (compiler))
- (export (compiler)
- btree-delete!
- btree-fringe
- btree-insert!
- btree-lookup
- make-btree))
-
(define-package (compiler macros)
(files "base/macros")
(parent ())
#| -*-Scheme-*-
-$Id: decls.scm,v 1.1 1993/06/08 06:13:32 gjr Exp $
+$Id: decls.scm,v 1.2 1993/10/12 07:28:45 cph Exp $
-Copyright (c) 1992 Massachusetts Institute of Technology
+Copyright (c) 1992-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
(if (null? filenames)
(error "Can't find source files of compiler"))
(set! source-filenames filenames))
- (set! source-hash
- (make/hash-table
- 101
- string-hash-mod
- (lambda (filename source-node)
- (string=? filename (source-node/filename source-node)))
- make/source-node))
+ (set! source-hash (make-string-hash-table))
(set! source-nodes
(map (lambda (filename)
- (hash-table/intern! source-hash
- filename
- identity-procedure
- identity-procedure))
+ (if (not (hash-table/get source-hash filename #f))
+ (hash-table/put! source-hash
+ filename
+ (make/source-node filename))))
source-filenames))
(initialize/syntax-dependencies!)
(initialize/integration-dependencies!)
(modification-time false))
(define (filename->source-node filename)
- (hash-table/lookup source-hash
- filename
- identity-procedure
- (lambda () (error "Unknown source file" filename))))
+ (let ((node (hash-table/get source-hash filename #f)))
+ (if (not node)
+ (error "Unknown source file:" filename))
+ node))
(define (source-node/circular? node)
(memq node (source-node/backward-closure node)))
#| -*-Scheme-*-
-$Id: compiler.cbf,v 1.1 1992/08/29 13:51:17 jinx Exp $
+$Id: compiler.cbf,v 1.2 1993/10/12 07:29:15 cph Exp $
-Copyright (c) 1992 Digital Equipment Corporation (D.E.C.)
+Copyright (c) 1992-93 Digital Equipment Corporation (D.E.C.)
This software was developed at the Digital Equipment Corporation
Cambridge Research Laboratory. Permission to copy this software, to
;;;; Script to incrementally compile the compiler (from .bins)
-(for-each compile-directory
- '("back"
- "base"
- "fggen"
- "fgopt"
- "machines/alpha"
- "rtlbase"
- "rtlgen"
- "rtlopt"))
\ No newline at end of file
+(fluid-let ((compiler:coalescing-constant-warnings? #f))
+ (for-each compile-directory
+ '("back"
+ "base"
+ "fggen"
+ "fgopt"
+ "machines/alpha"
+ "rtlbase"
+ "rtlgen"
+ "rtlopt")))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: compiler.pkg,v 1.8 1993/08/26 06:33:56 gjr Exp $
+$Id: compiler.pkg,v 1.9 1993/10/12 07:29:15 cph Exp $
Copyright (c) 1992-1993 Digital Equipment Corporation (D.E.C.)
(define-package (compiler)
(files "base/switch"
- "base/hashtb"
"base/object" ;tagged object support
"base/enumer" ;enumerations
"base/sets" ;set abstraction
reference-context?
set-reference-context/offset!))
-(define-package (compiler balanced-binary-tree)
- (files "base/btree")
- (parent (compiler))
- (export (compiler)
- btree-delete!
- btree-fringe
- btree-insert!
- btree-lookup
- make-btree))
-
(define-package (compiler macros)
(files "base/macros")
(parent ())
#| -*-Scheme-*-
-$Id: decls.scm,v 1.3 1992/11/18 03:53:38 gjr Exp $
+$Id: decls.scm,v 1.4 1993/10/12 07:29:16 cph Exp $
-Copyright (c) 1992 Digital Equipment Corporation (D.E.C.)
+Copyright (c) 1992-93 Digital Equipment Corporation (D.E.C.)
This software was developed at the Digital Equipment Corporation
Cambridge Research Laboratory. Permission to copy this software, to
(if (null? filenames)
(error "Can't find source files of compiler"))
(set! source-filenames filenames))
- (set! source-hash
- (make/hash-table
- 101
- string-hash-mod
- (lambda (filename source-node)
- (string=? filename (source-node/filename source-node)))
- make/source-node))
+ (set! source-hash (make-string-hash-table))
(set! source-nodes
(map (lambda (filename)
- (hash-table/intern! source-hash
- filename
- identity-procedure
- identity-procedure))
+ (if (not (hash-table/get source-hash filename #f))
+ (hash-table/put! source-hash
+ filename
+ (make/source-node filename))))
source-filenames))
(initialize/syntax-dependencies!)
(initialize/integration-dependencies!)
(modification-time false))
(define (filename->source-node filename)
- (hash-table/lookup source-hash
- filename
- identity-procedure
- (lambda () (error "Unknown source file" filename))))
+ (let ((node (hash-table/get source-hash filename #f)))
+ (if (not node)
+ (error "Unknown source file:" filename))
+ node))
(define (source-node/circular? node)
(memq node (source-node/backward-closure node)))
#| -*-Scheme-*-
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/machines/bobcat/compiler.cbf,v 1.1 1988/11/05 22:31:00 cph Rel $
+$Id: compiler.cbf,v 1.2 1993/10/12 07:29:30 cph Exp $
-Copyright (c) 1988 Massachusetts Institute of Technology
+Copyright (c) 1988-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
;;;; Script to incrementally compile the compiler (from .bins)
-(for-each compile-directory
- '("back"
- "base"
- "fggen"
- "fgopt"
- "machines/bobcat"
- "rtlbase"
- "rtlgen"
- "rtlopt"))
\ No newline at end of file
+(fluid-let ((compiler:coalescing-constant-warnings? #f))
+ (for-each compile-directory
+ '("back"
+ "base"
+ "fggen"
+ "fgopt"
+ "machines/bobcat"
+ "rtlbase"
+ "rtlgen"
+ "rtlopt")))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: compiler.pkg,v 1.46 1993/08/26 06:27:45 gjr Exp $
+$Id: compiler.pkg,v 1.47 1993/10/12 07:29:31 cph Exp $
Copyright (c) 1988-1993 Massachusetts Institute of Technology
(define-package (compiler)
(files "base/switch"
- "base/hashtb"
"base/object" ;tagged object support
"base/enumer" ;enumerations
"base/sets" ;set abstraction
reference-context?
set-reference-context/offset!))
-(define-package (compiler balanced-binary-tree)
- (files "base/btree")
- (parent (compiler))
- (export (compiler)
- btree-delete!
- btree-fringe
- btree-insert!
- btree-lookup
- make-btree))
-
(define-package (compiler macros)
(files "base/macros")
(parent ())
#| -*-Scheme-*-
-$Id: decls.scm,v 4.34 1992/11/18 03:56:42 gjr Exp $
+$Id: decls.scm,v 4.35 1993/10/12 07:29:32 cph Exp $
-Copyright (c) 1988-1992 Massachusetts Institute of Technology
+Copyright (c) 1988-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
(if (null? filenames)
(error "Can't find source files of compiler"))
(set! source-filenames filenames))
- (set! source-hash
- (make/hash-table
- 101
- string-hash-mod
- (lambda (filename source-node)
- (string=? filename (source-node/filename source-node)))
- make/source-node))
+ (set! source-hash (make-string-hash-table))
(set! source-nodes
(map (lambda (filename)
- (hash-table/intern! source-hash
- filename
- identity-procedure
- identity-procedure))
+ (if (not (hash-table/get source-hash filename #f))
+ (hash-table/put! source-hash
+ filename
+ (make/source-node filename))))
source-filenames))
(initialize/syntax-dependencies!)
(initialize/integration-dependencies!)
(modification-time false))
(define (filename->source-node filename)
- (hash-table/lookup source-hash
- filename
- identity-procedure
- (lambda () (error "Unknown source file" filename))))
+ (let ((node (hash-table/get source-hash filename #f)))
+ (if (not node)
+ (error "Unknown source file:" filename))
+ node))
(define (source-node/circular? node)
(memq node (source-node/backward-closure node)))
#| -*-Scheme-*-
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/machines/i386/compiler.cbf,v 1.2 1992/02/28 20:23:57 jinx Exp $
+$Id: compiler.cbf,v 1.3 1993/10/12 07:29:41 cph Exp $
-Copyright (c) 1992 Massachusetts Institute of Technology
+Copyright (c) 1992-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
;;;; Script to incrementally compile the compiler (from .bins)
-(for-each compile-directory
- '("back"
- "base"
- "fggen"
- "fgopt"
- "machines/i386"
- "rtlbase"
- "rtlgen"
- "rtlopt"))
\ No newline at end of file
+(fluid-let ((compiler:coalescing-constant-warnings? #f))
+ (for-each compile-directory
+ '("back"
+ "base"
+ "fggen"
+ "fgopt"
+ "machines/i386"
+ "rtlbase"
+ "rtlgen"
+ "rtlopt")))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: compiler.pkg,v 1.18 1993/08/26 05:46:36 gjr Exp $
+$Id: compiler.pkg,v 1.19 1993/10/12 07:29:42 cph Exp $
Copyright (c) 1992-1993 Massachusetts Institute of Technology
(define-package (compiler)
(files "base/switch"
- "base/hashtb"
"base/object" ;tagged object support
"base/enumer" ;enumerations
"base/sets" ;set abstraction
reference-context?
set-reference-context/offset!))
-(define-package (compiler balanced-binary-tree)
- (files "base/btree")
- (parent (compiler))
- (export (compiler)
- btree-delete!
- btree-fringe
- btree-insert!
- btree-lookup
- make-btree))
-
(define-package (compiler macros)
(files "base/macros")
(parent ())
#| -*-Scheme-*-
-$Id: decls.scm,v 1.5 1993/07/16 19:27:46 gjr Exp $
+$Id: decls.scm,v 1.6 1993/10/12 07:29:43 cph Exp $
Copyright (c) 1992-1993 Massachusetts Institute of Technology
(if (null? filenames)
(error "Can't find source files of compiler"))
(set! source-filenames filenames))
- (set! source-hash
- (make/hash-table
- 101
- string-hash-mod
- (lambda (filename source-node)
- (string=? filename (source-node/filename source-node)))
- make/source-node))
+ (set! source-hash (make-string-hash-table))
(set! source-nodes
(map (lambda (filename)
- (hash-table/intern! source-hash
- filename
- identity-procedure
- identity-procedure))
+ (if (not (hash-table/get source-hash filename #f))
+ (hash-table/put! source-hash
+ filename
+ (make/source-node filename))))
source-filenames))
(initialize/syntax-dependencies!)
(initialize/integration-dependencies!)
(modification-time false))
(define (filename->source-node filename)
- (hash-table/lookup source-hash
- filename
- identity-procedure
- (lambda () (error "Unknown source file" filename))))
+ (let ((node (hash-table/get source-hash filename #f)))
+ (if (not node)
+ (error "Unknown source file:" filename))
+ node))
(define (source-node/circular? node)
(memq node (source-node/backward-closure node)))
#| -*-Scheme-*-
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/machines/mips/compiler.cbf,v 1.1 1990/05/07 04:11:13 jinx Rel $
+$Id: compiler.cbf,v 1.2 1993/10/12 07:29:52 cph Exp $
-Copyright (c) 1988, 1989, 1990 Massachusetts Institute of Technology
+Copyright (c) 1988-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
;;;; Script to incrementally compile the compiler (from .bins)
-(for-each compile-directory
- '("back"
- "base"
- "fggen"
- "fgopt"
- "machines/mips"
- "rtlbase"
- "rtlgen"
- "rtlopt"))
\ No newline at end of file
+(fluid-let ((compiler:coalescing-constant-warnings? #f))
+ (for-each compile-directory
+ '("back"
+ "base"
+ "fggen"
+ "fgopt"
+ "machines/mips"
+ "rtlbase"
+ "rtlgen"
+ "rtlopt")))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: compiler.pkg,v 1.16 1993/08/26 06:27:25 gjr Exp $
+$Id: compiler.pkg,v 1.17 1993/10/12 07:29:53 cph Exp $
Copyright (c) 1988-1993 Massachusetts Institute of Technology
(define-package (compiler)
(files "base/switch"
- "base/hashtb"
"base/object" ;tagged object support
"base/enumer" ;enumerations
"base/sets" ;set abstraction
reference-context?
set-reference-context/offset!))
-(define-package (compiler balanced-binary-tree)
- (files "base/btree")
- (parent (compiler))
- (export (compiler)
- btree-delete!
- btree-fringe
- btree-insert!
- btree-lookup
- make-btree))
-
(define-package (compiler macros)
(files "base/macros")
(parent ())
#| -*-Scheme-*-
-$Id: decls.scm,v 1.7 1992/11/18 03:51:47 gjr Exp $
+$Id: decls.scm,v 1.8 1993/10/12 07:29:53 cph Exp $
-Copyright (c) 1988-1992 Massachusetts Institute of Technology
+Copyright (c) 1988-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
(if (null? filenames)
(error "Can't find source files of compiler"))
(set! source-filenames filenames))
- (set! source-hash
- (make/hash-table
- 101
- string-hash-mod
- (lambda (filename source-node)
- (string=? filename (source-node/filename source-node)))
- make/source-node))
+ (set! source-hash (make-string-hash-table))
(set! source-nodes
(map (lambda (filename)
- (hash-table/intern! source-hash
- filename
- identity-procedure
- identity-procedure))
+ (if (not (hash-table/get source-hash filename #f))
+ (hash-table/put! source-hash
+ filename
+ (make/source-node filename))))
source-filenames))
(initialize/syntax-dependencies!)
(initialize/integration-dependencies!)
(modification-time false))
(define (filename->source-node filename)
- (hash-table/lookup source-hash
- filename
- identity-procedure
- (lambda () (error "Unknown source file" filename))))
+ (let ((node (hash-table/get source-hash filename #f)))
+ (if (not node)
+ (error "Unknown source file:" filename))
+ node))
(define (source-node/circular? node)
(memq node (source-node/backward-closure node)))
#| -*-Scheme-*-
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/machines/sparc/decls.scm,v 1.1 1993/06/08 06:11:02 gjr Exp $
-$MC68020-Header: decls.scm,v 4.27 90/05/03 15:17:08 GMT jinx Exp $
+$Id: decls.scm,v 1.2 1993/10/12 07:30:02 cph Exp $
-Copyright (c) 1988-91 Massachusetts Institute of Technology
+Copyright (c) 1988-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
(if (null? filenames)
(error "Can't find source files of compiler"))
(set! source-filenames filenames))
- (set! source-hash
- (make/hash-table
- 101
- string-hash-mod
- (lambda (filename source-node)
- (string=? filename (source-node/filename source-node)))
- make/source-node))
+ (set! source-hash (make-string-hash-table))
(set! source-nodes
(map (lambda (filename)
- (hash-table/intern! source-hash
- filename
- identity-procedure
- identity-procedure))
+ (if (not (hash-table/get source-hash filename #f))
+ (hash-table/put! source-hash
+ filename
+ (make/source-node filename))))
source-filenames))
(initialize/syntax-dependencies!)
(initialize/integration-dependencies!)
(modification-time false))
(define (filename->source-node filename)
- (hash-table/lookup source-hash
- filename
- identity-procedure
- (lambda () (error "Unknown source file" filename))))
+ (let ((node (hash-table/get source-hash filename #f)))
+ (if (not node)
+ (error "Unknown source file:" filename))
+ node))
(define (source-node/circular? node)
(memq node (source-node/backward-closure node)))
#| -*-Scheme-*-
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/machines/spectrum/compiler.cbf,v 1.1 1990/01/29 21:29:09 jinx Rel $
+$Id: compiler.cbf,v 1.2 1993/10/12 07:30:11 cph Exp $
-Copyright (c) 1988, 1989 Massachusetts Institute of Technology
+Copyright (c) 1988-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
;;;; Script to incrementally compile the compiler (from .bins)
-(for-each compile-directory
- '("back"
- "base"
- "fggen"
- "fgopt"
- "machines/spectrum"
- "rtlbase"
- "rtlgen"
- "rtlopt"))
\ No newline at end of file
+(fluid-let ((compiler:coalescing-constant-warnings? #f))
+ (for-each compile-directory
+ '("back"
+ "base"
+ "fggen"
+ "fgopt"
+ "machines/spectrum"
+ "rtlbase"
+ "rtlgen"
+ "rtlopt")))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: compiler.pkg,v 1.44 1993/08/26 06:26:56 gjr Exp $
+$Id: compiler.pkg,v 1.45 1993/10/12 07:30:11 cph Exp $
Copyright (c) 1988-1993 Massachusetts Institute of Technology
(define-package (compiler)
(files "base/switch"
- "base/hashtb"
"base/object" ;tagged object support
"base/enumer" ;enumerations
"base/sets" ;set abstraction
reference-context?
set-reference-context/offset!))
-(define-package (compiler balanced-binary-tree)
- (files "base/btree")
- (parent (compiler))
- (export (compiler)
- btree-delete!
- btree-fringe
- btree-insert!
- btree-lookup
- make-btree))
-
(define-package (compiler macros)
(files "base/macros")
(parent ())
#| -*-Scheme-*-
-$Id: decls.scm,v 4.32 1992/11/18 00:46:26 gjr Exp $
+$Id: decls.scm,v 4.33 1993/10/12 07:30:13 cph Exp $
-Copyright (c) 1988-1992 Massachusetts Institute of Technology
+Copyright (c) 1988-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
(if (null? filenames)
(error "Can't find source files of compiler"))
(set! source-filenames filenames))
- (set! source-hash
- (make/hash-table
- 101
- string-hash-mod
- (lambda (filename source-node)
- (string=? filename (source-node/filename source-node)))
- make/source-node))
+ (set! source-hash (make-string-hash-table))
(set! source-nodes
(map (lambda (filename)
- (hash-table/intern! source-hash
- filename
- identity-procedure
- identity-procedure))
+ (if (not (hash-table/get source-hash filename #f))
+ (hash-table/put! source-hash
+ filename
+ (make/source-node filename))))
source-filenames))
(initialize/syntax-dependencies!)
(initialize/integration-dependencies!)
(modification-time false))
(define (filename->source-node filename)
- (hash-table/lookup source-hash
- filename
- identity-procedure
- (lambda () (error "Unknown source file" filename))))
+ (let ((node (hash-table/get source-hash filename #f)))
+ (if (not node)
+ (error "Unknown source file:" filename))
+ node))
(define (source-node/circular? node)
(memq node (source-node/backward-closure node)))
#| -*-Scheme-*-
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/machines/vax/compiler.cbf,v 1.4 1991/02/15 00:41:03 jinx Exp $
+$Id: compiler.cbf,v 1.5 1993/10/12 07:30:28 cph Exp $
-Copyright (c) 1989, 1991 Massachusetts Institute of Technology
+Copyright (c) 1989-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
;;;; Script to incrementally compile the compiler (from .bins)
-(for-each compile-directory
- '("back"
- "base"
- "fggen"
- "fgopt"
- "machines/vax"
- "rtlbase"
- "rtlgen"
- "rtlopt"))
\ No newline at end of file
+(fluid-let ((compiler:coalescing-constant-warnings? #f))
+ (for-each compile-directory
+ '("back"
+ "base"
+ "fggen"
+ "fgopt"
+ "machines/vax"
+ "rtlbase"
+ "rtlgen"
+ "rtlopt")))
\ No newline at end of file
#| -*-Scheme-*-
-$Id: compiler.pkg,v 1.18 1993/08/26 06:33:36 gjr Exp $
+$Id: compiler.pkg,v 1.19 1993/10/12 07:30:28 cph Exp $
Copyright (c) 1988-1993 Massachusetts Institute of Technology
(define-package (compiler)
(files "base/switch"
- "base/hashtb"
"base/object" ;tagged object support
"base/enumer" ;enumerations
"base/sets" ;set abstraction
reference-context?
set-reference-context/offset!))
-(define-package (compiler balanced-binary-tree)
- (files "base/btree")
- (parent (compiler))
- (export (compiler)
- btree-delete!
- btree-fringe
- btree-insert!
- btree-lookup
- make-btree))
-
(define-package (compiler macros)
(files "base/macros")
(parent ())
#| -*-Scheme-*-
-$Id: decls.scm,v 4.10 1992/11/18 03:54:51 gjr Exp $
+$Id: decls.scm,v 4.11 1993/10/12 07:30:29 cph Exp $
-Copyright (c) 1987-1992 Massachusetts Institute of Technology
+Copyright (c) 1987-93 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
(if (null? filenames)
(error "Can't find source files of compiler"))
(set! source-filenames filenames))
- (set! source-hash
- (make/hash-table
- 101
- string-hash-mod
- (lambda (filename source-node)
- (string=? filename (source-node/filename source-node)))
- make/source-node))
+ (set! source-hash (make-string-hash-table))
(set! source-nodes
(map (lambda (filename)
- (hash-table/intern! source-hash
- filename
- identity-procedure
- identity-procedure))
+ (if (not (hash-table/get source-hash filename #f))
+ (hash-table/put! source-hash
+ filename
+ (make/source-node filename))))
source-filenames))
(initialize/syntax-dependencies!)
(initialize/integration-dependencies!)
(modification-time false))
(define (filename->source-node filename)
- (hash-table/lookup source-hash
- filename
- identity-procedure
- (lambda () (error "Unknown source file" filename))))
+ (let ((node (hash-table/get source-hash filename #f)))
+ (if (not node)
+ (error "Unknown source file:" filename))
+ node))
(define (source-node/circular? node)
(memq node (source-node/backward-closure node)))
#| -*-Scheme-*-
-$Id: rtlobj.scm,v 4.10 1992/09/30 19:22:47 cph Exp $
+$Id: rtlobj.scm,v 4.11 1993/10/12 07:28:23 cph Exp $
Copyright (c) 1988-92 Massachusetts Institute of Technology
\f
(define (make/label->object expression procedures continuations)
(let ((hash-table
- (symbol-hash-table/make
- (1+ (+ (length procedures) (length continuations))))))
+ (make-eq-hash-table
+ (+ (if expression 1 0)
+ (length procedures)
+ (length continuations)))))
(if expression
- (symbol-hash-table/insert! hash-table
- (rtl-expr/label expression)
- expression))
+ (hash-table/put! hash-table
+ (rtl-expr/label expression)
+ expression))
(for-each (lambda (procedure)
- (symbol-hash-table/insert! hash-table
- (rtl-procedure/label procedure)
- procedure))
+ (hash-table/put! hash-table
+ (rtl-procedure/label procedure)
+ procedure))
procedures)
(for-each (lambda (continuation)
- (symbol-hash-table/insert!
- hash-table
- (rtl-continuation/label continuation)
- continuation))
+ (hash-table/put! hash-table
+ (rtl-continuation/label continuation)
+ continuation))
continuations)
- (make/label->object* hash-table)))
-
-(define (make/label->object* hash-table)
- (lambda (label)
- (symbol-hash-table/lookup hash-table label)))
\ No newline at end of file
+ (lambda (label)
+ (let ((datum (hash-table/get hash-table label #f)))
+ (if (not datum)
+ (error "Undefined label:" label))
+ datum))))
\ No newline at end of file