Merge pull request #6801 from akva2/fix_thread_printout_separate_simulator

fixed: move getNumThreads into TU
This commit is contained in:
Arne Morten Kvarving authored and GitHub committed 2026-02-03 13:38:45 +01:00
commit 488326fe94
2 files changed
+14 -8

No files matched your search

+13
View File
@@ -44,6 +44,10 @@
#include <amgx_c.h>
#endif
#if HAVE_OPENMP
#include <omp.h>
#endif
#include <iostream>
// NOTE: There is no C++ header replacement for these C posix headers (as of C++17)
#include <fcntl.h> // for open()
@@ -381,4 +385,13 @@ void Main::setupDamaris(const std::string& outputDir )
}
#endif
int Main::getNumThreads()
{
#ifdef _OPENMP
return omp_get_max_threads();
#else
return 1;
#endif
}
} // namespace Opm
+1 -8
View File
@@ -520,14 +520,7 @@ private:
std::string_view moduleVersion,
std::string_view compileTimestamp);
static int getNumThreads()
{
#ifdef _OPENMP
return omp_get_max_threads();
#else
return 1;
#endif
}
static int getNumThreads();
#if HAVE_DAMARIS
void setupDamaris(const std::string& outputDir);