mirror of
https://github.com/justinethier/cyclone.git
synced 2025-07-07 13:16:34 +02:00
Exclude lib init from inlinable top level funcs
This commit is contained in:
parent
b27dab456d
commit
9f26868ef0
1 changed files with 14 additions and 12 deletions
|
@ -218,9 +218,11 @@
|
||||||
|
|
||||||
;; Identify native Scheme functions that can be inlined
|
;; Identify native Scheme functions that can be inlined
|
||||||
(define inlinable-scheme-fncs '())
|
(define inlinable-scheme-fncs '())
|
||||||
|
(let ((lib-init-fnc (lib:name->symbol lib-name))) ;; safe to ignore for programs
|
||||||
(for-each
|
(for-each
|
||||||
(lambda (e)
|
(lambda (e)
|
||||||
(when (inlinable-top-level-function? e)
|
(when (and (not (equal? (define->var e) lib-init-fnc))
|
||||||
|
(inlinable-top-level-function? e))
|
||||||
(set! inlinable-scheme-fncs
|
(set! inlinable-scheme-fncs
|
||||||
(cons (define->var e) inlinable-scheme-fncs))
|
(cons (define->var e) inlinable-scheme-fncs))
|
||||||
;; TESTING, will not work yet
|
;; TESTING, will not work yet
|
||||||
|
@ -229,7 +231,7 @@
|
||||||
(prim:add-udf! (define->var e) (define-c->inline-var e))
|
(prim:add-udf! (define->var e) (define-c->inline-var e))
|
||||||
;; END
|
;; END
|
||||||
))
|
))
|
||||||
input-program)
|
input-program))
|
||||||
(trace:info "---------------- results of inlinable-top-level-function analysis: ")
|
(trace:info "---------------- results of inlinable-top-level-function analysis: ")
|
||||||
(trace:info inlinable-scheme-fncs)
|
(trace:info inlinable-scheme-fncs)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue