Couldn't join subrange unreachable hit
| Bugzilla Link | 33152 |
| Resolution | WORKSFORME |
| Resolved on | Nov 06, 2018 08:46 |
| Version | trunk |
| OS | All |
| Attachments | Testcase, Another example |
| CC | @dstutt,@MatzeB |
Extended Description
Matt - do you want to close this one then?
I'd expect the examples to pass given that there have been several fixes submitted around this area. I think the comments indicate that the examples here are expected to pass with latest trunk - given that the examples represented here were replicated in tests used to debug and implement fixes.
It might be worth either closing this bug and starting a new one for new cases of subrange failures or updating this one with a fresh example if you've discovered a different case. Either way, I think the examples here might be a little bit stale.
The test cases here don’t seem useful anymore. They compile for me once manually upgraded to trunk compatible IR, although it’s likely the original MIR might still fail
See https://reviews.llvm.org/D35073
Issue appears to be during the subrange join phase. It comes across this type of situation:
%other = COPY %ext %this = COPY %ext
A check already exists in JoinVals::analyzeValue but didn't work when in SubRangeJoin mode causing an unreachable to be triggered due to it not expecting to see a FullCopy with these characteristics (I suspect some cases will probably work).
My fix for the attachment I've just uploaded appears to also fix the first example uploaded to this bug.
Another example of this type of bug Found another example. I've got a potential fix for this one.
The latest patch for the fix for 33524 (https://reviews.llvm.org/D34391) also appears to fix the second example here (Another example). Attachment 18663
I've encountered this too for AMDGPU. See bug 33524
I've got a potential fix for this (although I'm not sure the approach I've taken is necessarily the right one) which I've uploaded for review (see bug 33524 for details). I tried the fix on the issues attached to this bug report but it didn't fix them - hence the reason for creating a new PR.