In SCEVExpander FactorOutConstant(), when GEP indexing into/over scalable vector,
it is legal for the 'Factor' in a MulExpr to be the size of a scalable vector
instead of a compile-time constant.
Current upstream crash with the test attached.
Paths
| Differential D80973
[LSR][SCEVExpander] Avoid blind cast 'Factor' to SCEVConstant in FactorOutConstant. ClosedPublic Authored by huihuiz on Jun 1 2020, 8:46 PM.
Details Summary In SCEVExpander FactorOutConstant(), when GEP indexing into/over scalable vector, Current upstream crash with the test attached.
Diff Detail
Event TimelineComment Actions What does expandAddToGEP actually end up doing in your testcase? If it's not generating ideal code, we might want to leave a FIXME pointing that out. Comment Actions Thanks Eli for pointing this out! In the test case provided, the generated IR is less ideal with base 'scalar_vector' cast to i8* and do uglygep over it. This revision is now accepted and ready to land.Jun 4 2020, 9:07 AM Closed by commit rGbd43f78c7663: [LSR][SCEVExpander] Avoid blind cast 'Factor' to SCEVConstant in… (authored by huihuiz). · Explain WhyJun 4 2020, 11:00 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 268534 llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp
llvm/test/Transforms/LoopStrengthReduce/vscale-factor-out-constant.ll
|