aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/CommaInitializer.h
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2013-02-07 19:06:14 +0100
committerGravatar Gael Guennebaud <g.gael@free.fr>2013-02-07 19:06:14 +0100
commit5adcc6c7b48b7a213af91bc123a02ab87751228e (patch)
tree5e0ee840a8fb9acbbb48c5c48f1bffe0ca3cfe2a /Eigen/src/Core/CommaInitializer.h
parente4ec63aee7233f5b934abc0b1d9ceada79a844ee (diff)
Add support for NVCC5: most of the Core and part of LU are callable from CUDA code.
Still a lot to do.
Diffstat (limited to 'Eigen/src/Core/CommaInitializer.h')
-rw-r--r--Eigen/src/Core/CommaInitializer.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/Eigen/src/Core/CommaInitializer.h b/Eigen/src/Core/CommaInitializer.h
index f20c1774c..1f801e2a0 100644
--- a/Eigen/src/Core/CommaInitializer.h
+++ b/Eigen/src/Core/CommaInitializer.h
@@ -30,6 +30,7 @@ struct CommaInitializer
typedef typename XprType::Scalar Scalar;
typedef typename XprType::Index Index;
+ EIGEN_DEVICE_FUNC
inline CommaInitializer(XprType& xpr, const Scalar& s)
: m_xpr(xpr), m_row(0), m_col(1), m_currentBlockRows(1)
{
@@ -37,6 +38,7 @@ struct CommaInitializer
}
template<typename OtherDerived>
+ EIGEN_DEVICE_FUNC
inline CommaInitializer(XprType& xpr, const DenseBase<OtherDerived>& other)
: m_xpr(xpr), m_row(0), m_col(other.cols()), m_currentBlockRows(other.rows())
{
@@ -44,6 +46,7 @@ struct CommaInitializer
}
/* inserts a scalar value in the target matrix */
+ EIGEN_DEVICE_FUNC
CommaInitializer& operator,(const Scalar& s)
{
if (m_col==m_xpr.cols())
@@ -63,6 +66,7 @@ struct CommaInitializer
/* inserts a matrix expression in the target matrix */
template<typename OtherDerived>
+ EIGEN_DEVICE_FUNC
CommaInitializer& operator,(const DenseBase<OtherDerived>& other)
{
if(other.cols()==0 || other.rows()==0)
@@ -88,6 +92,7 @@ struct CommaInitializer
return *this;
}
+ EIGEN_DEVICE_FUNC
inline ~CommaInitializer()
{
eigen_assert((m_row+m_currentBlockRows) == m_xpr.rows()
@@ -102,6 +107,7 @@ struct CommaInitializer
* quaternion.fromRotationMatrix((Matrix3f() << axis0, axis1, axis2).finished());
* \endcode
*/
+ EIGEN_DEVICE_FUNC
inline XprType& finished() { return m_xpr; }
XprType& m_xpr; // target expression