[compiler-rt] 000aeb2 - [hwasan] Fix build breakage (-Wunused-function) in hwasan_interceptors.cpp (NFC)
Jie Fu via llvm-commits
llvm-commits at lists.llvm.org
Tue May 16 22:01:42 PDT 2023
Author: Jie Fu
Date: 2023-05-17T13:00:50+08:00
New Revision: 000aeb2499b1db510f064c37c097a5020215b835
URL: https://github.com/llvm/llvm-project/commit/000aeb2499b1db510f064c37c097a5020215b835
DIFF: https://github.com/llvm/llvm-project/commit/000aeb2499b1db510f064c37c097a5020215b835.diff
LOG: [hwasan] Fix build breakage (-Wunused-function) in hwasan_interceptors.cpp (NFC)
In file included from /data/llvm-project/compiler-rt/lib/hwasan/hwasan_interceptors.cpp:141:
/data/llvm-project/compiler-rt/lib/hwasan/../sanitizer_common/sanitizer_common_interceptors.inc:1044:13: error: unused function 'write_iovec' [-Werror,-Wunused-function]
static void write_iovec(void *ctx, struct __sanitizer_iovec *iovec,
^
/data/llvm-project/compiler-rt/lib/hwasan/../sanitizer_common/sanitizer_common_interceptors.inc:1053:13: error: unused function 'read_iovec' [-Werror,-Wunused-function]
static void read_iovec(void *ctx, struct __sanitizer_iovec *iovec,
^
/data/llvm-project/compiler-rt/lib/hwasan/../sanitizer_common/sanitizer_common_interceptors.inc:10363:13: error: unused function 'InitializeCommonInterceptors' [-Werror,-Wunused-function]
static void InitializeCommonInterceptors() {
^
3 errors generated.
Added:
Modified:
compiler-rt/lib/hwasan/hwasan_interceptors.cpp
Removed:
################################################################################
diff --git a/compiler-rt/lib/hwasan/hwasan_interceptors.cpp b/compiler-rt/lib/hwasan/hwasan_interceptors.cpp
index f5099c2a835f..57df79d15123 100644
--- a/compiler-rt/lib/hwasan/hwasan_interceptors.cpp
+++ b/compiler-rt/lib/hwasan/hwasan_interceptors.cpp
@@ -138,7 +138,10 @@ using namespace __hwasan;
(void)(name); \
} while (false)
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wunused-function"
#include "sanitizer_common/sanitizer_common_interceptors.inc"
+#pragma clang diagnostic pop
struct ThreadStartArg {
__sanitizer_sigset_t starting_sigset_;
More information about the llvm-commits
mailing list