Before this patch Args was used to pass a broadcat's arguments by SLP.
This patch changes this. Args is now used for passing the operands of
the shuffle.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
I committed the new tests I had under rG091c2f953dd6, if you don't mind rebasing.
llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp | ||
---|---|---|
2607 | I think I would go for Args.size() > 0 && isa<LoadInst>(Args[0]). The second operand may be undef, but a broadcast is going to be coming from the first operand for any shuffle close to canonical. |
Thanks. LGTM
llvm/test/Analysis/CostModel/AArch64/shuffle-load.ll | ||
---|---|---|
38–44 | Yeah that sounds OK to me. FP16 was added in Arm8.2-a, and before that the costs are sometimes a little funny, because the types are not legal. For a broadcast load a ld1r isnt affected by the type though (just the size), so it should be OK to treat them as cheap. |
I think I would go for Args.size() > 0 && isa<LoadInst>(Args[0]). The second operand may be undef, but a broadcast is going to be coming from the first operand for any shuffle close to canonical.