79 if (commAndIORanks.
second().empty())
95 return commAndIORanks;
103void Foam::fileOperations::hostUncollatedFileOperation::init(
bool verbose)
110 <<
"I/O : " << this->
type() <<
nl;
125 masterUncollatedFileOperation
140 const bool distributedRoots,
Macros for easy insertion into run-time selection tables.
#define addNamedToRunTimeSelectionTable(baseType, thisType, argNames, lookupName)
Add to construction table with 'lookupName' as the key.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
A 2-tuple for storing two objects of dissimilar types. The container is similar in purpose to std::pa...
const T1 & first() const noexcept
Access the first element.
const T2 & second() const noexcept
Access the second element.
void size(const label n)
Older name for setAddressableSize.
static bool parRun(const bool on) noexcept
Set as parallel run on/off.
static label worldComm
Communicator for all ranks. May differ from commGlobal() if local worlds are in use.
static label newCommunicator(const label parent, const labelRange &subRanks, const bool withComponents=true)
Create new communicator with sub-ranks on the parent communicator.
static void freeCommunicator(const label communicator, const bool withComponents=true)
Free a previously allocated communicator.
An encapsulation of filesystem-related operations.
static labelRange subRanks(const labelUList &mainIOranks)
Get (contiguous) range/bounds of ranks addressed within the given main io-ranks.
static label getManagedComm(const label communicator)
Construction helper: check for locally allocated communicator.
const labelList ioRanks_
The list of IO ranks (global ranks).
label comm_
Communicator to use.
static labelList getGlobalIORanks()
Get list of global IO ranks from FOAM_IORANKS env variable. If set, these correspond to the IO master...
void printRanks() const
Helper: output which ranks are IO.
static labelList getGlobalHostIORanks()
Get list of global IO master ranks based on the hostname. It is assumed that each host range is conti...
A fileOperation initialiser for unthreaded file handlers.
Version of masterUncollated with host-based IO ranks.
virtual void storeComm() const
Transfer ownership of communicator to this fileOperation. Use with caution.
virtual ~hostUncollatedFileOperation()
Destructor.
hostUncollatedFileOperation(bool verbose=false)
Default construct.
fileOperations that performs all file operations on the master processor. Requires the calls to be pa...
masterUncollatedFileOperation(bool verbose=false)
Default construct.
virtual fileName::Type type(const fileName &, const bool followLink=true) const
Return the file type: DIRECTORY, FILE or SYMLINK.
A class for handling words, derived from Foam::string.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
Namespace for implementations of a fileOperation.
int infoDetailLevel
Global for selective suppression of Info output.
static Tuple2< label, labelList > getCommPattern()
Ostream & flush(Ostream &os)
Flush stream.
constexpr char nl
The newline '\n' character (0x0a).