Skip to content

Commit 8052dfb

Browse files
hjmjohnsonclaude
andcommitted
COMP: Suppress GCC -Wmaybe-uninitialized in Eigen3 SelfadjointMatrixVector
GCC on aarch64 (ARM) emits a false-positive -Wmaybe-uninitialized warning at line 224 of SelfadjointMatrixVector.h. The dashboard script (itk_common.cmake) treats any build warning as CI failure. Add targeted GCC diagnostic pragmas to suppress the warning in this file only, scoped to GCC (not Clang) via __GNUC__ / __clang__ guards. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 2642b9b commit 8052dfb

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

Modules/ThirdParty/Eigen3/src/itkeigen/Eigen/src/Core/products/SelfadjointMatrixVector.h

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,13 @@
1313
// IWYU pragma: private
1414
#include "../InternalHeaderCheck.h"
1515

16+
// GCC on ARM (aarch64) emits false-positive -Wmaybe-uninitialized warnings
17+
// in the vectorized selfadjoint matrix-vector product kernel.
18+
#if defined(__GNUC__) && !defined(__clang__)
19+
# pragma GCC diagnostic push
20+
# pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
21+
#endif
22+
1623
namespace Eigen {
1724

1825
namespace internal {
@@ -250,4 +257,8 @@ struct selfadjoint_product_impl<Lhs, 0, true, Rhs, RhsMode, false> {
250257

251258
} // end namespace Eigen
252259

260+
#if defined(__GNUC__) && !defined(__clang__)
261+
# pragma GCC diagnostic pop
262+
#endif
263+
253264
#endif // EIGEN_SELFADJOINT_MATRIX_VECTOR_H

0 commit comments

Comments
 (0)