diff options
author | Alexey Samsonov <vonosmas@gmail.com> | 2025-07-24 14:15:46 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-07-24 14:15:46 -0700 |
commit | 5e01797cd035cd1b86beb0ad3fb24277531dff66 (patch) | |
tree | 81c3e477f13a1caa5216210da47baf2d64a6c7eb /llvm/unittests/Support/DebugCounterTest.cpp | |
parent | 29e8599aa9609c1e1bc019d384a96be9333101d8 (diff) | |
download | llvm-5e01797cd035cd1b86beb0ad3fb24277531dff66.zip llvm-5e01797cd035cd1b86beb0ad3fb24277531dff66.tar.gz llvm-5e01797cd035cd1b86beb0ad3fb24277531dff66.tar.bz2 |
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341)
LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled)
is currently used to implicitly disable null checks, normally enabled
via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely
purely on the config value instead:
* LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't
rely on null checks at all (e.g. -fsanitize=alignment)
* null checks today (implemented via __builtin_trap) should function
normally today even when sanitizer is enabled - trap is still a trap
* tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a
particular signal / exit-code, and thus should pass even if sanitizers
override the default ones.
Diffstat (limited to 'llvm/unittests/Support/DebugCounterTest.cpp')
0 files changed, 0 insertions, 0 deletions