]> granicus.if.org Git - llvm/commit
[CostModel][X86] Add min/max reduction costs for all SSE targets
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Sat, 11 May 2019 17:12:52 +0000 (17:12 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Sat, 11 May 2019 17:12:52 +0000 (17:12 +0000)
commitab39cf6afa9acdc108d16e7194a0d82619b044d6
treeeb53dd48669d254f8a4e784b03d7e41898143704
parenta61c68b2e4ad2d5e011730d68a081d2977be7caf
[CostModel][X86] Add min/max reduction costs for all SSE targets

The original costs stopped at SSE42, I've added conservative estimates for everything down to SSE1/SSE2 and moved some of the SSE42 costs to SSE41 (really only the addition of PCMPGT makes any difference).

I've also added missing vXi8 costs (we use PHMINPOSUW for i8/i16 for scarily quick results) and 256-bit vector costs for AVX1.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@360528 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86TargetTransformInfo.cpp
test/Analysis/CostModel/X86/reduce-smax-widen.ll
test/Analysis/CostModel/X86/reduce-smax.ll
test/Analysis/CostModel/X86/reduce-smin-widen.ll
test/Analysis/CostModel/X86/reduce-smin.ll
test/Analysis/CostModel/X86/reduce-umax-widen.ll
test/Analysis/CostModel/X86/reduce-umax.ll
test/Analysis/CostModel/X86/reduce-umin-widen.ll
test/Analysis/CostModel/X86/reduce-umin.ll
test/Transforms/SLPVectorizer/X86/horizontal-minmax.ll