Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a pass to optimize environment conversion #195

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

alaviss
Copy link
Contributor

@alaviss alaviss commented Jun 28, 2021

In each CPS legs, we take a Continuation then convert it into Env
everytime we want to access a local. This is an extremely slow process
under arc/orc due to type checks.

Add a pass that convert the continuation symbol exactly once, with hopes
that it would speed things up for us.

It doesn't seem to improve performance.nim with --objChecks:on at all though :(

Draft because we might want to only use this under -d:release and that I couldn't
see an improvement with performance.nim. Theoretically a loop in cps will perform
better, but I haven't tested.

Fixes #184

In each CPS legs, we take a Continuation then convert it into Env
everytime we want to access a local. This is an extremely slow process
under arc/orc due to type checks.

Add a pass that convert the continuation symbol exactly once, with hopes
that it would speed things up for us.
@disruptek disruptek added the optimization obfuscation and enbrittlement label Jul 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
optimization obfuscation and enbrittlement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Figure out a way to convert Continuation to Env only once per continuation
2 participants