llvm-project icon indicating copy to clipboard operation
llvm-project copied to clipboard

Couldn't join subrange unreachable hit

Open arsenm opened this issue 9 years ago • 8 comments

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

arsenm avatar May 24 '17 12:05 arsenm

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.

dstutt avatar Nov 06 '18 09:11 dstutt

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

arsenm avatar Nov 02 '18 17:11 arsenm

See https://reviews.llvm.org/D35073

dstutt avatar Jul 06 '17 17:07 dstutt

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).

dstutt avatar Jul 06 '17 17:07 dstutt

My fix for the attachment I've just uploaded appears to also fix the first example uploaded to this bug.

dstutt avatar Jul 06 '17 17:07 dstutt

Another example of this type of bug Found another example. I've got a potential fix for this one.

dstutt avatar Jul 06 '17 17:07 dstutt

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

dstutt avatar Jun 22 '17 15:06 dstutt

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.

dstutt avatar Jun 20 '17 09:06 dstutt