diff --git a/unsupported/Eigen/CXX11/src/Tensor/TensorExecutor.h b/unsupported/Eigen/CXX11/src/Tensor/TensorExecutor.h index bc06ca1f0..956672771 100644 --- a/unsupported/Eigen/CXX11/src/Tensor/TensorExecutor.h +++ b/unsupported/Eigen/CXX11/src/Tensor/TensorExecutor.h @@ -50,6 +50,7 @@ class TensorExecutor { public: typedef typename Expression::Index Index; + EIGEN_DEVICE_FUNC static inline void run(const Expression& expr, const DefaultDevice& device = DefaultDevice()) { TensorEvaluator evaluator(expr, device); @@ -57,7 +58,7 @@ class TensorExecutor if (needs_assign) { const Index size = array_prod(evaluator.dimensions()); - static const int PacketSize = unpacket_traits::PacketReturnType>::size; + const int PacketSize = unpacket_traits::PacketReturnType>::size; const Index VectorizedSize = (size / PacketSize) * PacketSize; for (Index i = 0; i < VectorizedSize; i += PacketSize) {