STYLE: use PstreamBuffers default construct

- PstreamBuffers are nonBlocking by default, so no need to re-specify
This commit is contained in:
Mark Olesen
2024-04-26 10:17:43 +02:00
parent 7f355ba343
commit 7b38b148fa
34 changed files with 48 additions and 68 deletions

View File

@ -227,7 +227,7 @@ reducedKoopmanOperator()
// the final outcome of TSQR decomposition up to sign
// Don't clear storage on persistent buffer
PstreamBuffers pBufs(Pstream::commsTypes::nonBlocking);
PstreamBuffers pBufs;
pBufs.allowClearRecv(false);
const label myProcNo = Pstream::myProcNo();

View File

@ -111,7 +111,7 @@ void Foam::functionObjects::externalCoupled::readColumns
// Get sizes for all processors
const globalIndex globalFaces(globalIndex::gatherOnly{}, nRows);
PstreamBuffers pBufs(UPstream::commsTypes::nonBlocking);
PstreamBuffers pBufs;
if (UPstream::master())
{
@ -182,7 +182,7 @@ void Foam::functionObjects::externalCoupled::readLines
// Get sizes for all processors
const globalIndex globalFaces(globalIndex::gatherOnly{}, nRows);
PstreamBuffers pBufs(UPstream::commsTypes::nonBlocking);
PstreamBuffers pBufs;
if (UPstream::master())
{

View File

@ -215,7 +215,7 @@ bool Foam::functionObjects::energySpectrum::write()
if (Pstream::parRun())
{
PstreamBuffers pBufs(Pstream::commsTypes::nonBlocking);
PstreamBuffers pBufs;
{
UOPstream toMaster(Pstream::masterNo(), pBufs);

View File

@ -87,11 +87,7 @@ void Foam::functionObjects::syncObjects::sync()
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Note provision of explicit all-world communicator
PstreamBuffers pBufs
(
UPstream::commGlobal(),
UPstream::commsTypes::nonBlocking
);
PstreamBuffers pBufs(UPstream::commGlobal());
for (const int proci : pBufs.allProcs())