[PATCH] D94501: [SelectionDAG] Support scalable-vector splats in more cases
Fraser Cormack via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 22 09:48:10 PST 2021
frasercrmck marked 2 inline comments as done.
frasercrmck added inline comments.
================
Comment at: llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp:5035
+ } else if (VT.isScalableVector()) {
+ Shift = DAG.getSplatVector(ShVT, dl, Shifts[0]);
+ Factor = DAG.getSplatVector(VT, dl, Factors[0]);
----------------
craig.topper wrote:
> frasercrmck wrote:
> > craig.topper wrote:
> > > Is there only one element in Shifts and Factors? If I'm reading matchUnaryPredicate right it will only see the single operand of the SPLAT_VECTOR so only call BuildSDIVPattern once?
> > Yes, that's how it's working. Is that strong enough a thing to rely upon, do you think?
> Can we put an assert on the size and everwhere else we access element 0 to make it clear we aren't dropping anything?
Yep, done
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D94501/new/
https://reviews.llvm.org/D94501
More information about the llvm-commits
mailing list