[all-commits] [llvm/llvm-project] ba80cd: [asan, test] Disable _FORTIFY_SOURCE test incompati...
Fangrui Song via All-commits
all-commits at lists.llvm.org
Sun Aug 4 02:27:53 PDT 2024
Branch: refs/heads/release/19.x
Home: https://github.com/llvm/llvm-project
Commit: ba80cdd27874284077c2c79e54e867d9af1b956e
https://github.com/llvm/llvm-project/commit/ba80cdd27874284077c2c79e54e867d9af1b956e
Author: Fangrui Song <i at maskray.me>
Date: 2024-08-04 (Sun, 04 Aug 2024)
Changed paths:
M compiler-rt/test/asan/TestCases/Linux/printf-fortify-5.c
M compiler-rt/test/lit.common.cfg.py
Log Message:
-----------
[asan,test] Disable _FORTIFY_SOURCE test incompatible with glibc 2.40
In terms of bug catching capability, `_FORTIFY_SOURCE` does not perform
as well as some dynamic instrumentation tools. When a sanitizer is used,
generally `_FORTIFY_SOURCE` should be disabled since sanitizer runtime
does not implement most `*_chk` functions. Using `_FORTIFY_SOURCE`
will regress error checking (asan/hwasan/tsan) or cause false positives
(msan).
`*printf_chk` are the most pronounced `_chk` interceptors for
uninstrumented DSOes (https://reviews.llvm.org/D40951).
glibc 2.40 introduced `pass_object_info` style fortified source for some
functions ([1]). `fprintf` will be mangled as
`_ZL7fprintfP8_IO_FILEU17pass_object_size1PKcz`, which has no associated
interceptor, leading to printf-fortify-5.c failure.
Just disable the test. Fix #100877
[1]: https://sourceware.org/pipermail/libc-alpha/2024-February/154531.html
Pull Request: https://github.com/llvm/llvm-project/pull/101566
(cherry picked from commit bbdccf4c94ff18a0761b03a0e2c8b05805385132)
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