mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 19:23:23 +01:00
SLPVectorizer: Use vector type for vectorized memory operations
No test case, because with the current cost model we don't see a difference. An upcoming ARM memory cost model change will expose and test this bug. radar://15332579 llvm-svn: 193572
This commit is contained in:
parent
ebf56c2f5f
commit
6f22639253
@ -1023,14 +1023,14 @@ int BoUpSLP::getEntryCost(TreeEntry *E) {
|
||||
// Cost of wide load - cost of scalar loads.
|
||||
int ScalarLdCost = VecTy->getNumElements() *
|
||||
TTI->getMemoryOpCost(Instruction::Load, ScalarTy, 1, 0);
|
||||
int VecLdCost = TTI->getMemoryOpCost(Instruction::Load, ScalarTy, 1, 0);
|
||||
int VecLdCost = TTI->getMemoryOpCost(Instruction::Load, VecTy, 1, 0);
|
||||
return VecLdCost - ScalarLdCost;
|
||||
}
|
||||
case Instruction::Store: {
|
||||
// We know that we can merge the stores. Calculate the cost.
|
||||
int ScalarStCost = VecTy->getNumElements() *
|
||||
TTI->getMemoryOpCost(Instruction::Store, ScalarTy, 1, 0);
|
||||
int VecStCost = TTI->getMemoryOpCost(Instruction::Store, ScalarTy, 1, 0);
|
||||
int VecStCost = TTI->getMemoryOpCost(Instruction::Store, VecTy, 1, 0);
|
||||
return VecStCost - ScalarStCost;
|
||||
}
|
||||
default:
|
||||
|
Loading…
Reference in New Issue
Block a user