forked from OSchip/llvm-project
[CostModel][X86] SK_ExtractSubvector costs must only be tested for vector types (PR39615)
llvm-svn: 346589
This commit is contained in:
parent
9b8c102675
commit
d3ca710ec9
|
@ -874,7 +874,7 @@ int X86TTIImpl::getShuffleCost(TTI::ShuffleKind Kind, Type *Tp, int Index,
|
|||
|
||||
// Subvector extractions are free if they start at beginning of the
|
||||
// vector.
|
||||
if (Kind == TTI::SK_ExtractSubvector &&
|
||||
if (Kind == TTI::SK_ExtractSubvector && LT.second.isVector() &&
|
||||
((Index % LT.second.getVectorNumElements()) == 0))
|
||||
return 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue