diff options
author | Christoph Hertzberg <chtz@informatik.uni-bremen.de> | 2016-05-22 16:42:27 +0200 |
---|---|---|
committer | Christoph Hertzberg <chtz@informatik.uni-bremen.de> | 2016-05-22 16:42:27 +0200 |
commit | 25a03c02d6d7ad129943c312694a227e4b70f6f6 (patch) | |
tree | 86bfd964020ba237606bb628801e997a32296d1b /unsupported/Eigen/CXX11/src/Tensor/TensorContractionThreadPool.h | |
parent | 0851d5d210129e894fcd5d0855c5a11896d16e4a (diff) |
Fix some sign-compare warnings
Diffstat (limited to 'unsupported/Eigen/CXX11/src/Tensor/TensorContractionThreadPool.h')
-rw-r--r-- | unsupported/Eigen/CXX11/src/Tensor/TensorContractionThreadPool.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/unsupported/Eigen/CXX11/src/Tensor/TensorContractionThreadPool.h b/unsupported/Eigen/CXX11/src/Tensor/TensorContractionThreadPool.h index 88d485f38..d6af6fedd 100644 --- a/unsupported/Eigen/CXX11/src/Tensor/TensorContractionThreadPool.h +++ b/unsupported/Eigen/CXX11/src/Tensor/TensorContractionThreadPool.h @@ -273,7 +273,7 @@ struct TensorEvaluator<const TensorContractionOp<Indices, LeftArgType, RightArgT // First, we are interested in parallel packing if there are few tasks. bool parallel_pack = num_threads >= nm * nn; // Also do parallel packing if all data fits into L2$. - if (m * bk * sizeof(LhsScalar) + n * bk * sizeof(RhsScalar) <= + if (m * bk * Index(sizeof(LhsScalar)) + n * bk * Index(sizeof(RhsScalar)) <= l2CacheSize() * num_threads) parallel_pack = true; // But don't do it if we will use each rhs only once. Locality seems to be @@ -361,7 +361,7 @@ struct TensorEvaluator<const TensorContractionOp<Indices, LeftArgType, RightArgT packed_mem_ = static_cast<char*>(internal::aligned_malloc( (nm0_ * lhs_size + nn0_ * rhs_size) * std::min<size_t>(nk_, P - 1))); char* mem = static_cast<char*>(packed_mem_); - for (Index x = 0; x < numext::mini<size_t>(nk_, P - 1); x++) { + for (Index x = 0; x < numext::mini<Index>(nk_, P - 1); x++) { packed_lhs_[x].resize(nm0_); for (Index m = 0; m < nm0_; m++) { packed_lhs_[x][m] = reinterpret_cast<LhsScalar*>(mem); |