This is an archive of the discontinued LLVM Phabricator instance.

[CodeGen] Fix crash in CodeGenPrepare::optimizeGatherScatterInst.
ClosedPublic

Authored by jcranmer-intel on May 22 2023, 12:39 PM.

Diff Detail

Event Timeline

Herald added a project: Restricted Project. · View Herald TranscriptMay 22 2023, 12:39 PM
Herald added a subscriber: hiraditya. · View Herald Transcript
jcranmer-intel requested review of this revision.May 22 2023, 12:39 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 22 2023, 12:39 PM
craig.topper added inline comments.May 22 2023, 12:44 PM
llvm/test/CodeGen/Generic/masked-gather-struct-gep.ll
3 ↗(On Diff #524435)

Can we just put the test in the X86 directory?

llvm/test/CodeGen/Generic/masked-gather-struct-gep.ll
3 ↗(On Diff #524435)

Sure, I just put it there because CodeGenPrepare isn't really target-specific, and I was cribbing the requires line from another test in this directory.

Move test to CodeGen/X86

craig.topper added inline comments.May 22 2023, 1:34 PM
llvm/test/CodeGen/X86/masked-gather-struct-gep.ll
2

Thinking about it again, don't we have test/Transforms/CodeGenPrepare/X86 ?

craig.topper added inline comments.May 22 2023, 1:36 PM
llvm/test/CodeGen/X86/masked-gather-struct-gep.ll
22

Should we return %gather so its not trivially dead?

Move test again, add return.

This revision is now accepted and ready to land.May 22 2023, 4:26 PM
This revision was landed with ongoing or failed builds.May 23 2023, 12:02 PM
This revision was automatically updated to reflect the committed changes.