diff options
author | 2007-09-29 08:28:36 +0000 | |
---|---|---|
committer | 2007-09-29 08:28:36 +0000 | |
commit | ee63e15e2cad25d8acd0ac6ba6dc9d7a84f74f6c (patch) | |
tree | 8a7ee0fbbf3a2033a0b1a9073f9d35f862e13f28 /src/internal/Matrix.h | |
parent | 51e29ae4bd9d725c3a68fe94766c73ba8c717688 (diff) |
make matrix multiplication do immediate evaluation; add lazyMul() for the old behaviour
some reorganization, especially in MatrixStorage
start playing with loop unrolling, always_inline, and __restrict__
Diffstat (limited to 'src/internal/Matrix.h')
-rw-r--r-- | src/internal/Matrix.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/internal/Matrix.h b/src/internal/Matrix.h index 738cc9f6b..faed649c2 100644 --- a/src/internal/Matrix.h +++ b/src/internal/Matrix.h @@ -44,22 +44,22 @@ class EiMatrix : public EiObject<_Scalar, EiMatrix<_Scalar, _Rows, _Cols> >, static const int RowsAtCompileTime = _Rows, ColsAtCompileTime = _Cols; - const Scalar* array() const + const Scalar* EI_RESTRICT array() const { return Storage::m_array; } - Scalar* array() + Scalar* EI_RESTRICT array() { return Storage::m_array; } private: Ref _ref() const { return Ref(*const_cast<EiMatrix*>(this)); } - const Scalar& _read(int row, int col = 0) const + const Scalar& EI_RESTRICT _read(int row, int col = 0) const { EI_CHECK_RANGES(*this, row, col); return array()[row + col * Storage::_rows()]; } - Scalar& _write(int row, int col = 0) + Scalar& EI_RESTRICT _write(int row, int col = 0) { EI_CHECK_RANGES(*this, row, col); return array()[row + col * Storage::_rows()]; |