1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-22 12:30:32 +02:00

re-enable assembly packing

* module/language/glil/compile-assembly.scm (glil->assembly): Enable
  assembly packing, for e.g. (make-int8:0).
This commit is contained in:
Andy Wingo 2009-02-14 18:57:30 +01:00
parent 81600208f4
commit 194566b0ec
2 changed files with 4 additions and 4 deletions

View file

@ -66,11 +66,11 @@
(map (lambda (x) (cons (cdr x) (car x))) *abbreviations*)) (map (lambda (x) (cons (cdr x) (car x))) *abbreviations*))
(define (assembly-pack code) (define (assembly-pack code)
(or (assoc-ref code *abbreviations*) (or (assoc-ref *abbreviations* code)
code)) code))
(define (assembly-unpack code) (define (assembly-unpack code)
(or (assoc-ref code *expansions*) (or (assoc-ref *expansions* code)
code)) code))

View file

@ -137,9 +137,9 @@
(define (glil->assembly glil nargs nexts-stack bindings (define (glil->assembly glil nargs nexts-stack bindings
source-alist label-alist object-alist addr) source-alist label-alist object-alist addr)
(define (emit-code x) (define (emit-code x)
(values x bindings source-alist label-alist object-alist)) (values (map assembly-pack x) bindings source-alist label-alist object-alist))
(define (emit-code/object x object-alist) (define (emit-code/object x object-alist)
(values x bindings source-alist label-alist object-alist)) (values (map assembly-pack x) bindings source-alist label-alist object-alist))
(record-case glil (record-case glil
((<glil-program> nargs nrest nlocs nexts meta body closure-level) ((<glil-program> nargs nrest nlocs nexts meta body closure-level)