mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-12 01:25:10 +00:00
Enabled cost calculation for masked memory operations.
We already have implementation for cost calculation for masked memory operations. I just call it from the loop vectorizer. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229290 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -4912,7 +4912,11 @@ LoopVectorizationCostModel::getInstructionCost(Instruction *I, unsigned VF) {
|
||||
|
||||
// Wide load/stores.
|
||||
unsigned Cost = TTI.getAddressComputationCost(VectorTy);
|
||||
Cost += TTI.getMemoryOpCost(I->getOpcode(), VectorTy, Alignment, AS);
|
||||
if (Legal->isMaskRequired(I))
|
||||
Cost += TTI.getMaskedMemoryOpCost(I->getOpcode(), VectorTy, Alignment,
|
||||
AS);
|
||||
else
|
||||
Cost += TTI.getMemoryOpCost(I->getOpcode(), VectorTy, Alignment, AS);
|
||||
|
||||
if (Reverse)
|
||||
Cost += TTI.getShuffleCost(TargetTransformInfo::SK_Reverse,
|
||||
|
Reference in New Issue
Block a user