================
@@ -3615,9 +3616,12 @@ void CodeGenFunction::EmitCheck(
if (!CGM.getCodeGenOpts().SanitizeMergeHandlers.has(Checked[i].second))
NoMerge = true;
+
+ if (!CGM.getCodeGenOpts().NoSanitizeTopHot.has(Checked[i].second))
+ SanitizeGuardChecks = true;
}
- if (ClSanitizeGuardChecks) {
+ if (SanitizeGuardChecks) {
llvm::Value *Allow =
Builder.CreateCall(CGM.getIntrinsic(llvm::Intrinsic::allow_ubsan_check),
llvm::ConstantInt::get(CGM.Int8Ty, CheckHandler));
----------------
thurstond wrote:
Instead of passing CheckHandler, can I pass the sanitizer cutoff threshold
instead?
Something like
```
Builder.CreateCall(CGM.getIntrinsic(llvm::Intrinsic::allow_ubsan_check),
llvm::ConstantInt::get(CGM.Int8Ty,
NoSanitizeTopHot[someIndex]));
```
https://github.com/llvm/llvm-project/pull/121619
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits