| 40 | } |
| 41 | |
| 42 | void WriterModule::startup() { |
| 43 | logInfo(rank) << "Output Writer" << settings.name << ": startup, running at interval" |
| 44 | << settings.interval; |
| 45 | init(); |
| 46 | |
| 47 | // we want ASYNC to like us, hence we need to enter a non-zero size here |
| 48 | planId = addBuffer(nullptr, 1, true); |
| 49 | assert(planId == 0); |
| 50 | |
| 51 | callInit(AsyncWriterInit{}); |
| 52 | // TODO: pinning |
| 53 | |
| 54 | Modules::registerHook(*this, ModuleHook::SimulationStart); |
| 55 | Modules::registerHook(*this, ModuleHook::SynchronizationPoint); |
| 56 | Modules::registerHook(*this, ModuleHook::SimulationEnd); |
| 57 | Modules::registerHook(*this, ModuleHook::Shutdown); |
| 58 | setSyncInterval(settings.interval); |
| 59 | } |
| 60 | |
| 61 | void WriterModule::simulationStart() { syncPoint(0); } |
| 62 | |