diff options
author | Erik Schnetter <schnetter@cct.lsu.edu> | 2011-11-29 19:02:14 -0500 |
---|---|---|
committer | Barry Wardell <barry.wardell@gmail.com> | 2011-12-14 19:55:02 +0000 |
commit | e5a4072babaaeaccfd96d9857d433deaa417503f (patch) | |
tree | 5cbf71b49cf3c993153a5c81b7046cf3c4813461 /Carpet/CarpetInterp | |
parent | 01b7b58d2ba75324fadebba2cdd41b0c8ff77227 (diff) |
Improve named barriers
Introduce dist::barrier as low-level implementation of a named
barrier.
Use it in Carpet::NamedBarrier.
Use the above in almost all barrier calls.
Diffstat (limited to 'Carpet/CarpetInterp')
-rw-r--r-- | Carpet/CarpetInterp/src/interp.cc | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/Carpet/CarpetInterp/src/interp.cc b/Carpet/CarpetInterp/src/interp.cc index b1cc62348..2a7a62fdb 100644 --- a/Carpet/CarpetInterp/src/interp.cc +++ b/Carpet/CarpetInterp/src/interp.cc @@ -329,15 +329,9 @@ namespace CarpetInterp { if (barriers) { - static unsigned int magic = 0x2ad072fbUL; // a random starting value - unsigned int recv = magic; - MPI_Bcast (& recv, 1, MPI_UNSIGNED, 0, dist::comm()); - if (recv != magic) { - CCTK_WARN (CCTK_WARN_ABORT, - "Inconsistent communication schedule: not all processes call CarpetInterp"); - } - ++ magic; - MPI_Barrier (dist::comm()); + Carpet::NamedBarrier (cctkGH, + 696681976, + "CarpetInterp::Carpet_DriverInterpolate"); } ////////////////////////////////////////////////////////////////////// |