Skip to content
Snippets Groups Projects
Commit ad39cda3 authored by Timo Koch's avatar Timo Koch Committed by Kilian Weishaupt
Browse files

[istlfactory] Only construct parallel helper if MPI is found

parent d8b42a02
No related branches found
No related tags found
1 merge request!1931[linearsolver] Only construct parallel helper if MPI was found
......@@ -85,8 +85,10 @@ public:
const typename LinearSolverTraits::DofMapper& dofMapper,
const std::string& paramGroup = "")
: paramGroup_(paramGroup)
#if HAVE_MPI
, parallelHelper_(std::make_unique<ParallelISTLHelper<LinearSolverTraits>>(gridView, dofMapper))
, isParallel_(Dune::MPIHelper::getCollectiveCommunication().size() > 1)
#endif
{
reset();
}
......@@ -227,8 +229,10 @@ private:
}
const std::string paramGroup_;
#if HAVE_MPI
std::unique_ptr<ParallelISTLHelper<LinearSolverTraits>> parallelHelper_;
bool isParallel_;
#endif
bool isParallel_ = false;
bool firstCall_;
Dune::InverseOperatorResult result_;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment