From 78b76986b7f70c1b76a8dd46e46fa82140c72ff1 Mon Sep 17 00:00:00 2001 From: Rasmus Munk Larsen <4643818-rmlarsen1@users.noreply.gitlab.com> Date: Sun, 22 Feb 2026 21:20:08 -0800 Subject: [PATCH] Comment cleanup v3: trailing ??, informal language, FIXME/TODO colons libeigen/eigen!2197 Co-authored-by: Rasmus Munk Larsen --- Eigen/src/Cholesky/LDLT.h | 2 +- Eigen/src/Cholesky/LLT.h | 2 +- Eigen/src/CholmodSupport/CholmodSupport.h | 4 ++-- Eigen/src/Core/AssignEvaluator.h | 6 +++--- Eigen/src/Core/CoreEvaluators.h | 10 +++++----- Eigen/src/Core/DeviceWrapper.h | 2 +- Eigen/src/Core/GeneralProduct.h | 6 +++--- Eigen/src/Core/IO.h | 2 +- Eigen/src/Core/IndexedView.h | 2 +- Eigen/src/Core/ProductEvaluators.h | 8 ++++---- Eigen/src/Core/Redux.h | 4 ++-- Eigen/src/Core/Replicate.h | 4 ++-- Eigen/src/Core/ReturnByValue.h | 4 ++-- Eigen/src/Core/StlIterators.h | 2 +- Eigen/src/Core/Swap.h | 4 ++-- Eigen/src/Core/TriangularMatrix.h | 2 +- Eigen/src/Core/arch/AVX512/GemmKernel.h | 2 +- Eigen/src/Core/arch/AltiVec/PacketMath.h | 6 +++--- Eigen/src/Core/arch/LSX/Complex.h | 4 ++-- Eigen/src/Core/arch/MSA/PacketMath.h | 6 +++--- Eigen/src/Core/functors/AssignmentFunctors.h | 2 +- Eigen/src/Core/functors/BinaryFunctors.h | 4 ++-- Eigen/src/Core/functors/UnaryFunctors.h | 6 +++--- Eigen/src/Core/products/GeneralBlockPanelKernel.h | 4 ++-- .../Core/products/GeneralMatrixMatrixTriangular_BLAS.h | 4 ++-- Eigen/src/Core/products/SelfadjointMatrixVector.h | 2 +- Eigen/src/Core/products/TriangularSolverMatrix.h | 2 +- Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h | 2 +- Eigen/src/Eigenvalues/Tridiagonalization.h | 2 +- Eigen/src/SVD/BDCSVD.h | 2 +- Eigen/src/SparseCore/AmbiVector.h | 2 +- Eigen/src/SparseCore/SparseAssign.h | 2 +- Eigen/src/SparseCore/SparseCwiseBinaryOp.h | 2 +- Eigen/src/SparseCore/SparseRef.h | 4 ++-- Eigen/src/SparseCore/SparseSelfAdjointView.h | 4 ++-- Eigen/src/SparseCore/SparseVector.h | 2 +- Eigen/src/SparseCore/SparseView.h | 2 +- Eigen/src/SparseCore/TriangularSolver.h | 3 ++- Eigen/src/SparseLU/SparseLU_Memory.h | 2 +- Eigen/src/SparseLU/SparseLU_column_bmod.h | 2 +- Eigen/src/SuperLUSupport/SuperLUSupport.h | 4 ++-- Eigen/src/ThreadPool/NonBlockingThreadPool.h | 2 +- Eigen/src/UmfPackSupport/UmfPackSupport.h | 2 +- Eigen/src/plugins/ArrayCwiseBinaryOps.inc | 2 +- bench/benchmark-blocking-sizes.cpp | 2 +- bench/eig33.cpp | 2 +- blas/level3_impl.h | 2 +- demos/opengl/camera.cpp | 2 +- test/bug1213_main.cpp | 2 +- test/main.h | 2 +- test/packetmath.cpp | 2 +- test/prec_inverse_4x4.cpp | 2 +- test/rand.cpp | 2 +- unsupported/Eigen/src/FFT/kissfft_impl.h | 2 +- unsupported/Eigen/src/IterativeSolvers/IDRSTABL.h | 2 +- unsupported/Eigen/src/SparseExtra/BlockSparseMatrix.h | 8 ++++---- unsupported/test/special_functions.cpp | 2 +- 57 files changed, 90 insertions(+), 89 deletions(-) diff --git a/Eigen/src/Cholesky/LDLT.h b/Eigen/src/Cholesky/LDLT.h index dd208e3eb..45912a24e 100644 --- a/Eigen/src/Cholesky/LDLT.h +++ b/Eigen/src/Cholesky/LDLT.h @@ -491,7 +491,7 @@ LDLT& LDLT::compute(const EigenBase& LLT::compute(const EigenBase { this->m_info = NumericalIssue; return; } - // TODO optimize this copy by swapping when possible (be careful with alignment, etc.) + // TODO: optimize this copy by swapping when possible (be careful with alignment, etc.) // NOTE Actually, the copy can be avoided by calling cholmod_solve2 instead of cholmod_solve dest = Matrix::Map(reinterpret_cast(x_cd->x), b.rows(), b.cols()); @@ -386,7 +386,7 @@ class CholmodBase : public SparseSolverBase { this->m_info = NumericalIssue; return; } - // TODO optimize this copy by swapping when possible (be careful with alignment, etc.) + // TODO: optimize this copy by swapping when possible (be careful with alignment, etc.) // NOTE cholmod_spsolve in fact just calls the dense solver for blocks of 4 columns at a time (similar to Eigen's // sparse solver) dest.derived() = viewAsEigen(*x_cs); diff --git a/Eigen/src/Core/AssignEvaluator.h b/Eigen/src/Core/AssignEvaluator.h index 17e21c436..061ac6c2c 100644 --- a/Eigen/src/Core/AssignEvaluator.h +++ b/Eigen/src/Core/AssignEvaluator.h @@ -762,7 +762,7 @@ class generic_dense_assignment_kernel { DstEvaluatorType& m_dst; const SrcEvaluatorType& m_src; const Functor& m_functor; - // TODO find a way to avoid the needs of the original expression + // TODO: find a way to avoid the needs of the original expression DstXprType& m_dstExpr; }; @@ -921,7 +921,7 @@ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE constexpr void call_assignment_no_alias(Ds typedef std::conditional_t, Dst&> ActualDstType; ActualDstType actualDst(dst); - // TODO check whether this is the right place to perform these checks: + // TODO: check whether this is the right place to perform these checks: EIGEN_STATIC_ASSERT_LVALUE(Dst) EIGEN_STATIC_ASSERT_SAME_MATRIX_SIZE(ActualDstTypeCleaned, Src) EIGEN_CHECK_BINARY_COMPATIBILIY(Func, typename ActualDstTypeCleaned::Scalar, typename Src::Scalar); @@ -956,7 +956,7 @@ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE constexpr void call_assignment_no_alias(Ds template EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE constexpr void call_assignment_no_alias_no_transpose(Dst& dst, const Src& src, const Func& func) { - // TODO check whether this is the right place to perform these checks: + // TODO: check whether this is the right place to perform these checks: EIGEN_STATIC_ASSERT_LVALUE(Dst) EIGEN_STATIC_ASSERT_SAME_MATRIX_SIZE(Dst, Src) EIGEN_CHECK_BINARY_COMPATIBILIY(Func, typename Dst::Scalar, typename Src::Scalar); diff --git a/Eigen/src/Core/CoreEvaluators.h b/Eigen/src/Core/CoreEvaluators.h index a79c891cd..d2649d246 100644 --- a/Eigen/src/Core/CoreEvaluators.h +++ b/Eigen/src/Core/CoreEvaluators.h @@ -116,7 +116,7 @@ struct evaluator : evaluator { template struct evaluator_base { - // TODO that's not very nice to have to propagate all these traits. They are currently only needed to handle + // TODO: find a way to avoid propagating all these traits. They are currently only needed to handle // outer,inner indices. typedef traits ExpressionTraits; @@ -1117,7 +1117,7 @@ struct unary_evaluator, IndexBased> Flags = (evaluator::Flags & (HereditaryBits | LinearAccessBit | DirectAccessBit)), - Alignment = 0 // FIXME it is not very clear why alignment is necessarily lost... + Alignment = 0 // FIXME: clarify why alignment is lost for CwiseUnaryView. }; EIGEN_DEVICE_FUNC explicit unary_evaluator(const XprType& op) : m_d(op) { @@ -1159,7 +1159,7 @@ struct unary_evaluator, IndexBased> // -------------------- Map -------------------- -// FIXME perhaps the PlainObjectType could be provided by Derived::PlainObject ? +// FIXME: consider using Derived::PlainObject for PlainObjectType. // but that might complicate template specialization template struct mapbase_evaluator; @@ -1713,7 +1713,7 @@ struct unary_evaluator> : evaluator_base::CoeffReadCost, // let's enable LinearAccess only with vectorization because of the product overhead - // FIXME enable DirectAccess with negative strides? + // FIXME: consider enabling DirectAccess with negative strides. Flags0 = evaluator::Flags, LinearAccess = ((Direction == BothDirections) && (int(Flags0) & PacketAccessBit)) || @@ -1723,7 +1723,7 @@ struct unary_evaluator> : evaluator_base, Dst&>; ActualDstType actualDst(dst.derived()); - // TODO check whether this is the right place to perform these checks: + // TODO: check whether this is the right place to perform these checks: EIGEN_STATIC_ASSERT_LVALUE(Dst) EIGEN_STATIC_ASSERT_SAME_MATRIX_SIZE(ActualDstTypeCleaned, Src) EIGEN_CHECK_BINARY_COMPATIBILIY(Func, typename ActualDstTypeCleaned::Scalar, typename Src::Scalar); diff --git a/Eigen/src/Core/GeneralProduct.h b/Eigen/src/Core/GeneralProduct.h index 279fd82a5..707611a82 100644 --- a/Eigen/src/Core/GeneralProduct.h +++ b/Eigen/src/Core/GeneralProduct.h @@ -292,7 +292,7 @@ struct gemv_dense_selector { typedef std::conditional_t ActualDest; enum { - // FIXME find a way to allow an inner stride on the result if packet_traits::size==1 + // FIXME: find a way to allow an inner stride on the result if packet_traits::size==1 // on, the other hand it is good for the cache to pack the vector anyways... EvalToDestAtCompileTime = (ActualDest::InnerStrideAtCompileTime == 1), ComplexByReal = (NumTraits::IsComplex) && (!NumTraits::IsComplex), @@ -375,7 +375,7 @@ struct gemv_dense_selector { ResScalar actualAlpha = combine_scalar_factors(alpha, lhs, rhs); enum { - // FIXME find a way to allow an inner stride on the result if packet_traits::size==1 + // FIXME: find a way to allow an inner stride on the result if packet_traits::size==1 // on, the other hand it is good for the cache to pack the vector anyways... DirectlyUseRhs = ActualRhsTypeCleaned::InnerStrideAtCompileTime == 1 || ActualRhsTypeCleaned::MaxSizeAtCompileTime == 0 @@ -416,7 +416,7 @@ struct gemv_dense_selector { static void run(const Lhs& lhs, const Rhs& rhs, Dest& dest, const typename Dest::Scalar& alpha) { EIGEN_STATIC_ASSERT((!nested_eval::Evaluate), EIGEN_INTERNAL_COMPILATION_ERROR_OR_YOU_MADE_A_PROGRAMMING_MISTAKE); - // TODO if rhs is large enough it might be beneficial to make sure that dest is sequentially stored in memory, + // TODO: if rhs is large enough it might be beneficial to make sure that dest is sequentially stored in memory, // otherwise use a temp typename nested_eval::type actual_rhs(rhs); const Index size = rhs.rows(); diff --git a/Eigen/src/Core/IO.h b/Eigen/src/Core/IO.h index 0a1b583d6..e2362fcdc 100644 --- a/Eigen/src/Core/IO.h +++ b/Eigen/src/Core/IO.h @@ -65,7 +65,7 @@ struct IOFormat { fill(_fill), precision(_precision), flags(_flags) { - // TODO check if rowPrefix, rowSuffix or rowSeparator contains a newline + // TODO: check if rowPrefix, rowSuffix or rowSeparator contains a newline // don't add rowSpacer if columns are not to be aligned if ((flags & DontAlignCols)) return; int i = int(matPrefix.length()) - 1; diff --git a/Eigen/src/Core/IndexedView.h b/Eigen/src/Core/IndexedView.h index 10562c194..af047c4ee 100644 --- a/Eigen/src/Core/IndexedView.h +++ b/Eigen/src/Core/IndexedView.h @@ -59,7 +59,7 @@ struct traits> : traits { ReturnAsBlock = (!ReturnAsScalar) && IsBlockAlike, ReturnAsIndexedView = (!ReturnAsScalar) && (!ReturnAsBlock), - // FIXME we deal with compile-time strides if and only if we have DirectAccessBit flag, + // FIXME: we deal with compile-time strides if and only if we have DirectAccessBit flag, // but this is too strict regarding negative strides... DirectAccessMask = (int(InnerIncr) != Undefined && int(OuterIncr) != Undefined && InnerIncr >= 0 && OuterIncr >= 0) ? DirectAccessBit diff --git a/Eigen/src/Core/ProductEvaluators.h b/Eigen/src/Core/ProductEvaluators.h index e96256a2c..cbff424c1 100644 --- a/Eigen/src/Core/ProductEvaluators.h +++ b/Eigen/src/Core/ProductEvaluators.h @@ -36,7 +36,7 @@ struct evaluator> : public product_evaluator struct evaluator_assume_aliasing, const CwiseNullaryOp, Plain1>, @@ -161,7 +161,7 @@ struct Assignment, internal::sub_assign_o }; // Dense ?= scalar * Product -// TODO we should apply that rule if that's really helpful +// TODO: we should apply that rule if that's really helpful // for instance, this is not good for inner products template @@ -286,7 +286,7 @@ struct generic_product_impl { struct is_row_major : bool_constant<(int(T::Flags) & RowMajorBit)> {}; typedef typename Product::Scalar Scalar; - // TODO it would be nice to be able to exploit our *_assign_op functors for that purpose + // TODO: it would be nice to be able to exploit our *_assign_op functors for that purpose struct set { template EIGEN_DEVICE_FUNC void operator()(const Dst& dst, const Src& src) const { @@ -563,7 +563,7 @@ struct product_evaluator, ProductTag, DenseShape, Flags = ((int(LhsFlags) | int(RhsFlags)) & HereditaryBits & ~RowMajorBit) | (EvalToRowMajor ? RowMajorBit : 0) - // TODO enable vectorization for mixed types + // TODO: enable vectorization for mixed types | (SameType && (CanVectorizeLhs || CanVectorizeRhs) ? PacketAccessBit : 0) | (XprType::IsVectorAtCompileTime ? LinearAccessBit : 0), diff --git a/Eigen/src/Core/Redux.h b/Eigen/src/Core/Redux.h index 4e9ab0e4f..7111604a1 100644 --- a/Eigen/src/Core/Redux.h +++ b/Eigen/src/Core/Redux.h @@ -398,8 +398,8 @@ class redux_evaluator : public internal::evaluator { enum { MaxRowsAtCompileTime = XprType::MaxRowsAtCompileTime, MaxColsAtCompileTime = XprType::MaxColsAtCompileTime, - // TODO we should not remove DirectAccessBit and rather find an elegant way to query the alignment offset at runtime - // from the evaluator + // TODO: we should not remove DirectAccessBit and rather find an elegant way to query the alignment offset at + // runtime from the evaluator Flags = Base::Flags & ~DirectAccessBit, IsRowMajor = XprType::IsRowMajor, SizeAtCompileTime = XprType::SizeAtCompileTime, diff --git a/Eigen/src/Core/Replicate.h b/Eigen/src/Core/Replicate.h index 341504522..30a17db67 100644 --- a/Eigen/src/Core/Replicate.h +++ b/Eigen/src/Core/Replicate.h @@ -30,7 +30,7 @@ struct traits > : traits ColsAtCompileTime = ColFactor == Dynamic || int(MatrixType::ColsAtCompileTime) == Dynamic ? Dynamic : ColFactor * MatrixType::ColsAtCompileTime, - // FIXME we don't propagate the max sizes !!! + // FIXME: propagate MaxRowsAtCompileTime and MaxColsAtCompileTime. MaxRowsAtCompileTime = RowsAtCompileTime, MaxColsAtCompileTime = ColsAtCompileTime, IsRowMajor = MaxRowsAtCompileTime == 1 && MaxColsAtCompileTime != 1 ? 1 @@ -38,7 +38,7 @@ struct traits > : traits : (MatrixType::Flags & RowMajorBit) ? 1 : 0, - // FIXME enable DirectAccess with negative strides? + // FIXME: consider enabling DirectAccess with negative strides. Flags = IsRowMajor ? RowMajorBit : 0 }; }; diff --git a/Eigen/src/Core/ReturnByValue.h b/Eigen/src/Core/ReturnByValue.h index 892c193bd..410b77d2e 100644 --- a/Eigen/src/Core/ReturnByValue.h +++ b/Eigen/src/Core/ReturnByValue.h @@ -23,7 +23,7 @@ struct traits > : public traits: enum { // We're disabling the DirectAccess because e.g. the constructor of // the Block-with-DirectAccess expression requires to have a coeffRef method. - // Also, we don't want to have to implement the stride stuff. + // Also, this avoids having to implement stride support. Flags = (traits::ReturnType>::Flags | EvalBeforeNestingBit) & ~DirectAccessBit }; }; @@ -32,7 +32,7 @@ struct traits > : public traits: * So the only way that nesting it in an expression can work, is by evaluating it into a plain matrix. * So internal::nested always gives the plain return matrix type. * - * FIXME: I don't understand why we need this specialization: isn't this taken care of by the EvalBeforeNestingBit ?? + * FIXME: this specialization may be redundant with EvalBeforeNestingBit. * Answer: EvalBeforeNestingBit should be deprecated since we have the evaluators */ template diff --git a/Eigen/src/Core/StlIterators.h b/Eigen/src/Core/StlIterators.h index d3cfce01e..afa2ecba0 100644 --- a/Eigen/src/Core/StlIterators.h +++ b/Eigen/src/Core/StlIterators.h @@ -449,7 +449,7 @@ class generic_randaccess_stl_iterator using Base::m_index; using Base::mp_xpr; - // TODO currently const Transpose/Reshape expressions never returns const references, + // TODO: currently const Transpose/Reshape expressions never returns const references, // so lets return by value too. // typedef std::conditional_t read_only_ref_t; typedef const value_type read_only_ref_t; diff --git a/Eigen/src/Core/Swap.h b/Eigen/src/Core/Swap.h index dd825e907..5d419b19f 100644 --- a/Eigen/src/Core/Swap.h +++ b/Eigen/src/Core/Swap.h @@ -57,7 +57,7 @@ class generic_dense_assignment_kernel(index, tmp); } - // TODO find a simple way not to have to copy/paste this function from generic_dense_assignment_kernel, by simple I + // TODO: find a simple way not to have to copy/paste this function from generic_dense_assignment_kernel, by simple I // mean no CRTP (Gael) template EIGEN_STRONG_INLINE void assignPacketByOuterInner(Index outer, Index inner) { @@ -82,7 +82,7 @@ class generic_dense_assignment_kernel(index, tmp, begin, count); } - // TODO find a simple way not to have to copy/paste this function from generic_dense_assignment_kernel, by simple I + // TODO: find a simple way not to have to copy/paste this function from generic_dense_assignment_kernel, by simple I // mean no CRTP (Gael) template EIGEN_STRONG_INLINE void assignPacketSegmentByOuterInner(Index outer, Index inner, Index begin, Index count) { diff --git a/Eigen/src/Core/TriangularMatrix.h b/Eigen/src/Core/TriangularMatrix.h index 3225ab699..76da9e983 100644 --- a/Eigen/src/Core/TriangularMatrix.h +++ b/Eigen/src/Core/TriangularMatrix.h @@ -633,7 +633,7 @@ bool MatrixBase::isLowerTriangular(const RealScalar& prec) const { namespace internal { -// TODO currently a triangular expression has the form TriangularView<.,.> +// TODO: currently a triangular expression has the form TriangularView<.,.> // in the future triangular-ness should be defined by the expression traits // such that Transpose > is valid. (currently TriangularBase::transpose() is overloaded to make // it work) diff --git a/Eigen/src/Core/arch/AVX512/GemmKernel.h b/Eigen/src/Core/arch/AVX512/GemmKernel.h index 1ec9033e7..fbc2d5822 100644 --- a/Eigen/src/Core/arch/AVX512/GemmKernel.h +++ b/Eigen/src/Core/arch/AVX512/GemmKernel.h @@ -1059,7 +1059,7 @@ EIGEN_DONT_INLINE void gemm_pack_rhs kernel; diff --git a/Eigen/src/Core/arch/AltiVec/PacketMath.h b/Eigen/src/Core/arch/AltiVec/PacketMath.h index ce6702008..8d5a35156 100644 --- a/Eigen/src/Core/arch/AltiVec/PacketMath.h +++ b/Eigen/src/Core/arch/AltiVec/PacketMath.h @@ -41,7 +41,7 @@ typedef __vector signed char Packet16c; typedef __vector unsigned char Packet16uc; typedef eigen_packet_wrapper<__vector unsigned short int, 0> Packet8bf; -// We don't want to write the same code all the time, but we need to reuse the constants +// To avoid repeating the same code, but we need to reuse the constants // and it doesn't really work to declare them global, so we define macros instead #define EIGEN_DECLARE_CONST_FAST_Packet4f(NAME, X) Packet4f p4f_##NAME = {X, X, X, X} @@ -1163,7 +1163,7 @@ EIGEN_STRONG_INLINE Packet4i pdiv(const Packet4i& a, const Packet4i& b #endif } -// for some weird reasons, it has to be overloaded for packet of integers +// This overload is required for integer packet types. template <> EIGEN_STRONG_INLINE Packet4f pmadd(const Packet4f& a, const Packet4f& b, const Packet4f& c) { return vec_madd(a, b, c); @@ -3274,7 +3274,7 @@ EIGEN_STRONG_INLINE Packet2d pdiv(const Packet2d& a, const Packet2d& b return vec_div(a, b); } -// for some weird reasons, it has to be overloaded for packet of integers +// This overload is required for integer packet types. template <> EIGEN_STRONG_INLINE Packet2d pmadd(const Packet2d& a, const Packet2d& b, const Packet2d& c) { return vec_madd(a, b, c); diff --git a/Eigen/src/Core/arch/LSX/Complex.h b/Eigen/src/Core/arch/LSX/Complex.h index 0b60a8312..43ba989d2 100644 --- a/Eigen/src/Core/arch/LSX/Complex.h +++ b/Eigen/src/Core/arch/LSX/Complex.h @@ -364,7 +364,7 @@ EIGEN_STRONG_INLINE Packet1cd pandnot(const Packet1cd& a, const Packe return res; } -// FIXME force unaligned load, this is a temporary fix +// FIXME: force unaligned load, this is a temporary fix template <> EIGEN_STRONG_INLINE Packet1cd pload(const std::complex* from) { EIGEN_DEBUG_ALIGNED_LOAD return Packet1cd(pload((const double*)from)); @@ -384,7 +384,7 @@ EIGEN_STRONG_INLINE Packet1cd ploaddup(const std::complex* fr return pset1(*from); } -// FIXME force unaligned store, this is a temporary fix +// FIXME: force unaligned store, this is a temporary fix template <> EIGEN_STRONG_INLINE void pstore >(std::complex* to, const Packet1cd& from) { EIGEN_DEBUG_ALIGNED_STORE pstore((double*)to, Packet2d(from.v)); diff --git a/Eigen/src/Core/arch/MSA/PacketMath.h b/Eigen/src/Core/arch/MSA/PacketMath.h index ff708a0e6..558893ee6 100644 --- a/Eigen/src/Core/arch/MSA/PacketMath.h +++ b/Eigen/src/Core/arch/MSA/PacketMath.h @@ -70,7 +70,7 @@ struct packet_traits : default_packet_traits { Vectorizable = 1, AlignedOnScalar = 1, size = 4, - // FIXME check the Has* + // FIXME: verify the Has* flags. HasDiv = 1, HasSin = EIGEN_FAST_MATH, HasCos = EIGEN_FAST_MATH, @@ -91,7 +91,7 @@ struct packet_traits : default_packet_traits { Vectorizable = 1, AlignedOnScalar = 1, size = 4, - // FIXME check the Has* + // FIXME: verify the Has* flags. HasDiv = 1, }; }; @@ -822,7 +822,7 @@ struct packet_traits : default_packet_traits { Vectorizable = 1, AlignedOnScalar = 1, size = 2, - // FIXME check the Has* + // FIXME: verify the Has* flags. HasDiv = 1, HasExp = 1, HasSqrt = 1, diff --git a/Eigen/src/Core/functors/AssignmentFunctors.h b/Eigen/src/Core/functors/AssignmentFunctors.h index e3ad3375c..c8f1e4161 100644 --- a/Eigen/src/Core/functors/AssignmentFunctors.h +++ b/Eigen/src/Core/functors/AssignmentFunctors.h @@ -140,7 +140,7 @@ template struct swap_assign_op { EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void assignCoeff(Scalar& a, const Scalar& b) const { #ifdef EIGEN_GPUCC - // FIXME is there some kind of cuda::swap? + // FIXME: check whether cuda::swap exists. Scalar t = b; const_cast(b) = a; a = t; diff --git a/Eigen/src/Core/functors/BinaryFunctors.h b/Eigen/src/Core/functors/BinaryFunctors.h index 0f318646a..1be48992d 100644 --- a/Eigen/src/Core/functors/BinaryFunctors.h +++ b/Eigen/src/Core/functors/BinaryFunctors.h @@ -55,7 +55,7 @@ struct functor_traits> { Cost = (int(NumTraits::AddCost) + int(NumTraits::AddCost)) / 2, // rough estimate! PacketAccess = is_same::value && packet_traits::HasAdd && packet_traits::HasAdd - // TODO vectorize mixed sum + // TODO: vectorize mixed sum }; }; @@ -94,7 +94,7 @@ struct functor_traits> { Cost = (int(NumTraits::MulCost) + int(NumTraits::MulCost)) / 2, // rough estimate! PacketAccess = is_same::value && packet_traits::HasMul && packet_traits::HasMul - // TODO vectorize mixed product + // TODO: vectorize mixed product }; }; diff --git a/Eigen/src/Core/functors/UnaryFunctors.h b/Eigen/src/Core/functors/UnaryFunctors.h index 8c9f81393..996d9154c 100644 --- a/Eigen/src/Core/functors/UnaryFunctors.h +++ b/Eigen/src/Core/functors/UnaryFunctors.h @@ -367,7 +367,7 @@ template struct functor_traits> { enum { PacketAccess = packet_traits::HasExp, - Cost = functor_traits>::Cost // TODO measure cost of exp2 + Cost = functor_traits>::Cost // TODO: measure cost of exp2 }; }; @@ -389,7 +389,7 @@ template struct functor_traits> { enum { PacketAccess = packet_traits::HasExpm1, - Cost = functor_traits>::Cost // TODO measure cost of expm1 + Cost = functor_traits>::Cost // TODO: measure cost of expm1 }; }; @@ -443,7 +443,7 @@ template struct functor_traits> { enum { PacketAccess = packet_traits::HasLog1p, - Cost = functor_traits>::Cost // TODO measure cost of log1p + Cost = functor_traits>::Cost // TODO: measure cost of log1p }; }; diff --git a/Eigen/src/Core/products/GeneralBlockPanelKernel.h b/Eigen/src/Core/products/GeneralBlockPanelKernel.h index da6b04500..cb32270f4 100644 --- a/Eigen/src/Core/products/GeneralBlockPanelKernel.h +++ b/Eigen/src/Core/products/GeneralBlockPanelKernel.h @@ -189,7 +189,7 @@ void evaluateProductBlockingSizesHeuristic(Index& k, Index& m, Index& n, Index n #endif // Early return for small problems because the computation below are time consuming for small problems. - // Perhaps it would make more sense to consider k*n*m?? + // Perhaps it would make more sense to consider k*n*m? // Note that for very tiny problem, this function should be bypassed anyway // because we use the coefficient-based implementation for them. if ((numext::maxi)(k, (numext::maxi)(m, n)) < 48) return; @@ -2173,7 +2173,7 @@ EIGEN_DONT_INLINE void gemm_pack_rhs kernel; diff --git a/Eigen/src/Core/products/GeneralMatrixMatrixTriangular_BLAS.h b/Eigen/src/Core/products/GeneralMatrixMatrixTriangular_BLAS.h index c1df8564f..e14aa61c6 100644 --- a/Eigen/src/Core/products/GeneralMatrixMatrixTriangular_BLAS.h +++ b/Eigen/src/Core/products/GeneralMatrixMatrixTriangular_BLAS.h @@ -67,7 +67,7 @@ struct general_matrix_matrix_rankupdate EIGEN_BLAS_RANKUPDATE_SPECIALIZE(double) EIGEN_BLAS_RANKUPDATE_SPECIALIZE(float) -// TODO handle complex cases +// TODO: handle complex cases // EIGEN_BLAS_RANKUPDATE_SPECIALIZE(dcomplex) // EIGEN_BLAS_RANKUPDATE_SPECIALIZE(scomplex) @@ -137,7 +137,7 @@ EIGEN_BLAS_RANKUPDATE_R(double, double, dsyrk_) EIGEN_BLAS_RANKUPDATE_R(float, float, ssyrk_) #endif -// TODO handle complex cases +// TODO: handle complex cases // EIGEN_BLAS_RANKUPDATE_C(dcomplex, double, double, zherk_) // EIGEN_BLAS_RANKUPDATE_C(scomplex, float, float, cherk_) diff --git a/Eigen/src/Core/products/SelfadjointMatrixVector.h b/Eigen/src/Core/products/SelfadjointMatrixVector.h index 786822394..8a84aa45d 100644 --- a/Eigen/src/Core/products/SelfadjointMatrixVector.h +++ b/Eigen/src/Core/products/SelfadjointMatrixVector.h @@ -108,7 +108,7 @@ selfadjoint_matrix_vector_product(a1It); a1It += PacketSize; Packet Bi = ploadu(rhsIt); - rhsIt += PacketSize; // FIXME should be aligned in most cases + rhsIt += PacketSize; // FIXME: should be aligned in most cases. Packet Xi = pload(resIt); Xi = pcj0.pmadd(A0i, ptmp0, pcj0.pmadd(A1i, ptmp1, Xi)); diff --git a/Eigen/src/Core/products/TriangularSolverMatrix.h b/Eigen/src/Core/products/TriangularSolverMatrix.h index 7a5fe7e17..bee971d50 100644 --- a/Eigen/src/Core/products/TriangularSolverMatrix.h +++ b/Eigen/src/Core/products/TriangularSolverMatrix.h @@ -52,7 +52,7 @@ EIGEN_STRONG_INLINE void trsmKernelL > q(matrixQ, n, n); q.applyOnTheRight(k, k + 1, rot); } diff --git a/Eigen/src/Eigenvalues/Tridiagonalization.h b/Eigen/src/Eigenvalues/Tridiagonalization.h index 9cc92011f..aef8739f6 100644 --- a/Eigen/src/Eigenvalues/Tridiagonalization.h +++ b/Eigen/src/Eigenvalues/Tridiagonalization.h @@ -22,7 +22,7 @@ template struct TridiagonalizationMatrixTReturnType; template struct traits> : public traits { - typedef typename MatrixType::PlainObject ReturnType; // FIXME shall it be a BandMatrix? + typedef typename MatrixType::PlainObject ReturnType; // FIXME: consider using BandMatrix as ReturnType. enum { Flags = 0 }; }; diff --git a/Eigen/src/SVD/BDCSVD.h b/Eigen/src/SVD/BDCSVD.h index 43b4071e2..04bf5151c 100644 --- a/Eigen/src/SVD/BDCSVD.h +++ b/Eigen/src/SVD/BDCSVD.h @@ -983,7 +983,7 @@ void BDCSVD::computeSingVals(const ArrayRef& col0, const Ar // check that we did it right: eigen_internal_assert( (numext::isfinite)((col0(k) / leftShifted) * (col0(k) / (diag(k) + shift + leftShifted)))); - // I don't understand why the case k==0 would be special there: + // It is unclear why k==0 would need special handling here: // if (k == 0) rightShifted = right - left; else rightShifted = (k == actual_n - 1) ? right diff --git a/Eigen/src/SparseCore/AmbiVector.h b/Eigen/src/SparseCore/AmbiVector.h index 9f265f056..4af6f8825 100644 --- a/Eigen/src/SparseCore/AmbiVector.h +++ b/Eigen/src/SparseCore/AmbiVector.h @@ -173,7 +173,7 @@ Scalar_& AmbiVector::coeffRef(Index i) { return m_buffer[i]; else { ListEl* EIGEN_RESTRICT llElements = reinterpret_cast(m_buffer); - // TODO factorize the following code to reduce code generation + // TODO: factor out the following code to reduce code generation eigen_assert(m_mode == IsSparse); if (m_llSize == 0) { // this is the first element diff --git a/Eigen/src/SparseCore/SparseAssign.h b/Eigen/src/SparseCore/SparseAssign.h index f2da51934..b794263b4 100644 --- a/Eigen/src/SparseCore/SparseAssign.h +++ b/Eigen/src/SparseCore/SparseAssign.h @@ -25,7 +25,7 @@ Derived &SparseMatrixBase::operator=(const EigenBase &oth template template Derived &SparseMatrixBase::operator=(const ReturnByValue &other) { - // TODO use the evaluator mechanism + // TODO: use the evaluator mechanism other.evalTo(derived()); return derived(); } diff --git a/Eigen/src/SparseCore/SparseCwiseBinaryOp.h b/Eigen/src/SparseCore/SparseCwiseBinaryOp.h index 7fcf2c219..e3dcd57b2 100644 --- a/Eigen/src/SparseCore/SparseCwiseBinaryOp.h +++ b/Eigen/src/SparseCore/SparseCwiseBinaryOp.h @@ -32,7 +32,7 @@ namespace Eigen { // 4 - dense op dense product dense // generic dense // -// TODO to ease compiler job, we could specialize product/quotient with a scalar +// TODO: to ease compiler job, we could specialize product/quotient with a scalar // and fallback to cwise-unary evaluator using bind1st_op and bind2nd_op. template diff --git a/Eigen/src/SparseCore/SparseRef.h b/Eigen/src/SparseCore/SparseRef.h index da026af5c..aa8ae34fa 100644 --- a/Eigen/src/SparseCore/SparseRef.h +++ b/Eigen/src/SparseCore/SparseRef.h @@ -323,8 +323,8 @@ class Ref, Options, StrideTy namespace internal { -// FIXME shall we introduce a general evaluatior_ref that we can specialize for any sparse object once, and thus remove -// this copy-pasta thing... +// FIXME: consider introducing a general evaluator_ref that we can specialize for any sparse object once, and thus +// remove this copy-pasta thing... template struct evaluator, Options, StrideType>> diff --git a/Eigen/src/SparseCore/SparseSelfAdjointView.h b/Eigen/src/SparseCore/SparseSelfAdjointView.h index 05b3de56e..210462fc9 100644 --- a/Eigen/src/SparseCore/SparseSelfAdjointView.h +++ b/Eigen/src/SparseCore/SparseSelfAdjointView.h @@ -126,7 +126,7 @@ class SparseSelfAdjointView : public EigenBase& u, const Scalar& alpha = Scalar(1)); /** \returns an expression of P H P^-1 */ - // TODO implement twists in a more evaluator friendly fashion + // TODO: implement twists in a more evaluator friendly fashion SparseSymmetricPermutationProduct twistedBy( const PermutationMatrix& perm) const { return SparseSymmetricPermutationProduct(m_matrix, perm); @@ -205,7 +205,7 @@ SparseSelfAdjointView& SparseSelfAdjointView namespace internal { -// TODO currently a selfadjoint expression has the form SelfAdjointView<.,.> +// TODO: currently a selfadjoint expression has the form SelfAdjointView<.,.> // in the future selfadjoint-ness should be defined by the expression traits // such that Transpose > is valid. (currently TriangularBase::transpose() is overloaded to // make it work) diff --git a/Eigen/src/SparseCore/SparseVector.h b/Eigen/src/SparseCore/SparseVector.h index c8d34e318..66fbb07e5 100644 --- a/Eigen/src/SparseCore/SparseVector.h +++ b/Eigen/src/SparseCore/SparseVector.h @@ -168,7 +168,7 @@ class SparseVector : public SparseCompressedBase= startId) && (m_data.index(p) > i)) { diff --git a/Eigen/src/SparseCore/SparseView.h b/Eigen/src/SparseCore/SparseView.h index 7220beea4..d5668980c 100644 --- a/Eigen/src/SparseCore/SparseView.h +++ b/Eigen/src/SparseCore/SparseView.h @@ -75,7 +75,7 @@ class SparseView : public SparseMatrixBase > { namespace internal { -// TODO find a way to unify the two following variants +// TODO: find a way to unify the two following variants // This is tricky because implementing an inner iterator on top of an IndexBased evaluator is // not easy because the evaluators do not expose the sizes of the underlying expression. diff --git a/Eigen/src/SparseCore/TriangularSolver.h b/Eigen/src/SparseCore/TriangularSolver.h index ddc555683..b0054870a 100644 --- a/Eigen/src/SparseCore/TriangularSolver.h +++ b/Eigen/src/SparseCore/TriangularSolver.h @@ -130,7 +130,8 @@ struct sparse_solve_triangular_selector { if (!numext::is_exactly_zero(tmp)) // optimization when other is actually sparse { if (!(Mode & UnitDiag)) { - // TODO replace this by a binary search. make sure the binary search is safe for partially sorted elements + // TODO: replace this with a binary search. make sure the binary search is safe for partially sorted + // elements LhsIterator it(lhsEval, i); while (it && it.index() != i) ++it; eigen_assert(it && it.index() == i); diff --git a/Eigen/src/SparseLU/SparseLU_Memory.h b/Eigen/src/SparseLU/SparseLU_Memory.h index 22affd221..7acfa5c8f 100644 --- a/Eigen/src/SparseLU/SparseLU_Memory.h +++ b/Eigen/src/SparseLU/SparseLU_Memory.h @@ -128,7 +128,7 @@ Index SparseLUImpl::expand(VectorType& vec, Index& length, * \param n number of columns * \param annz number of initial nonzeros in the matrix * \param lwork if lwork=-1, this routine returns an estimated size of the required memory - * \param glu persistent data to facilitate multiple factors : will be deleted later ?? + * \param glu persistent data to facilitate multiple factors (may be deleted later). * \param fillratio estimated ratio of fill in the factors * \param panel_size Size of a panel * \return an estimated size of the required memory if lwork = -1; otherwise, return the size of actually allocated diff --git a/Eigen/src/SparseLU/SparseLU_column_bmod.h b/Eigen/src/SparseLU/SparseLU_column_bmod.h index 8435b5622..014ffc286 100644 --- a/Eigen/src/SparseLU/SparseLU_column_bmod.h +++ b/Eigen/src/SparseLU/SparseLU_column_bmod.h @@ -45,7 +45,7 @@ namespace internal { * \param dense Store the full representation of the column * \param tempv working array * \param segrep segment representative ... - * \param repfnz ??? First nonzero column in each row ??? ... + * \param repfnz first nonzero column in each row ... * \param fpanelc First column in the current panel * \param glu Global LU data. * \return 0 - successful return diff --git a/Eigen/src/SuperLUSupport/SuperLUSupport.h b/Eigen/src/SuperLUSupport/SuperLUSupport.h index 7d6fef2e2..bed414bd1 100644 --- a/Eigen/src/SuperLUSupport/SuperLUSupport.h +++ b/Eigen/src/SuperLUSupport/SuperLUSupport.h @@ -208,7 +208,7 @@ struct SluMatrix : SuperMatrix { res.setScalarType(); - // FIXME the following is not very accurate + // FIXME: the following type mapping is approximate. if (int(MatrixType::Flags) & int(Upper)) res.Mtype = SLU_TRU; if (int(MatrixType::Flags) & int(Lower)) res.Mtype = SLU_TRL; @@ -259,7 +259,7 @@ struct SluMatrixMapHelper > { res.setScalarType(); - // FIXME the following is not very accurate + // FIXME: the following type mapping is approximate. if (MatrixType::Flags & Upper) res.Mtype = SLU_TRU; if (MatrixType::Flags & Lower) res.Mtype = SLU_TRL; diff --git a/Eigen/src/ThreadPool/NonBlockingThreadPool.h b/Eigen/src/ThreadPool/NonBlockingThreadPool.h index 44d4b2432..a9f0bebf8 100644 --- a/Eigen/src/ThreadPool/NonBlockingThreadPool.h +++ b/Eigen/src/ThreadPool/NonBlockingThreadPool.h @@ -433,7 +433,7 @@ class ThreadPoolTempl : public Eigen::ThreadPoolInterface { // If we are shutting down and all worker threads blocked without work, // that's we are done. blocked_++; - // TODO is blocked_ required to be unsigned? + // TODO: is blocked_ required to be unsigned? if (done_ && blocked_ == static_cast(num_threads_)) { ec_.CancelWait(); // Almost done, but need to re-check queues. diff --git a/Eigen/src/UmfPackSupport/UmfPackSupport.h b/Eigen/src/UmfPackSupport/UmfPackSupport.h index a32331ce4..51e4db177 100644 --- a/Eigen/src/UmfPackSupport/UmfPackSupport.h +++ b/Eigen/src/UmfPackSupport/UmfPackSupport.h @@ -11,7 +11,7 @@ #define EIGEN_UMFPACKSUPPORT_H // for compatibility with super old version of umfpack, -// not sure this is really needed, but this is harmless. +// This may not be strictly needed, but it is harmless. #ifndef SuiteSparse_long #ifdef UF_long #define SuiteSparse_long UF_long diff --git a/Eigen/src/plugins/ArrayCwiseBinaryOps.inc b/Eigen/src/plugins/ArrayCwiseBinaryOps.inc index 7a4ab19fe..c7922c29c 100644 --- a/Eigen/src/plugins/ArrayCwiseBinaryOps.inc +++ b/Eigen/src/plugins/ArrayCwiseBinaryOps.inc @@ -133,7 +133,7 @@ EIGEN_MAKE_CWISE_BINARY_OP(pow, pow) */ EIGEN_MAKE_CWISE_BINARY_OP(atan2, atan2) -// TODO code generating macros could be moved to Macros.h and could include generation of documentation +// TODO: code generating macros could be moved to Macros.h and could include generation of documentation #define EIGEN_MAKE_CWISE_COMP_OP(OP, COMPARATOR) \ template \ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const \ diff --git a/bench/benchmark-blocking-sizes.cpp b/bench/benchmark-blocking-sizes.cpp index 8c94a797e..61c0aedc7 100644 --- a/bench/benchmark-blocking-sizes.cpp +++ b/bench/benchmark-blocking-sizes.cpp @@ -381,7 +381,7 @@ void try_run_some_benchmarks(vector& benchmarks, double time_start, // Clock speed is now higher than we previously measured. // Either our initial measurement was inaccurate, which won't happen // too many times as we are keeping the best clock speed value and - // and allowing some tolerance; or something really weird happened, + // and allowing some tolerance; or an unexpected condition occurred, // which invalidates all benchmark results collected so far. // Either way, we better restart all over again now. if (benchmark_index) { diff --git a/bench/eig33.cpp b/bench/eig33.cpp index 25df142fe..d623ac243 100644 --- a/bench/eig33.cpp +++ b/bench/eig33.cpp @@ -101,7 +101,7 @@ void eigen33(const Matrix& mat, Matrix& evecs, Vector& evals) { // compute the eigen vectors // **here we assume 3 different eigenvalues** - // "optimized version" which appears to be slower with gcc! + // "optimized version" which is slower with GCC! // Vector base; // Scalar alpha, beta; // base << scaledMat(1,0) * scaledMat(2,1), diff --git a/blas/level3_impl.h b/blas/level3_impl.h index 4ea1b46c2..03d634c72 100644 --- a/blas/level3_impl.h +++ b/blas/level3_impl.h @@ -486,7 +486,7 @@ EIGEN_BLAS_FUNC(trmm) if (*m == 0 || *n == 0) return; - // FIXME find a way to avoid this copy + // FIXME: find a way to avoid this copy Eigen::Matrix tmp = matrix(b, *m, *n, *ldb); matrix(b, *m, *n, *ldb).setZero(); diff --git a/demos/opengl/camera.cpp b/demos/opengl/camera.cpp index e50e3d7ba..0e5cc58ff 100644 --- a/demos/opengl/camera.cpp +++ b/demos/opengl/camera.cpp @@ -213,7 +213,7 @@ Vector3f Camera::unProject(const Vector2f& uv, float depth, const Matrix4f& invM a.x() *= depth / mProjectionMatrix(0, 0); a.y() *= depth / mProjectionMatrix(1, 1); a.z() = -depth; - // FIXME /\/| + // FIXME: verify this transformation. Vector4f b = invModelview * Vector4f(a.x(), a.y(), a.z(), 1.); return Vector3f(b.x(), b.y(), b.z()); } diff --git a/test/bug1213_main.cpp b/test/bug1213_main.cpp index 16150cf1e..354315507 100644 --- a/test/bug1213_main.cpp +++ b/test/bug1213_main.cpp @@ -1,5 +1,5 @@ -// This is a regression unit regarding a weird linking issue with gcc. +// This is a regression unit regarding an unusual linking issue with GCC. #include "bug1213.h" diff --git a/test/main.h b/test/main.h index fa7053e96..7ba0dc830 100644 --- a/test/main.h +++ b/test/main.h @@ -635,7 +635,7 @@ inline bool verifyIsCwiseApprox(const Type1& a, const Type2& b, bool exact) { // The idea behind this function is to compare the two scalars a and b where // the scalar ref is a hint about the expected order of magnitude of a and b. // WARNING: the scalar a and b must be positive -// Therefore, if for some reason a and b are very small compared to ref, +// Therefore, if a and b happen to be very small compared to ref, // we won't issue a false negative. // This test could be: abs(a-b) <= eps * ref // However, it seems that simply comparing a+ref and b+ref is more sensitive to true error. diff --git a/test/packetmath.cpp b/test/packetmath.cpp index fd27eb36c..37437aee0 100644 --- a/test/packetmath.cpp +++ b/test/packetmath.cpp @@ -127,7 +127,7 @@ inline T REF_FREXP(const T& x, T& exp) { exp = static_cast(iexp); // The exponent value is unspecified if the input is inf or NaN, but MSVC - // seems to set it to 1. We need to set it back to zero for consistency. + // sets it to 1. We need to set it back to zero for consistency. if (!(numext::isfinite)(x)) { exp = T(0); } diff --git a/test/prec_inverse_4x4.cpp b/test/prec_inverse_4x4.cpp index dc9967f63..157afa7f2 100644 --- a/test/prec_inverse_4x4.cpp +++ b/test/prec_inverse_4x4.cpp @@ -43,7 +43,7 @@ void inverse_general_4x4(int repeat) { double error_avg = error_sum / repeat; EIGEN_DEBUG_VAR(error_avg); EIGEN_DEBUG_VAR(error_max); - // FIXME that 1.25 used to be a 1.0 until the NumTraits changes on 28 April 2010, what's going wrong?? + // FIXME: that 1.25 used to be 1.0 until the NumTraits changes on 28 April 2010. // FIXME that 1.25 used to be 1.2 until we tested gcc 4.1 on 30 June 2010 and got 1.21. VERIFY(error_avg < (NumTraits::IsComplex ? 8.0 : 1.25)); VERIFY(error_max < (NumTraits::IsComplex ? 64.0 : 20.0)); diff --git a/test/rand.cpp b/test/rand.cpp index 0145299a7..eb7077740 100644 --- a/test/rand.cpp +++ b/test/rand.cpp @@ -14,7 +14,7 @@ // SafeScalar is used to simulate custom Scalar types, which use a more generalized approach to generate random // numbers -// For GCC-6, if this function is inlined then there seems to be an optimization +// For GCC-6, if this function is inlined then there is an optimization // bug that triggers a failure. This failure goes away if you access `r` in // in any way, and for any other compiler. template diff --git a/unsupported/Eigen/src/FFT/kissfft_impl.h b/unsupported/Eigen/src/FFT/kissfft_impl.h index c201d8047..c7e5960ce 100644 --- a/unsupported/Eigen/src/FFT/kissfft_impl.h +++ b/unsupported/Eigen/src/FFT/kissfft_impl.h @@ -389,7 +389,7 @@ struct kissfft_impl { inline int PlanKey(int nfft, bool isinverse) const { return (nfft << 1) | int(isinverse); } inline PlanData &get_plan(int nfft, bool inverse) { - // TODO look for PlanKey(nfft, ! inverse) and conjugate the twiddles + // TODO: look for PlanKey(nfft, ! inverse) and conjugate the twiddles PlanData &pd = m_plans[PlanKey(nfft, inverse)]; if (pd.m_twiddles.size() == 0) { pd.make_twiddles(nfft, inverse); diff --git a/unsupported/Eigen/src/IterativeSolvers/IDRSTABL.h b/unsupported/Eigen/src/IterativeSolvers/IDRSTABL.h index e55c3b3cc..a08a71d04 100644 --- a/unsupported/Eigen/src/IterativeSolvers/IDRSTABL.h +++ b/unsupported/Eigen/src/IterativeSolvers/IDRSTABL.h @@ -208,7 +208,7 @@ bool idrstabl(const MatrixType &mat, const Rhs &rhs, Dest &x, const Precondition // Pre-allocate sigma. DenseMatrixType sigma(S, S); - bool reset_while = false; // Should the while loop be reset for some reason? + bool reset_while = false; // Should the while loop be reset? while (k < maxIters) { for (Index j = 1; j <= L; ++j) { diff --git a/unsupported/Eigen/src/SparseExtra/BlockSparseMatrix.h b/unsupported/Eigen/src/SparseExtra/BlockSparseMatrix.h index 6e8be8490..7b6a01244 100644 --- a/unsupported/Eigen/src/SparseExtra/BlockSparseMatrix.h +++ b/unsupported/Eigen/src/SparseExtra/BlockSparseMatrix.h @@ -65,7 +65,7 @@ template > { typedef Scalar_ Scalar; typedef Index_ Index; - typedef Sparse StorageKind; // FIXME Where is it used ?? + typedef Sparse StorageKind; // FIXME: determine where StorageKind is used. typedef MatrixXpr XprKind; enum { RowsAtCompileTime = Dynamic, @@ -315,7 +315,7 @@ class BlockSparseMatrix m_nonzeros(other.m_nonzeros), m_blockPtr(0), m_blockSize(other.m_blockSize) { - // should we allow copying between variable-size blocks and fixed-size blocks ?? + // TODO: decide whether to allow copying between variable-size and fixed-size blocks. eigen_assert(m_blockSize == BlockSize && " CAN NOT COPY BETWEEN FIXED-SIZE AND VARIABLE-SIZE BLOCKS"); std::copy(other.m_innerOffset, other.m_innerOffset + m_innerBSize + 1, m_innerOffset); @@ -486,7 +486,7 @@ class BlockSparseMatrix m_indices[offset] = nzBlockIdx[idx]; if (m_blockSize == Dynamic) m_blockPtr[offset] = m_blockPtr[offset - 1] + blockInnerSize(nzBlockIdx[idx]) * blockOuterSize(bj); - // There is no blockPtr for fixed-size blocks... not needed !??? + // There is no blockPtr for fixed-size blocks; not needed. } // Save the pointer to the next outer block m_outerIndex[bj + 1] = m_outerIndex[bj] + nzBlockIdx.size(); @@ -810,7 +810,7 @@ class BlockSparseMatrix return (m_blockSize == Dynamic) ? m_innerOffset[bi] : (bi * m_blockSize); } - // Not needed ??? + // Not needed. inline Index blockInnerSize(Index bi) const { return (m_blockSize == Dynamic) ? (m_innerOffset[bi + 1] - m_innerOffset[bi]) : m_blockSize; } diff --git a/unsupported/test/special_functions.cpp b/unsupported/test/special_functions.cpp index a63a2ea8f..0abad059d 100644 --- a/unsupported/test/special_functions.cpp +++ b/unsupported/test/special_functions.cpp @@ -11,7 +11,7 @@ #include "main.h" #include "../Eigen/SpecialFunctions" -// Hack to allow "implicit" conversions from double to Scalar via comma-initialization. +// Workaround to allow "implicit" conversions from double to Scalar via comma-initialization. template Eigen::CommaInitializer operator<<(Eigen::DenseBase& dense, double v) { return (dense << static_cast(v));