[CostModel][X86] Add shuffle costs for some common sub-128bit vectors
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 9 Apr 2020 18:55:51 +0000 (19:55 +0100)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 9 Apr 2020 18:57:06 +0000 (19:57 +0100)
commit12c629ec6c590ad71f3707735df5931dfb6a2496
tree475c4848b8ee2c7362f7586d9fcb222e19d8e1dd
parent8fbac4e1a2f2506671ca06226e4513a5965bdbf5
[CostModel][X86] Add shuffle costs for some common sub-128bit vectors

v2i8/v4i8/v8i8 + v2i16/v4i16 all show up in vectorizer code and by just using the legalized types (v16i8/v8i16) we're highly exaggerating the actual cost of the shuffle.
llvm/lib/Target/X86/X86TargetTransformInfo.cpp
llvm/test/Analysis/CostModel/X86/shuffle-broadcast.ll
llvm/test/Analysis/CostModel/X86/shuffle-insert_subvector.ll
llvm/test/Analysis/CostModel/X86/shuffle-reverse.ll
llvm/test/Analysis/CostModel/X86/shuffle-single-src.ll
llvm/test/Analysis/CostModel/X86/shuffle-transpose.ll
llvm/test/Analysis/CostModel/X86/shuffle-two-src.ll