Uh oh!
There was an error while loading. Please reload this page.
sanitizers: Implement support for the sanitize ignorelist - #157808
sanitizers: Implement support for the sanitize ignorelist#1578081c3t3a wants to merge 9 commits into
Conversation
rustbot
commented
Jun 12, 2026
Some changes occurred in tests/codegen-llvm/sanitizer cc @rcvalle |
This comment has been minimized.
This comment has been minimized.
624834b to
693e22fCompareUh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
This comment has been minimized.
This comment has been minimized.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
| RustString::build_byte_buffer(f) | ||
| } | ||
| pub(crate) struct SanitizerIgnoreList { |
There was a problem hiding this comment.
Can this be moved to the rustc_sanitizers crate? Maybe an ignorelist module there? Are there any other things that could be moved there?
There was a problem hiding this comment.
Yes it makes sense to live there. I just want to know that this relies on LLVM specific ffi calls and types. I replicated/moved the necessary pieces, but please take a look if it makes sense like this, alternatively rustc_sanitizer could be generic over these types and routines (a bit like rustc_codegen_ssa is), but it may be a bit ugly and similar amounts of code as if we don't move it :) I am fine with either!
Uh oh!
There was an error while loading. Please reload this page.
a24ff27 to
eeed708Comparerustbot
commented
Aug 27, 2026
These commits modify the If this was unintentional then you should revert the changes before this PR is merged. Some changes occurred in compiler/rustc_sanitizers cc @rcvalle |
rustbot
commented
Aug 27, 2026
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
This comment has been minimized.
This comment has been minimized.
The sanitize ignorelist gives central controls over which functions, files, etc. should be ignored and not sanitized. It is a common file format for clang and explained here: https://clang.llvm.org/docs/SanitizerSpecialCaseList.html. This change adds support for this list in Rust as well.
eeed708 to
066c9e1Compare| src:*src-ignore-memory.rs | ||
| [cfi] | ||
| fun:*test_cfi* |
There was a problem hiding this comment.
Do we have a concept of different CFI violation types in Rust?
I've just fixed that those get correctly reported by UBSAN here: llvm/llvm-project#213224, since then we can easily generate ignorelists if the type printed in there is the same as the section in the ignorelist.
So we should make sure that the output from UBSAN for CFI violations correspond to the section name for the ignore here.
There was a problem hiding this comment.
Good point! My understanding is that this commit should handle that correctly?
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
3f6de90 to
1cb8361Compare
This comment has been minimized.
This comment has been minimized.
1cb8361 to
a9e36d5Compare
View all comments
The sanitize ignorelist gives central controls over which functions, files, etc. should be ignored and not sanitized. It is a common file format for clang and explained here:
https://clang.llvm.org/docs/SanitizerSpecialCaseList.html. This change adds support for this list in Rust as well.
r? @rcvalle