perf(solvers): scope default one-equation calls to one thread
This commit is contained in:
@@ -13,6 +13,7 @@
|
||||
|
||||
#include "fesa/math/sparse_matrix.h"
|
||||
#include "fesa/math/vector.h"
|
||||
#include "math/dense_blas_internal.h"
|
||||
|
||||
namespace fesa {
|
||||
namespace {
|
||||
@@ -230,6 +231,8 @@ class MklPardisoTangentSolver::Impl {
|
||||
/// @brief Calls PARDISO with retained private arrays and phase state.
|
||||
void CallPardiso(const MKL_INT phase, double* rhs, double* correction,
|
||||
MKL_INT& error) {
|
||||
const dense_blas_internal::ScopedSingleEquationThreads thread_scope{
|
||||
static_cast<std::size_t>(equation_count_)};
|
||||
pardiso(pt_.data(), &max_factorizations_, &matrix_number_, &mtype_, &phase,
|
||||
&equation_count_, values_.data(), row_offsets_.data(),
|
||||
column_indices_.data(), permutation_.data(), &rhs_count_,
|
||||
|
||||
Reference in New Issue
Block a user