================
@@ -169,6 +169,22 @@ bool SemaAMDGPU::CheckAMDGCNBuiltinFunctionCall(const
TargetInfo &TI,
case AMDGPU::BI__builtin_amdgcn_s_setreg:
return SemaRef.BuiltinConstantArgRange(TheCall, /*ArgNum=*/0, /*Low=*/0,
/*High=*/UINT16_MAX);
+ case AMDGPU::BI__builtin_amdgcn_s_monitor_sleep: {
+ if (getLangOpts().CUDA && !getLangOpts().CUDAIsDevice)
+ return false;
+ bool NoSleepForever = Builtin::evaluateRequiredTargetFeatures(
+ "no-sleep-forever", CallerFeatureMap);
+ Expr *ArgExpr = TheCall->getArg(0);
+ if (ArgExpr->isInstantiationDependent())
+ return false;
+ llvm::APSInt Sleep;
----------------
arsenm wrote:
Can we replace all this code after #241583
https://github.com/llvm/llvm-project/pull/241042
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits