Skip to content

frontend and ir optimizations#239

Open
kmerrill18 wants to merge 2 commits intocircify:masterfrom
sschefflab:circ-optimizations
Open

frontend and ir optimizations#239
kmerrill18 wants to merge 2 commits intocircify:masterfrom
sschefflab:circ-optimizations

Conversation

@kmerrill18
Copy link
Copy Markdown
Contributor

I noticed that circ was taking a really long time to compile relatively simple zokrates files. These files just had large numbers of loops and large numbers of constants. The following optimizations sped up compile-time significantly.

  1. frontend - reduce calls to constant_fold to only when necessary.
  2. ir - skip rebuilding a node if it is the same as it was before. If all children are unchanged, return the existing node directly instead of rebuilding it.

Drive-by: fix an issue with driver.py that incorrectly adds --debug when trying to run in debug mode.

@kmerrill18 kmerrill18 marked this pull request as draft May 4, 2026 02:25
@kmerrill18 kmerrill18 marked this pull request as ready for review May 4, 2026 02:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant