Home
last modified time | relevance | path

Searched refs:TensorOpCost (Results 1 – 25 of 29) sorted by relevance

12

/external/eigen/unsupported/Eigen/CXX11/src/Tensor/
DTensorCostModel.h25 class TensorOpCost {
55 TensorOpCost() : bytes_loaded_(0), bytes_stored_(0), compute_cycles_(0) {} in TensorOpCost() function
57 TensorOpCost(double bytes_loaded, double bytes_stored, double compute_cycles) in TensorOpCost() function
63 TensorOpCost(double bytes_loaded, double bytes_stored, double compute_cycles, in TensorOpCost() function
97 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost cwiseMin( in cwiseMin()
98 const TensorOpCost& rhs) const { in cwiseMin()
102 return TensorOpCost(bytes_loaded, bytes_stored, compute_cycles); in cwiseMin()
106 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost cwiseMax( in cwiseMax()
107 const TensorOpCost& rhs) const { in cwiseMax()
111 return TensorOpCost(bytes_loaded, bytes_stored, compute_cycles); in cwiseMax()
[all …]
DTensorBroadcasting.h351 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
353 double compute_cost = TensorOpCost::AddCost<Index>();
356 compute_cost += TensorOpCost::DivCost<Index>();
359 TensorOpCost::MulCost<Index>() + TensorOpCost::AddCost<Index>();
362 compute_cost += TensorOpCost::MulCost<Index>() +
363 TensorOpCost::ModCost<Index>() +
364 TensorOpCost::AddCost<Index>();
368 TensorOpCost::MulCost<Index>() + TensorOpCost::AddCost<Index>();
372 TensorOpCost(0, 0, compute_cost, vectorized, PacketSize);
DTensorPadding.h189 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
190 TensorOpCost cost = m_impl.costPerCoeff(vectorized);
238 void updateCostPerDimension(TensorOpCost& cost, int i, bool first) const {
246 cost += TensorOpCost(0, 0, 2 * TensorOpCost::AddCost<Index>() +
247 reduction * (1 * TensorOpCost::AddCost<Index>()));
249 cost += TensorOpCost(0, 0, 2 * TensorOpCost::AddCost<Index>() +
250 2 * TensorOpCost::MulCost<Index>() +
251 reduction * (2 * TensorOpCost::MulCost<Index>() +
252 1 * TensorOpCost::DivCost<Index>()));
DTensorInflation.h203 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
204 const double compute_cost = NumDims * (3 * TensorOpCost::DivCost<Index>() +
205 3 * TensorOpCost::MulCost<Index>() +
206 2 * TensorOpCost::AddCost<Index>());
210 return TensorOpCost();
212 TensorOpCost(sizeof(CoeffReturnType) * input_size / output_size, 0,
DTensorEvaluator.h106 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const { in costPerCoeff()
107 return TensorOpCost(sizeof(CoeffReturnType), 0, 0, vectorized, in costPerCoeff()
205 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
206 return TensorOpCost(sizeof(CoeffReturnType), 0, 0, vectorized,
268 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
270 return TensorOpCost(sizeof(CoeffReturnType), 0, 0, vectorized,
338 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
341 TensorOpCost(0, 0, functor_cost, vectorized, PacketSize);
416 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
421 TensorOpCost(0, 0, functor_cost, vectorized, PacketSize);
[all …]
DTensorReverse.h212 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
213 double compute_cost = NumDims * (2 * TensorOpCost::AddCost<Index>() +
214 2 * TensorOpCost::MulCost<Index>() +
215 TensorOpCost::DivCost<Index>());
218 compute_cost += 2 * TensorOpCost::AddCost<Index>();
222 TensorOpCost(0, 0, compute_cost, false /* vectorized */, PacketSize);
DTensorArgMax.h115 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
117 return m_impl.costPerCoeff(vectorized) + TensorOpCost(0, 0, 1);
257 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
260 … (m_return_dim < 0 ? 0.0 : (TensorOpCost::ModCost<Index>() + TensorOpCost::DivCost<Index>()));
262 m_impl.costPerCoeff(vectorized) + TensorOpCost(0, 0, compute_cost);
DTensorChipping.h244 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
251 cost += TensorOpCost::MulCost<Index>() + TensorOpCost::AddCost<Index>();
256 cost += TensorOpCost::AddCost<Index>();
258 cost += 3 * TensorOpCost::MulCost<Index>() + TensorOpCost::DivCost<Index>() +
259 3 * TensorOpCost::AddCost<Index>();
263 TensorOpCost(0, 0, cost, vectorized, PacketSize);
DTensorGenerator.h148 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
152 return TensorOpCost(0, 0, TensorOpCost::AddCost<Scalar>() +
153 TensorOpCost::MulCost<Scalar>());
DTensorShuffling.h180 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
181 const double compute_cost = NumDims * (2 * TensorOpCost::AddCost<Index>() +
182 2 * TensorOpCost::MulCost<Index>() +
183 TensorOpCost::DivCost<Index>());
185 TensorOpCost(0, 0, compute_cost, false /* vectorized */, PacketSize);
DTensorAssign.h153 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
158 TensorOpCost left = m_leftImpl.costPerCoeff(vectorized);
160 TensorOpCost(
163 TensorOpCost(0, sizeof(CoeffReturnType), 0, vectorized, PacketSize);
DTensorPatch.h248 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
249 const double compute_cost = NumDims * (TensorOpCost::DivCost<Index>() +
250 TensorOpCost::MulCost<Index>() +
251 2 * TensorOpCost::AddCost<Index>());
253 TensorOpCost(0, 0, compute_cost, vectorized, PacketSize);
DTensorStriding.h211 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
212 double compute_cost = (NumDims - 1) * (TensorOpCost::AddCost<Index>() +
213 TensorOpCost::MulCost<Index>() +
214 TensorOpCost::DivCost<Index>()) +
215 TensorOpCost::MulCost<Index>();
222 TensorOpCost(0, 0, compute_cost, vectorized, PacketSize);
DTensorConvolution.h451 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
456 TensorOpCost::AddCost<Scalar>() + TensorOpCost::MulCost<Scalar>();
459 (2 * TensorOpCost::AddCost<Index>() + 2 * TensorOpCost::MulCost<Index>() +
460 TensorOpCost::DivCost<Index>());
461 return TensorOpCost(0, 0, firstIndex_compute_cost, vectorized, PacketSize) +
464 TensorOpCost(0, 0, convolve_compute_cost, vectorized,
1065 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
1072 TensorOpCost::AddCost<Scalar>() + TensorOpCost::MulCost<Scalar>();
1075 (2 * TensorOpCost::AddCost<Index>() + 2 * TensorOpCost::MulCost<Index>() +
1076 TensorOpCost::DivCost<Index>());
[all …]
DTensorConcatenation.h263 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
265 const double compute_cost = NumDims * (2 * TensorOpCost::AddCost<Index>() +
266 2 * TensorOpCost::MulCost<Index>() +
267 TensorOpCost::DivCost<Index>() +
268 TensorOpCost::ModCost<Index>());
275 TensorOpCost(0, 0, compute_cost);
DTensorConversion.h232 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
234 const double cast_cost = TensorOpCost::CastCost<SrcType, TargetType>();
241 TensorOpCost(0, 0, TgtCoeffRatio * (cast_cost / PacketSize));
243 return m_impl.costPerCoeff(vectorized) + TensorOpCost(0, 0, cast_cost);
DTensorCustomOp.h136 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
138 return TensorOpCost(sizeof(CoeffReturnType), 0, 0, vectorized, PacketSize);
291 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
293 return TensorOpCost(sizeof(CoeffReturnType), 0, 0, vectorized, PacketSize);
DTensorImagePatch.h436 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
441 const double compute_cost = 3 * TensorOpCost::DivCost<Index>() +
442 6 * TensorOpCost::MulCost<Index>() +
443 8 * TensorOpCost::MulCost<Index>();
445 TensorOpCost(0, 0, compute_cost, vectorized, PacketSize);
DTensorForcedEval.h147 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
148 return TensorOpCost(sizeof(CoeffReturnType), 0, 0, vectorized, PacketSize);
DTensorContractionThreadPool.h203 const TensorOpCost cost =
703 const TensorOpCost cost =
1008 TensorOpCost contractionCost(Index m, Index n, Index bm, Index bn, Index bk,
1027 TensorOpCost cost = TensorOpCost(0, 0, kd * computeBandwidth, true, packed_size);
1029 cost += TensorOpCost(0, sizeof(CoeffReturnType), 0, true, output_packet_size);
1037 TensorOpCost lhsCost = this->m_leftImpl.costPerCoeff(true) * (kd / n);
1038 TensorOpCost rhsCost = this->m_rightImpl.costPerCoeff(true) * (kd / m);
DTensorEvalTo.h155 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
159 TensorOpCost(0, sizeof(CoeffReturnType), 0, vectorized, PacketSize);
DTensorVolumePatch.h497 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost
500 10 * TensorOpCost::DivCost<Index>() + 21 * TensorOpCost::MulCost<Index>() +
501 8 * TensorOpCost::AddCost<Index>();
502 return TensorOpCost(0, 0, compute_cost, vectorized, PacketSize);
DTensorDeviceThreadPool.h182 void parallelFor(Index n, const TensorOpCost& cost, in parallelFor()
266 void parallelFor(Index n, const TensorOpCost& cost, in parallelFor()
DTensorScan.h188 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool) const {
189 return TensorOpCost(sizeof(CoeffReturnType), 0, 0);
DTensorReduction.h258 const TensorOpCost cost =
260 TensorOpCost(0, 0, internal::functor_traits<Op>::Cost, Vectorizable,
654 EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const {
656 return TensorOpCost(sizeof(CoeffReturnType), 0, 0, vectorized, PacketSize);
661 TensorOpCost(0, 0, compute_cost, vectorized, PacketSize);

12