mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: gatherScatter: switch off comms if not parRun
This commit is contained in:
@ -52,7 +52,7 @@ void Pstream::gather
|
||||
const label comm
|
||||
)
|
||||
{
|
||||
if (UPstream::nProcs(comm) > 1)
|
||||
if (UPstream::parRun() && UPstream::nProcs(comm) > 1)
|
||||
{
|
||||
// Get my communication order
|
||||
const commsStruct& myComm = comms[UPstream::myProcNo(comm)];
|
||||
@ -151,7 +151,7 @@ void Pstream::scatter
|
||||
const label comm
|
||||
)
|
||||
{
|
||||
if (UPstream::nProcs(comm) > 1)
|
||||
if (UPstream::parRun() && UPstream::nProcs(comm) > 1)
|
||||
{
|
||||
// Get my communication order
|
||||
const commsStruct& myComm = comms[UPstream::myProcNo(comm)];
|
||||
|
||||
Reference in New Issue
Block a user