| 12 | Module::~Module() = default; |
| 13 | |
| 14 | double Module::potentialSyncPoint(double currentTime, double timeTolerance, bool forceSyncPoint) { |
| 15 | if (std::abs(currentTime - lastSyncPoint) < timeTolerance) { |
| 16 | const int rank = seissol::MPI::mpi.rank(); |
| 17 | logInfo(rank) << "Ignoring duplicate synchronization point at time" << currentTime |
| 18 | << "; the last sync point was at " << lastSyncPoint; |
| 19 | } else if (forceSyncPoint || std::abs(currentTime - nextSyncPoint) < timeTolerance) { |
| 20 | syncPoint(currentTime); |
| 21 | lastSyncPoint = currentTime; |
| 22 | nextSyncPoint += isyncInterval; |
| 23 | } |
| 24 | |
| 25 | return nextSyncPoint; |
| 26 | } |
| 27 | |
| 28 | void Module::setSimulationStartTime(double time) { |
| 29 | assert(isyncInterval > 0); |