MCPcopy Create free account
hub / github.com/RenderKit/ospray / ~MPIOffloadDevice

Method ~MPIOffloadDevice

modules/mpi/ospray/MPIOffloadDevice.cpp:190–216  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

188///////////////////////////////////////////////////////////////////////////
189
190MPIOffloadDevice::~MPIOffloadDevice()
191{
192 try {
193 if (dynamic_cast<MPIFabric *>(fabric.get()) && world.rank == 0) {
194 postStatusMsg(OSP_LOG_INFO) << "shutting down mpi device";
195
196 sendWork(
197 [](networking::WriteStream &writer) { writer << work::FINALIZE; },
198 true);
199 fabric = nullptr;
200 maml::shutdown();
201
202 MPI_Finalize();
203
204 RKCOMMON_IF_TRACING_ENABLED({
205 char hostname[512] = {0};
206 gethostname(hostname, 511);
207 const std::string masterTraceFile =
208 std::string(hostname) + "_master.json";
209 rkcommon::tracing::saveLog(
210 masterTraceFile.c_str(), masterTraceFile.c_str());
211 });
212 }
213 } catch (const std::exception &e) {
214 handleError(OSP_UNKNOWN_ERROR, e.what());
215 }
216}
217
218void MPIOffloadDevice::initializeDevice()
219{

Callers

nothing calls this directly

Calls 3

postStatusMsgFunction · 0.85
handleErrorFunction · 0.85
shutdownFunction · 0.50

Tested by

no test coverage detected