-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
[GCLowering] Fix phis of unions #26989
Merged
Merged
Conversation
This file contains 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
vchuravy
reviewed
May 5, 2018
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.
Thanks Keno! This does indeed fix the issue I noticed.
The only other thing I am seeing on LLVM 6 with the new optimizer enabled is:
Test Failed at /scratch/vchuravy/julia/usr/share/julia/stdlib/v0.7/SparseArrays/test/higherorderfns.jl:269
Expression: #= /scratch/vchuravy/julia/usr/share/julia/stdlib/v0.7/SparseArrays/test/higherorderfns.jl:269 =# @allocated
(broadcast!(f, Q, X, Y, Z)) == 0
Evaluated: 16 == 0
which I suppose is meant to be fixed by 26990?
No, that's #26981. |
CI failures look related. Will take a look. |
We stopped using these a while ago when we switched to using LiveSet diffs for computing where to root values.
The fact that this was absent was masking a bug (fixed in a previous commit). Now, we don't currently allow any safepoints or allocations before the call to the ptls getter, but in the future we may want to do things like callee-rooted arguments, which would have to be rooted across the ptls getter if it were a safepoint. With the bug fixed, we can proactively add this to the list of known non-safepoints.
This fixes gc lowering for phis of the form: ``` %phi = phi {%jl_value_t addrspace(10)*, i8} [%aunion, %a], [%bunion, %b] ``` This kind of struct (used by the tagged union representation) has special support in GC lowering. After optimization, these structs often survive quite far as a struct (i.e. the destructuring of them is often elided). We simply need to extend this support to the cases that handle phi and select nodes. Fixes crashes with the new optimizer enabled noted in #26925
OSX CI failure seems unrelated:
|
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 fixes gc lowering for phis of the form:
This kind of struct (used by the tagged union representation) has special support
in GC lowering. After optimization, these structs often survive quite far as a
struct (i.e. the destructuring of them is often elided). We simply need to extend
this support to the cases that handle phi and select nodes.
Fixes crashes with the new optimizer enabled noted in #26925