D92270 updated constant expression folding to fold inbounds GEP to
poison if the base is undef. Apply the same logic to SimplifyGEPInst.
The justification is that we can choose an out-of-bounds pointer as base
pointer.
Paths
| Differential D117015
[InstSimplify] Fold inbounds GEP to poison if base is undef. ClosedPublic Authored by fhahn on Jan 11 2022, 5:45 AM.
Details Summary D92270 updated constant expression folding to fold inbounds GEP to The justification is that we can choose an out-of-bounds pointer as base
Diff Detail
Event TimelineThis revision is now accepted and ready to land.Jan 11 2022, 5:48 AM Closed by commit rG8a469e20505f: [InstSimplify] Fold inbounds GEP to poison if base is undef. (authored by fhahn). · Explain WhyJan 11 2022, 8:23 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 398960 llvm/lib/Analysis/InstructionSimplify.cpp
llvm/test/Transforms/InstSimplify/gep.ll
|