diff options
Diffstat (limited to 'Eigen/src/LU')
-rw-r--r-- | Eigen/src/LU/Inverse.h | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/Eigen/src/LU/Inverse.h b/Eigen/src/LU/Inverse.h index 9e0c46094..1e9d69a22 100644 --- a/Eigen/src/LU/Inverse.h +++ b/Eigen/src/LU/Inverse.h @@ -281,15 +281,9 @@ struct ei_traits<ei_inverse_impl<MatrixType> > template<typename MatrixType> struct ei_inverse_impl : public ReturnByValue<ei_inverse_impl<MatrixType> > { - // for 2x2, it's worth giving a chance to avoid evaluating. - // for larger sizes, evaluating has negligible cost, limits code size, - // and allows for vectorized paths. - typedef typename ei_meta_if< - MatrixType::RowsAtCompileTime == 2, - typename ei_nested<MatrixType,2>::type, - typename ei_eval<MatrixType>::type - >::ret MatrixTypeNested; + typedef typename MatrixType::Nested MatrixTypeNested; typedef typename ei_cleantype<MatrixTypeNested>::type MatrixTypeNestedCleaned; + const MatrixTypeNested m_matrix; ei_inverse_impl(const MatrixType& matrix) @@ -359,14 +353,7 @@ inline void MatrixBase<Derived>::computeInverseAndDetWithCheck( { // i'd love to put some static assertions there, but SFINAE means that they have no effect... ei_assert(rows() == cols()); - // for 2x2, it's worth giving a chance to avoid evaluating. - // for larger sizes, evaluating has negligible cost and limits code size. - typedef typename ei_meta_if< - RowsAtCompileTime == 2, - typename ei_cleantype<typename ei_nested<Derived, 2>::type>::type, - PlainObject - >::ret MatrixType; - ei_compute_inverse_and_det_with_check<MatrixType, ResultType>::run + ei_compute_inverse_and_det_with_check<PlainObject, ResultType>::run (derived(), absDeterminantThreshold, inverse, determinant, invertible); } |