[libcxx-commits] [libcxx] [libc++] Reduce the number of warnings when running SPEC (PR #160366)
via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Sep 23 11:50:51 PDT 2025
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-libcxx
Author: Louis Dionne (ldionne)
<details>
<summary>Changes</summary>
Using -Wall and -Wextra when building SPEC leads to extremely large log files. Since we don't actually care about warnings in these benchmarks, this patches tones down the number of warnings a bit.
---
Full diff: https://github.com/llvm/llvm-project/pull/160366.diff
1 Files Affected:
- (modified) libcxx/test/benchmarks/spec.gen.py (+4-1)
``````````diff
diff --git a/libcxx/test/benchmarks/spec.gen.py b/libcxx/test/benchmarks/spec.gen.py
index ea7b75b3d2085..de7c14db5ad8e 100644
--- a/libcxx/test/benchmarks/spec.gen.py
+++ b/libcxx/test/benchmarks/spec.gen.py
@@ -28,6 +28,9 @@
link_flags = (test_dir / 'link_flags.subs').open().read().strip()
spec_dir = pathlib.Path((test_dir / 'spec_dir.subs').open().read().strip())
+# Remove -Wall, -Wextra and -Werror from the flags since we don't care about enabling all warnings inside SPEC
+compile_flags = compile_flags.replace('-Wall', '').replace('-Wextra', '').replace('-Werror', '')
+
# Setup the configuration file
test_dir.mkdir(parents=True, exist_ok=True)
spec_config = test_dir / 'spec-config.cfg'
@@ -46,7 +49,7 @@
copies = 1
threads = 1
CC = cc -O3
- CXX = {cxx} {compile_flags} {flags} {link_flags} -Wno-error
+ CXX = {cxx} {compile_flags} {flags} {link_flags}
CC_VERSION_OPTION = --version
CXX_VERSION_OPTION = --version
EXTRA_PORTABILITY = -DSPEC_NO_CXX17_SPECIAL_MATH_FUNCTIONS # because libc++ doesn't implement the special math functions yet
``````````
</details>
https://github.com/llvm/llvm-project/pull/160366
More information about the libcxx-commits
mailing list