[PATCH] D28118: AVX-512 cost calculation for interleave load/store patterns

Elena Demikhovsky via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 26 07:12:55 PST 2016


delena created this revision.
delena added reviewers: mkuper, Farhana.
delena added subscribers: llvm-commits, Ayal.
delena set the repository for this revision to rL LLVM.

X86 target does not provide any target specific cost calculation for interleave patterns. It uses the common target-independent calculation, which gives very high numbers.
As a result, the scalar version is chosen in many cases. The situation on AVX-512 is even worse, since we have 3-src shuffles that significantly reduce the cost.

In this patch I calculate the cost on AVX-512. It will allow to compare interleave pattern with gather/scatter and choose a better solution (PR31426).


Repository:
  rL LLVM

https://reviews.llvm.org/D28118

Files:
  ../include/llvm/Analysis/TargetTransformInfo.h
  ../include/llvm/CodeGen/BasicTTIImpl.h
  ../lib/Target/X86/X86TargetTransformInfo.cpp
  ../lib/Target/X86/X86TargetTransformInfo.h
  ../test/Analysis/CostModel/X86/interleave-load-i32.ll
  ../test/Analysis/CostModel/X86/interleave-store-i32.ll
  ../test/Analysis/CostModel/X86/strided-load-i16.ll
  ../test/Analysis/CostModel/X86/strided-load-i32.ll
  ../test/Analysis/CostModel/X86/strided-load-i64.ll
  ../test/Analysis/CostModel/X86/strided-load-i8.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D28118.82501.patch
Type: text/x-patch
Size: 43293 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161226/809ca345/attachment.bin>


More information about the llvm-commits mailing list