From effe84e7038577ab58a3df9f5b260058aa67b099 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Tue, 27 Feb 2024 08:45:04 -0800 Subject: [PATCH] fix --- src/support/threads.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/support/threads.cpp b/src/support/threads.cpp index 58aa05be481..7388986389a 100644 --- a/src/support/threads.cpp +++ b/src/support/threads.cpp @@ -143,13 +143,13 @@ size_t ThreadPool::getNumCores() { // In an Emscripten build without pthreads support, avoid the overhead of // including support code for the below runtime checks. return 1; -#endif - +#else size_t num = std::max(1U, std::thread::hardware_concurrency()); if (getenv("BINARYEN_CORES")) { num = std::stoi(getenv("BINARYEN_CORES")); } return num; +#endif } ThreadPool* ThreadPool::get() {