aboutsummaryrefslogtreecommitdiffhomepage
path: root/unsupported/Eigen/CXX11/src/Tensor/TensorEvaluator.h
diff options
context:
space:
mode:
authorGravatar Eugene Zhulenev <ezhulenev@google.com>2019-11-12 10:12:28 -0800
committerGravatar Eugene Zhulenev <ezhulenev@google.com>2019-11-12 10:12:28 -0800
commit13c3327f5cf829fd9d04a2ab46861e722cd74ca0 (patch)
tree20bd1a5f361023db822298696efbcff7378ab4a7 /unsupported/Eigen/CXX11/src/Tensor/TensorEvaluator.h
parent71aa53dd6dfdc497324d9e87f59c4ba820191856 (diff)
Remove legacy block evaluation support
Diffstat (limited to 'unsupported/Eigen/CXX11/src/Tensor/TensorEvaluator.h')
-rw-r--r--unsupported/Eigen/CXX11/src/Tensor/TensorEvaluator.h72
1 files changed, 0 insertions, 72 deletions
diff --git a/unsupported/Eigen/CXX11/src/Tensor/TensorEvaluator.h b/unsupported/Eigen/CXX11/src/Tensor/TensorEvaluator.h
index ce2305b56..d6a3e6abe 100644
--- a/unsupported/Eigen/CXX11/src/Tensor/TensorEvaluator.h
+++ b/unsupported/Eigen/CXX11/src/Tensor/TensorEvaluator.h
@@ -45,7 +45,6 @@ struct TensorEvaluator
enum {
IsAligned = Derived::IsAligned,
PacketAccess = (PacketType<CoeffReturnType, Device>::size > 1),
- BlockAccess = internal::is_arithmetic<typename internal::remove_const<Scalar>::type>::value,
BlockAccessV2 = internal::is_arithmetic<typename internal::remove_const<Scalar>::type>::value,
PreferBlockAccess = false,
Layout = Derived::Layout,
@@ -55,13 +54,6 @@ struct TensorEvaluator
typedef typename internal::remove_const<Scalar>::type ScalarNoConst;
- typedef typename internal::TensorBlock<ScalarNoConst, Index, NumCoords, Layout>
- TensorBlock;
- typedef typename internal::TensorBlockReader<ScalarNoConst, Index, NumCoords, Layout>
- TensorBlockReader;
- typedef typename internal::TensorBlockWriter<ScalarNoConst, Index, NumCoords, Layout>
- TensorBlockWriter;
-
//===- Tensor block evaluation strategy (see TensorBlock.h) -------------===//
typedef internal::TensorBlockDescriptor<NumCoords, Index> TensorBlockDesc;
typedef internal::TensorBlockScratchAllocator<Device> TensorBlockScratch;
@@ -160,11 +152,6 @@ struct TensorEvaluator
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void getResourceRequirements(
std::vector<internal::TensorOpResourceRequirements>*) const {}
- EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void block(TensorBlock* block) const {
- assert(m_data != NULL);
- TensorBlockReader::Run(block, m_data);
- }
-
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorBlockV2
blockV2(TensorBlockDesc& desc, TensorBlockScratch& scratch,
bool /*root_of_expr_ast*/ = false) const {
@@ -172,12 +159,6 @@ struct TensorEvaluator
return TensorBlockV2::materialize(m_data, m_dims, desc, scratch);
}
- EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void writeBlock(
- const TensorBlock& block) {
- assert(m_data != NULL);
- TensorBlockWriter::Run(block, m_data);
- }
-
template<typename TensorBlockV2>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void writeBlockV2(
const TensorBlockDesc& desc, const TensorBlockV2& block) {
@@ -263,7 +244,6 @@ struct TensorEvaluator<const Derived, Device>
enum {
IsAligned = Derived::IsAligned,
PacketAccess = (PacketType<CoeffReturnType, Device>::size > 1),
- BlockAccess = internal::is_arithmetic<ScalarNoConst>::value,
BlockAccessV2 = internal::is_arithmetic<ScalarNoConst>::value,
PreferBlockAccess = false,
Layout = Derived::Layout,
@@ -271,11 +251,6 @@ struct TensorEvaluator<const Derived, Device>
RawAccess = true
};
- typedef typename internal::TensorBlock<ScalarNoConst, Index, NumCoords, Layout>
- TensorBlock;
- typedef typename internal::TensorBlockReader<ScalarNoConst, Index, NumCoords, Layout>
- TensorBlockReader;
-
//===- Tensor block evaluation strategy (see TensorBlock.h) -------------===//
typedef internal::TensorBlockDescriptor<NumCoords, Index> TensorBlockDesc;
typedef internal::TensorBlockScratchAllocator<Device> TensorBlockScratch;
@@ -348,11 +323,6 @@ struct TensorEvaluator<const Derived, Device>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void getResourceRequirements(
std::vector<internal::TensorOpResourceRequirements>*) const {}
- EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void block(TensorBlock* block) const {
- assert(m_data != NULL);
- TensorBlockReader::Run(block, m_data);
- }
-
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorBlockV2
blockV2(TensorBlockDesc& desc, TensorBlockScratch& scratch,
bool /*root_of_expr_ast*/ = false) const {
@@ -404,7 +374,6 @@ struct TensorEvaluator<const TensorCwiseNullaryOp<NullaryOp, ArgType>, Device>
&& (PacketType<CoeffReturnType, Device>::size >1)
#endif
,
- BlockAccess = false,
BlockAccessV2 = false,
PreferBlockAccess = false,
Layout = TensorEvaluator<ArgType, Device>::Layout,
@@ -475,7 +444,6 @@ struct TensorEvaluator<const TensorCwiseUnaryOp<UnaryOp, ArgType>, Device>
IsAligned = TensorEvaluator<ArgType, Device>::IsAligned,
PacketAccess = TensorEvaluator<ArgType, Device>::PacketAccess &
internal::functor_traits<UnaryOp>::PacketAccess,
- BlockAccess = TensorEvaluator<ArgType, Device>::BlockAccess,
BlockAccessV2 = TensorEvaluator<ArgType, Device>::BlockAccessV2,
PreferBlockAccess = TensorEvaluator<ArgType, Device>::PreferBlockAccess,
Layout = TensorEvaluator<ArgType, Device>::Layout,
@@ -554,24 +522,6 @@ struct TensorEvaluator<const TensorCwiseUnaryOp<UnaryOp, ArgType>, Device>
m_argImpl.getResourceRequirements(resources);
}
- EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void block(
- TensorBlock* output_block) const {
- if (NumDims <= 0) {
- output_block->data()[0] = coeff(0);
- return;
- }
- internal::TensorBlockView<ArgType, Device> arg_block(m_device, m_argImpl,
- *output_block);
- internal::TensorBlockCwiseUnaryIO<UnaryOp, Index, ScalarNoConst, NumDims,
- Layout>::Run(m_functor,
- output_block->block_sizes(),
- output_block
- ->block_strides(),
- output_block->data(),
- arg_block.block_strides(),
- arg_block.data());
- }
-
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorBlockV2
blockV2(TensorBlockDesc& desc, TensorBlockScratch& scratch,
bool /*root_of_expr_ast*/ = false) const {
@@ -608,8 +558,6 @@ struct TensorEvaluator<const TensorCwiseBinaryOp<BinaryOp, LeftArgType, RightArg
PacketAccess = TensorEvaluator<LeftArgType, Device>::PacketAccess &
TensorEvaluator<RightArgType, Device>::PacketAccess &
internal::functor_traits<BinaryOp>::PacketAccess,
- BlockAccess = TensorEvaluator<LeftArgType, Device>::BlockAccess &
- TensorEvaluator<RightArgType, Device>::BlockAccess,
BlockAccessV2 = TensorEvaluator<LeftArgType, Device>::BlockAccessV2 &
TensorEvaluator<RightArgType, Device>::BlockAccessV2,
PreferBlockAccess = TensorEvaluator<LeftArgType, Device>::PreferBlockAccess |
@@ -713,24 +661,6 @@ struct TensorEvaluator<const TensorCwiseBinaryOp<BinaryOp, LeftArgType, RightArg
m_rightImpl.getResourceRequirements(resources);
}
- EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void block(
- TensorBlock* output_block) const {
- if (NumDims <= 0) {
- output_block->data()[0] = coeff(Index(0));
- return;
- }
- internal::TensorBlockView<LeftArgType, Device> left_block(
- m_device, m_leftImpl, *output_block);
- internal::TensorBlockView<RightArgType, Device> right_block(
- m_device, m_rightImpl, *output_block);
- internal::TensorBlockCwiseBinaryIO<
- BinaryOp, Index, typename internal::remove_const<Scalar>::type, NumDims,
- Layout>::Run(m_functor, output_block->block_sizes(),
- output_block->block_strides(), output_block->data(),
- left_block.block_strides(), left_block.data(),
- right_block.block_strides(), right_block.data());
- }
-
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorBlockV2
blockV2(TensorBlockDesc& desc, TensorBlockScratch& scratch,
bool /*root_of_expr_ast*/ = false) const {
@@ -768,7 +698,6 @@ struct TensorEvaluator<const TensorCwiseTernaryOp<TernaryOp, Arg1Type, Arg2Type,
TensorEvaluator<Arg2Type, Device>::PacketAccess &&
TensorEvaluator<Arg3Type, Device>::PacketAccess &&
internal::functor_traits<TernaryOp>::PacketAccess,
- BlockAccess = false,
BlockAccessV2 = false,
PreferBlockAccess = TensorEvaluator<Arg1Type, Device>::PreferBlockAccess ||
TensorEvaluator<Arg2Type, Device>::PreferBlockAccess ||
@@ -887,7 +816,6 @@ struct TensorEvaluator<const TensorSelectOp<IfArgType, ThenArgType, ElseArgType>
PacketAccess = TensorEvaluator<ThenArgType, Device>::PacketAccess &
TensorEvaluator<ElseArgType, Device>::PacketAccess &
PacketType<Scalar, Device>::HasBlend,
- BlockAccess = false,
BlockAccessV2 = TensorEvaluator<IfArgType, Device>::BlockAccessV2 &&
TensorEvaluator<ThenArgType, Device>::BlockAccessV2 &&
TensorEvaluator<ElseArgType, Device>::BlockAccessV2,