Fix compile warnings

libeigen/eigen!2167
This commit is contained in:
Antonio Sánchez
2026-02-20 23:09:56 +00:00
parent 1dcea43c49
commit e0a8d6c9d8
2 changed files with 7 additions and 1 deletions

View File

@@ -1302,7 +1302,13 @@ EIGEN_ALWAYS_INLINE void gebp_micro_panel_impl(GEBPTraits& traits, const DataMap
// Double-accumulation trick for 1pX4 path to break FMA dependency chains
constexpr bool use_double_accum = (MrPackets == 1 && NrCols == 4);
#ifdef EIGEN_HAS_CXX17_IFCONSTEXPR
AccPacketLocal D[use_double_accum ? NrCols : 1];
#else
// Without if constexpr, we must allocate a larger array to satisfy the
// compiler that D[n] is always in bounds for the use_double_accum path.
AccPacketLocal D[CSize];
#endif
EIGEN_IF_CONSTEXPR(use_double_accum) {
for (int n = 0; n < NrCols; ++n) traits.initAcc(D[n]);
}

View File

@@ -382,7 +382,7 @@ class FFT {
defined EIGEN_MKL_DEFAULT
inline void inv2(Complex* dst, const Complex* src, int n0, int n1) {
m_impl.inv2(dst, src, n0, n1);
if (HasFlag(Unscaled) == false) scale(dst, 1. / (n0 * n1), n0 * n1);
if (HasFlag(Unscaled) == false) scale(dst, Scalar(1) / (n0 * n1), n0 * n1);
}
#endif