[all-commits] [llvm/llvm-project] dccd27: [ubsan] Connect -fsanitize-skip-hot-cutoff to Lowe...
Thurston Dang via All-commits
all-commits at lists.llvm.org
Wed Jan 29 21:03:48 PST 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: dccd27112722109d2e2f03e8da9ce8690f06e11b
https://github.com/llvm/llvm-project/commit/dccd27112722109d2e2f03e8da9ce8690f06e11b
Author: Thurston Dang <thurston at google.com>
Date: 2025-01-29 (Wed, 29 Jan 2025)
Changed paths:
M clang/include/clang/Basic/Sanitizers.h
M clang/lib/Basic/Sanitizers.cpp
M clang/lib/CodeGen/BackendUtil.cpp
M clang/lib/CodeGen/CGExpr.cpp
M clang/test/CodeGen/allow-ubsan-check-inline.c
M clang/test/CodeGen/allow-ubsan-check.c
Log Message:
-----------
[ubsan] Connect -fsanitize-skip-hot-cutoff to LowerAllowCheckPass<cutoffs> (#124857)
This adds the plumbing between -fsanitize-skip-hot-cutoff (introduced in
https://github.com/llvm/llvm-project/pull/121619) and
LowerAllowCheckPass<cutoffs> (introduced in
https://github.com/llvm/llvm-project/pull/124211).
The net effect is that -fsanitize-skip-hot-cutoff now combines the
functionality of -ubsan-guard-checks and
-lower-allow-check-percentile-cutoff (though this patch does not remove
those yet), and generalizes the latter to allow per-sanitizer cutoffs.
Note: this patch replaces Intrinsic::allow_ubsan_check's
SanitizerHandler parameter with SanitizerOrdinal; this is necessary
because the hot cutoffs are specified in terms of SanitizerOrdinal
(e.g., null, alignment), not SanitizerHandler (e.g., TypeMismatch).
Likewise, CodeGenFunction::EmitCheck is changed to emit
allow_ubsan_check() for each individual check.
---------
Co-authored-by: Vitaly Buka <vitalybuka at gmail.com>
Co-authored-by: Vitaly Buka <vitalybuka at google.com>
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list