-
-
Notifications
You must be signed in to change notification settings - Fork 14.8k
Tracking issue for sanitizer support #39699
Copy link
Copy link
Open
Labels
A-CLIArea: Command-line interface (CLI) to the compilerArea: Command-line interface (CLI) to the compilerA-sanitizersArea: Sanitizers for correctness and code qualityArea: Sanitizers for correctness and code qualityB-unstableBlocker: Implemented in the nightly compiler and unstable.Blocker: Implemented in the nightly compiler and unstable.C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCS-tracking-needs-summaryStatus: It's hard to tell what's been done and what hasn't! Someone should do some investigation.Status: It's hard to tell what's been done and what hasn't! Someone should do some investigation.T-dev-toolsRelevant to the dev-tools subteam, which will review and decide on the PR/issue.Relevant to the dev-tools subteam, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-CLIArea: Command-line interface (CLI) to the compilerArea: Command-line interface (CLI) to the compilerA-sanitizersArea: Sanitizers for correctness and code qualityArea: Sanitizers for correctness and code qualityB-unstableBlocker: Implemented in the nightly compiler and unstable.Blocker: Implemented in the nightly compiler and unstable.C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCS-tracking-needs-summaryStatus: It's hard to tell what's been done and what hasn't! Someone should do some investigation.Status: It's hard to tell what's been done and what hasn't! Someone should do some investigation.T-dev-toolsRelevant to the dev-tools subteam, which will review and decide on the PR/issue.Relevant to the dev-tools subteam, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Currently we have:
A rustc flag,
-Z sanitizer, to sanitize rlibs (it adds an extra LLVM pass/attribute) and executables (it links to the sanitizer runtime). Added in LeakSanitizer, ThreadSanitizer, AddressSanitizer and MemorySanitizer support #38699.An attribute
#[no_sanitize]to disable sanitization on specific functions. Also lints if those functions are marked as requesting inlining. Added in Selectively disable sanitizer instrumentation #68164.#[no_sanitize]suppresses#[inline]hints. A lint is issued if combined with#[inline(always)].A few violations (false positives?) in the test runner
rustc --test) ThreadSanitizer detects a data race in the test runner (rustc --test) #39608rustc --test) MemorySanitizer detects an use of unitialized value in the test runner (rustc --test) #39610Known issues
Unresolved questions:
#[no_sanitize]or perhaps something like#[sanitize(never)]or some other variation? In particular, might we at some point want "positive options" like#[sanitize(miri(aggressive))]? There is much back and forth in Selectively disable sanitizer instrumentation #68164.