Skip to content

Commit 2d4d1ab

Browse files
committed
Suppress GCC variable tracking warnings in debug builds
Add -fno-var-tracking-assignments flag for GCC debug builds to prevent verbose "variable tracking size limit exceeded, retrying without" notes. This particularly affects large test files like wpt_urlpattern_tests.cpp that exceed GCC's variable tracking limits. The compiler automatically retries without tracking, so these notes don't indicate actual problems, but they create noise in build output. The flag is applied only to Debug builds using a generator expression, so it doesn't affect Release builds where variable tracking is already disabled.
1 parent c33be54 commit 2d4d1ab

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

cmake/CompilerWarnings.cmake

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,12 @@ function(ada_set_project_warnings target_name)
124124
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
125125
target_compile_options(${target_name} PRIVATE ${GCC_WARNINGS_TO_USE})
126126

127+
# Suppress variable tracking notes in debug builds (prevents verbose "retrying without" messages)
128+
# This affects large files like wpt_urlpattern_tests.cpp that exceed variable tracking limits
129+
target_compile_options(${target_name} PRIVATE
130+
$<$<CONFIG:Debug>:-fno-var-tracking-assignments>
131+
)
132+
127133
# Workaround for GCC poor AVX load/store code generation on x86
128134
# Skip this workaround when clang-tidy is enabled (it's Clang-based and doesn't support these flags)
129135
if(CMAKE_SYSTEM_PROCESSOR MATCHES "^(i.86|x86(_64)?)$" AND NOT ADA_ENABLE_CLANG_TIDY)

0 commit comments

Comments
 (0)