]> https://gitweb.dealii.org/ - dealii.git/commitdiff
use new broadcast function 13379/head
authorTimo Heister <timo.heister@gmail.com>
Mon, 14 Feb 2022 13:18:09 +0000 (08:18 -0500)
committerTimo Heister <timo.heister@gmail.com>
Wed, 16 Feb 2022 01:14:41 +0000 (20:14 -0500)
include/deal.II/base/mpi.h

index c3459641a2b8315c246818235065d15df6aed546..763c5147f27870f9935eff4e4d0993e98a62b3db 100644 (file)
@@ -1862,11 +1862,8 @@ namespace Utilities
         }
 
       // Exchange the size of buffer
-      int ierr = MPI_Bcast(&buffer_size,
-                           1,
-                           internal::mpi_type_id(&buffer_size),
-                           root_process,
-                           comm);
+      int ierr = MPI_Bcast(
+        &buffer_size, 1, mpi_type_id(&buffer_size), root_process, comm);
       AssertThrowMPI(ierr);
 
       // If not on the root process, correctly size the buffer to
@@ -1874,9 +1871,7 @@ namespace Utilities
       if (this_mpi_process(comm) != root_process)
         buffer.resize(buffer_size);
 
-      ierr =
-        MPI_Bcast(buffer.data(), buffer_size, MPI_CHAR, root_process, comm);
-      AssertThrowMPI(ierr);
+      broadcast(buffer.data(), buffer_size, root_process, comm);
 
       if (Utilities::MPI::this_mpi_process(comm) == root_process)
         return object_to_send;

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.