MCPcopy Create free account
hub / github.com/Kitware/VTK / IsFirstReaderRank

Method IsFirstReaderRank

IO/ParallelNetCDF/vtkPNetCDFPOPReader.cxx:710–719  ·  view source on GitHub ↗

------------------------------------------------------------------------------ Similar to above, but returns true only if the calling process is the first rank in the readerRanks vector. (This function exists because much of the file metadata is read by a single rank and broadcast to all the others.)

Source from the content-addressed store, hash-verified

708// rank in the readerRanks vector. (This function exists because much of the
709// file metadata is read by a single rank and broadcast to all the others.)
710bool vtkPNetCDFPOPReader::IsFirstReaderRank()
711{
712 if (this->Internals->ReaderRanks.empty())
713 {
714 return false; // sanity check
715 }
716
717 int rank = this->Controller->GetLocalProcessId();
718 return (rank == this->Internals->ReaderRanks[0]);
719}
720//------------------------------------------------------------------------------
721//
722void vtkPNetCDFPOPReader::SetController(vtkMPIController* controller)

Callers 2

RequestInformationMethod · 0.95
RequestDataMethod · 0.95

Calls 2

emptyMethod · 0.45
GetLocalProcessIdMethod · 0.45

Tested by

no test coverage detected