Call CPS optimization code from main program

This commit is contained in:
Justin Ethier 2016-03-10 21:29:47 -05:00
parent 4c2b56b19e
commit c44d5d5427
2 changed files with 7 additions and 5 deletions

View file

@ -211,7 +211,12 @@
;; phase 5 - common subexpression elimination
;; TODO: re-run phases again until program is stable (less than n opts made, more than r rounds performed, etc)
;; END CPS optimization
(set! input-program
(map
cps-optimize-01
input-program))
(trace:info "---------------- after cps optimizations:")
(trace:info input-program) ;pretty-print
(set! input-program
(map

View file

@ -1458,10 +1458,7 @@
ast)
(else
(cps ast '%halt)))))
; ast-cps))
;; TODO: use for temporary testing of optimizations
;; eventually will want to call this explicitly from cyclone.scm
(cps-optimize-01 ast-cps)))
ast-cps))
;; CPS optimizations