[PATCH] D113853: [X86][Costmodel] `getReplicationShuffleCost()`: promote 8 bit-wide elements to 32 bit when no AVX512VBMI

Roman Lebedev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Nov 14 10:15:15 PST 2021


lebedev.ri created this revision.
lebedev.ri added a reviewer: RKSimon.
lebedev.ri added a project: LLVM.
Herald added subscribers: pengfei, hiraditya.
lebedev.ri requested review of this revision.

Currently `X86TTIImpl::getInterleavedMemoryOpCostAVX512()` asks about i8 elt type,
so this change does affect vectorization. In the end, it will ask about i1.

We should also try to promote to i16 if we have AVX512BW, i'll do that in a follow-up.
All costs here look good, i've added the missing truncation costs in preparatory patches.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D113853

Files:
  llvm/lib/Target/X86/X86TargetTransformInfo.cpp
  llvm/test/Analysis/CostModel/X86/interleaved-store-accesses-with-gaps.ll
  llvm/test/Analysis/CostModel/X86/shuffle-replication-i8.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D113853.387107.patch
Type: text/x-patch
Size: 161408 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211114/18a52293/attachment-0001.bin>


More information about the llvm-commits mailing list