Skip to content

Commit 43d4f10

Browse files
committed
Disable -Wunused-function under xlC.
This bug is entirely too verbose. Bug 2740315 Reviewed-by: Bryce Adelstein Lelbach aka wash <brycelelbach@gmail.com>
1 parent 00ee736 commit 43d4f10

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

internal/build/common_warnings.mk

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ ifeq ($(OS),$(filter $(OS),Linux Darwin))
77
# template functions, but xlC does. This causes xlC to choke on the
88
# OMP backend, which is mostly #ifdef'd out when you aren't using it.
99
CUDACC_FLAGS += -Xcompiler "-Wno-unused-parameter"
10+
11+
# xlC is unreasonable about unused functions in a translation unit
12+
# when this warning is enabled; this includes warning on most functions
13+
# that are defined as static inline in cuda_fp16.h. Disable this warning
14+
# entirely under xlC.
15+
CUDACC_FLAGS += -Xcompiler "-Wno-unused-function"
1016
else # GCC, ICC or Clang AKA the sane ones.
1117
# XXX Enable -Wcast-align.
1218
CUDACC_FLAGS += -Xcompiler "-Winit-self -Woverloaded-virtual -Wno-cast-align -Wcast-qual -Wno-long-long -Wno-variadic-macros -Wno-unused-function"

0 commit comments

Comments
 (0)