Since D46637 we are better at handling uniform/non-uniform constant Pow2 detection; this patch tweaks the SLP argument handling to support them.
As SLP works with arrays of values I don't think we can easily use the pattern match helpers here.
Paths
| Differential D48214
[SLPVectorizer] Recognise non uniform power of 2 constants ClosedPublic Authored by RKSimon on Jun 15 2018, 3:49 AM.
Details Summary Since D46637 we are better at handling uniform/non-uniform constant Pow2 detection; this patch tweaks the SLP argument handling to support them. As SLP works with arrays of values I don't think we can easily use the pattern match helpers here.
Diff Detail
Event TimelineThis revision is now accepted and ready to land.Jun 26 2018, 8:58 AM Closed by commit rL335621: [SLPVectorizer] Recognise non uniform power of 2 constants (authored by RKSimon). · Explain WhyJun 26 2018, 9:25 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 151485 lib/Transforms/Vectorize/SLPVectorizer.cpp
test/Transforms/SLPVectorizer/X86/powof2div.ll
|
if (Op2VP == TargetTransformInfo::OP_PowerOf2 && !CInt->getValue().isPowerOf2())