mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: remove blocking communication for gather patterns
ENH: eliminate unnecessary duplicate communicator - in globalMeshData previously had a comm_dup hack to avoid clashes with deltaCoeffs calculations. However, this was largely due to a manual implementation of reduce() that used point-to-point communication. This has since been updated to use an MPI_Allreduce and now an MPI_Allgather, neither of which need this hack.
This commit is contained in:
@ -541,7 +541,7 @@ void syncPoints
|
||||
// Is there any coupled patch with transformation?
|
||||
bool hasTransformation = false;
|
||||
|
||||
if (Pstream::parRun())
|
||||
if (UPstream::parRun())
|
||||
{
|
||||
const labelList& procPatches = mesh.globalData().processorPatches();
|
||||
|
||||
@ -569,7 +569,12 @@ void syncPoints
|
||||
}
|
||||
|
||||
// buffered send
|
||||
OPstream::bsend(patchInfo, procPatch.neighbProcNo());
|
||||
OPstream toNbr
|
||||
(
|
||||
UPstream::commsTypes::blocking,
|
||||
procPatch.neighbProcNo()
|
||||
);
|
||||
toNbr << patchInfo;
|
||||
}
|
||||
}
|
||||
|
||||
@ -583,10 +588,10 @@ void syncPoints
|
||||
|
||||
if (pp.nPoints() && !procPatch.owner())
|
||||
{
|
||||
pointField nbrPatchInfo;
|
||||
|
||||
// We do not know the number of points on the other side
|
||||
// so cannot use UIPstream::read
|
||||
|
||||
pointField nbrPatchInfo;
|
||||
IPstream::recv(nbrPatchInfo, procPatch.neighbProcNo());
|
||||
|
||||
// Null any value which is not on neighbouring processor
|
||||
|
||||
Reference in New Issue
Block a user