-
Notifications
You must be signed in to change notification settings - Fork 816
Precompute: Rewrite logic for handling children to carefully decide which to keep #7863
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
Merged
Merged
Changes from all commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
a7bd493
start
kripken 3dd86d7
more
kripken 4a37746
work
kripken 61f3d1b
work
kripken 0535544
work
kripken ddd6bb4
work
kripken 8a3e1c7
work
kripken a717eb5
work
kripken cb833e9
work
kripken baa0ede
work
kripken 7b249a3
work
kripken f950f43
work
kripken 033f780
text
kripken 9196308
work
kripken 22fb8c9
test
kripken 23a25b5
test
kripken c08586a
fix
kripken 85f635b
format
kripken 6251e93
test
kripken 6cd0ff1
test
kripken 5fed017
test
kripken 90d5ea2
fix
kripken eaa6a01
test
kripken 95d149a
comments
kripken da8f9e5
Merge remote-tracking branch 'origin/main' into precompute.drop
kripken 777a014
test
kripken 2c67d84
work
kripken f469916
work
kripken f861fe3
work
kripken 6eb438d
work
kripken 63ca25a
simpl
kripken 690aedc
simpl
kripken 04b6b17
Update src/passes/Precompute.cpp
kripken 0c9d61a
Update src/passes/Precompute.cpp
kripken 7ce4b7f
Update test/lit/passes/precompute-gc.wast
kripken 9cc8dc7
feedback
kripken bdd29f7
Merge remote-tracking branch 'myself/precompute.drop' into precompute…
kripken File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can use
insert
with a placeholder null data in place of the originalheapValues.map.find
to avoid the second lookup here.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, I see what you mean, but this code feels complex enough to me that I'd rather not add that? That is, I feel the current code is easier to read, even if slightly less efficient.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it would be more complicated! It even gives you a nice
inserted
bool to check rather than comparing againstheapValues.map.end()
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Difference of opinion I guess 😄 To me, starting with "insert into the map, just a placeholder we'll fill in later" feels odd, when mentally the situation at the start is "ok, let's see if this is already in the map".