40 <<
"Cannot gather values for non-contiguous types" <<
endl 58 reinterpret_cast<const char*>(&localValue),
69 allValues[0] = localValue;
86 <<
"Cannot scatter values for non-contiguous types" <<
endl 100 <<
"Attempting to send " << allValues.
size()
101 <<
" values to " << nproc <<
" processors" <<
endl 109 reinterpret_cast<char*>(&localValue),
118 if (allValues.
empty())
124 localValue = allValues[0];
void size(const label n)
Older name for setAddressableSize.
void resize(const label len)
Adjust allocated size of list.
error FatalError
Error stream (stdout output on all processes), with additional 'FOAM FATAL ERROR' header text and sta...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
bool empty() const noexcept
True if the UList is empty (ie, size() is zero)
static List< T > listGatherValues(const T &localValue, const label communicator=worldComm)
Gather individual values into list locations.
Ostream & endl(Ostream &os)
Add newline and flush stream.
static bool & parRun() noexcept
Test if this a parallel run.
char * data_bytes() noexcept
Return pointer to the underlying array serving as data storage,.
const char * cdata_bytes() const noexcept
Return pointer to the underlying array serving as data storage,.
static label nProcs(const label communicator=worldComm)
Number of ranks in parallel run (for given communicator) is 1 for serial run.
static void mpiGather(const char *sendData, int sendCount, char *recvData, int recvCount, const label communicator=worldComm)
Receive identically-sized char data from all ranks.
errorManip< error > abort(error &err)
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
static void mpiScatter(const char *sendData, int sendCount, char *recvData, int recvCount, const label communicator=worldComm)
Send identically-sized char data to all ranks.
A template class to specify that a data type can be considered as being contiguous in memory...
static bool master(const label communicator=worldComm)
Am I the master rank.
static T listScatterValues(const UList< T > &allValues, const label communicator=worldComm)
Scatter individual values from list locations.
static constexpr const zero Zero
Global zero (0)