refactor(ir): introduce VariableLookup for lightweight variable resolution#130
Open
erickcestari wants to merge 2 commits intodergoegge:masterfrom
Open
refactor(ir): introduce VariableLookup for lightweight variable resolution#130erickcestari wants to merge 2 commits intodergoegge:masterfrom
erickcestari wants to merge 2 commits intodergoegge:masterfrom
Conversation
f978cf1 to
c8d0efb
Compare
…ution This reduces overhead in mutators that only require variable type and scope information, avoiding full program validation/building.
c8d0efb to
0743f5e
Compare
Owner
|
Awesome, thank you! Would you mind adding the benchmarking tests as well? |
Contributor
Author
Yes, I'll add it soon! |
Contributor
Author
Added! |
…ookup This adds a benchmark file comparing ProgramBuilder::from_program against the new lightweight VariableLookup on 100k instructions, along with the criterion dev-dependency.
dec7eca to
d65a2fc
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This reduces overhead in mutators that only require variable type and scope information, avoiding full program validation/building.
These changes optimize the
inputMutatorby avoiding validating the full program only to get variable lookups.These are the results of running fuzzamoto for five hours:
+1.58% total exec
+1.31% coverage
+5.20% corpus
−1.96% stability
A naive benchmark shows that it is 6 times faster to use the
variableLookupinstead ofProgramBuilder.program_builder_100k time: [7.0090 ms 7.0274 ms 7.0463 ms]variable_lookup_100k time: [1.2774 ms 1.2834 ms 1.2907 ms]