[PATCH] D96337: [sanitizer] Fix suffix-log-path_test.c on arm-linux-gnu
Oliver Stannard (Linaro) via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 11 02:20:35 PST 2021
ostannard added a comment.
Could this also affect regular users of the sanitizers, or is it specific to the way we are running the tests? If it could affect users, then could we fix this in the clang driver, so that unwind tables are turned on by default whenever the sanitizers need them?
================
Comment at: compiler-rt/test/sanitizer_common/CMakeLists.txt:82
+ # required to get a complete stacktrace.
+ if (${arch} MATCHES "armhf|arm" AND NOT ANDROID AND NOT WINDOWS AND NOT APPLE)
+ list(APPEND SANITIZER_COMMON_TEST_TARGET_CFLAGS -funwind-tables)
----------------
Testing for Linux using `NOT ANDROID AND NOT WINDOWS AND NOT APPLE` will break if more operating systems are added in future, and it's not obvious to me that this list is complete now. This is tested with `if("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux")` elsewhere in compiler-rt, which looks like a better way to do this.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D96337/new/
https://reviews.llvm.org/D96337
More information about the llvm-commits
mailing list