From 00de570793b8acdc072c16d533f1740e3e061d94 Mon Sep 17 00:00:00 2001 From: Janek Kozicki Date: Mon, 23 Dec 2019 23:52:44 +0100 Subject: [PATCH] Fix -Werror -Wfloat-conversion warning. --- Eigen/src/Core/products/Parallelizer.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Eigen/src/Core/products/Parallelizer.h b/Eigen/src/Core/products/Parallelizer.h index e01e798f1..3bdd30e5a 100644 --- a/Eigen/src/Core/products/Parallelizer.h +++ b/Eigen/src/Core/products/Parallelizer.h @@ -129,7 +129,7 @@ void parallelize_gemm(const Functor& func, Index rows, Index cols, Index depth, double work = static_cast(rows) * static_cast(cols) * static_cast(depth); double kMinTaskSize = 50000; // FIXME improve this heuristic. - pb_max_threads = std::max(1, std::min(pb_max_threads, work / kMinTaskSize)); + pb_max_threads = std::max(1, std::min(pb_max_threads, static_cast( work / kMinTaskSize ) )); // compute the number of threads we are going to use Index threads = std::min(nbThreads(), pb_max_threads);