From: Martin Kronbichler Date: Tue, 11 Apr 2023 08:01:45 +0000 (+0200) Subject: Use proper MPI communicator X-Git-Tag: v9.5.0-rc1~342^2~1 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=588ab9ea3689da3124abe42acf49205ed365c3af;p=dealii.git Use proper MPI communicator --- diff --git a/include/deal.II/lac/solver_gmres.h b/include/deal.II/lac/solver_gmres.h index 54d2393af1..e2f219d81b 100644 --- a/include/deal.II/lac/solver_gmres.h +++ b/include/deal.II/lac/solver_gmres.h @@ -915,7 +915,7 @@ namespace internal block(vv, b).local_element(j); } - Utilities::MPI::sum(h, MPI_COMM_WORLD, h); + Utilities::MPI::sum(h, block(vv, 0).get_mpi_communicator(), h); } @@ -1025,7 +1025,8 @@ namespace internal } } - return std::sqrt(Utilities::MPI::sum(norm_vv_temp, MPI_COMM_WORLD)); + return std::sqrt( + Utilities::MPI::sum(norm_vv_temp, block(vv, 0).get_mpi_communicator())); } @@ -1067,7 +1068,8 @@ namespace internal norm += temp * temp; } - return std::sqrt(Utilities::MPI::sum(norm, MPI_COMM_WORLD)); + return std::sqrt( + Utilities::MPI::sum(norm, block(v, 0).get_mpi_communicator())); }