[clang] [Clang] Overflow Pattern Exclusions (PR #100272)
Vitaly Buka via cfe-commits
cfe-commits at lists.llvm.org
Fri Aug 16 13:16:28 PDT 2024
vitalybuka wrote:
> > Can we split `-fsanitize=unsigned-integer-overflow` into `-fsanitize=unsigned-integer-overflow-patternA,unsigned-integer-overflow-patternB,unsigned-integer-overflow-patternC...` ?
> > Then it's quite intuitive to disable them with `no-sanitize`.
>
> Yikes, no way. The pattern exclusions apply to all of the overflow-related sanitizers. Each is a small behavioral difference; they're not separate sanitizers nor do they apply to only one sanitizer.
That's a strong argument, such explanation is good enough to move forward.
>
> If `-fsanitize-pattern-exclusion` isn't wanted, perhaps `-fsanitize-overflow=pattern-exclude-{none,all,add-overflow-test,post-decr-while,negated-unsigned-const}`? But I still prefer it as-as.
historically we for modifieres we used `-fsanitize-<sanitizer>-<modifier>`, e.g. `-fsanitize-address-outline-instrumentation` or `-fsanitize-address-use-after-return` `-fsanitize-memory-track-origins`
Then `-fsanitize-undefined-exclude-overflow-pattern=none|all|.....`
I slightly prefer `exclude` -> `ignore`
https://github.com/llvm/llvm-project/pull/100272
More information about the cfe-commits
mailing list