mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-01 04:10:18 +02:00
-O1 disables call precoloring
* module/language/cps/compile-bytecode.scm (compile-function) (emit-bytecode): * module/language/cps/slot-allocation.scm (allocate-slots): * module/language/cps/optimize.scm (cps-default-optimization-options): Allow the "lazy vars" optimization, a form of slot precoloring, to be disabled. It will be disabled at -O0 or -O1, to speed compilation times.
This commit is contained in:
parent
2ab89102e7
commit
5675e46410
3 changed files with 12 additions and 7 deletions
|
@ -81,8 +81,9 @@
|
|||
(_ forwarding-labels)))
|
||||
cps empty-intmap)))
|
||||
|
||||
(define (compile-function cps asm)
|
||||
(let* ((allocation (allocate-slots cps))
|
||||
(define (compile-function cps asm opts)
|
||||
(let* ((allocation (allocate-slots cps #:precolor-calls?
|
||||
(kw-arg-ref opts #:precolor-calls? #t)))
|
||||
(forwarding-labels (compute-forwarding-labels cps allocation))
|
||||
(frame-size (lookup-nlocals allocation)))
|
||||
(define (forward-label k)
|
||||
|
@ -600,7 +601,7 @@
|
|||
(define (emit-bytecode exp env opts)
|
||||
(let ((asm (make-assembler)))
|
||||
(intmap-for-each (lambda (kfun body)
|
||||
(compile-function (intmap-select exp body) asm))
|
||||
(compile-function (intmap-select exp body) asm opts))
|
||||
(compute-reachable-functions exp 0))
|
||||
(values (link-assembly asm #:page-aligned? (kw-arg-ref opts #:to-file? #f))
|
||||
env
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue