Skip to content

Commit af44d87

Browse files
authored
[clang][SME] Remove folding of __arm_in_streaming_mode() (NFC) (#150917)
This is handled by the instcombine added in #147930; there is no need for any clang-specific folding. NFC as all clang tests for `__arm_in_streaming_mode()` used -O1, which applies the LLVM instcombines.
1 parent be17791 commit af44d87

File tree

1 file changed

+0
-13
lines changed
  • clang/lib/CodeGen/TargetBuiltins

1 file changed

+0
-13
lines changed

clang/lib/CodeGen/TargetBuiltins/ARM.cpp

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4922,19 +4922,6 @@ Value *CodeGenFunction::EmitAArch64SMEBuiltinExpr(unsigned BuiltinID,
49224922
if (Builtin->LLVMIntrinsic == 0)
49234923
return nullptr;
49244924

4925-
if (BuiltinID == SME::BI__builtin_sme___arm_in_streaming_mode) {
4926-
// If we already know the streaming mode, don't bother with the intrinsic
4927-
// and emit a constant instead
4928-
const auto *FD = cast<FunctionDecl>(CurFuncDecl);
4929-
if (const auto *FPT = FD->getType()->getAs<FunctionProtoType>()) {
4930-
unsigned SMEAttrs = FPT->getAArch64SMEAttributes();
4931-
if (!(SMEAttrs & FunctionType::SME_PStateSMCompatibleMask)) {
4932-
bool IsStreaming = SMEAttrs & FunctionType::SME_PStateSMEnabledMask;
4933-
return ConstantInt::getBool(Builder.getContext(), IsStreaming);
4934-
}
4935-
}
4936-
}
4937-
49384925
// Predicates must match the main datatype.
49394926
for (Value *&Op : Ops)
49404927
if (auto PredTy = dyn_cast<llvm::VectorType>(Op->getType()))

0 commit comments

Comments
 (0)