Skip to content

Commit 7ca41c8

Browse files
committed
whilewr/rw accept sme as well
1 parent 26349a7 commit 7ca41c8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1001,6 +1001,7 @@ AArch64TTIImpl::getIntrinsicInstrCost(const IntrinsicCostAttributes &ICA,
10011001
}
10021002
case Intrinsic::loop_dependence_raw_mask:
10031003
case Intrinsic::loop_dependence_war_mask:
1004+
// The whilewr/rw instructions require SVE2
10041005
if (ST->hasSVE2() || ST->hasSME())
10051006
return 1;
10061007
break;
@@ -5600,7 +5601,7 @@ InstructionCost AArch64TTIImpl::getPartialReductionCost(
56005601

56015602
bool AArch64TTIImpl::useSafeEltsMask() const {
56025603
// The whilewr/rw instructions require SVE2
5603-
return ST->hasSVE2();
5604+
return ST->hasSVE2() || ST->hasSME();
56045605
}
56055606

56065607
InstructionCost

0 commit comments

Comments
 (0)