mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
CONFIG: add named topoControls
This commit is contained in:
@ -147,6 +147,15 @@ OptimisationSwitches
|
|||||||
// >= 3 : when there are more than N nodes
|
// >= 3 : when there are more than N nodes
|
||||||
nodeComms.min 0;
|
nodeComms.min 0;
|
||||||
|
|
||||||
|
// Selection of topology-aware routines (bitmask)
|
||||||
|
// 0: disabled [default]
|
||||||
|
// 1: broadcast [MPI]
|
||||||
|
// 4: gather/all-gather [MPI]
|
||||||
|
// 16: combine (reduction) [manual algorithm]
|
||||||
|
// 32: mapGather (reduction) [manual algorithm]
|
||||||
|
// 64: gatherList/scatterList [manual algorithm]
|
||||||
|
topoControl 0;
|
||||||
|
|
||||||
// Transfer double as float for processor boundaries. Mostly defunct.
|
// Transfer double as float for processor boundaries. Mostly defunct.
|
||||||
floatTransfer 0;
|
floatTransfer 0;
|
||||||
|
|
||||||
|
|||||||
@ -106,7 +106,35 @@ void Foam::UPstream::printNodeCommsControl(Ostream& os)
|
|||||||
|
|
||||||
void Foam::UPstream::printTopoControl(Ostream& os)
|
void Foam::UPstream::printTopoControl(Ostream& os)
|
||||||
{
|
{
|
||||||
os << "none";
|
unsigned count = 0;
|
||||||
|
|
||||||
|
if (UPstream::topologyControl_ > 0)
|
||||||
|
{
|
||||||
|
#undef PrintControl
|
||||||
|
#define PrintControl(Ctrl, Name) \
|
||||||
|
if (UPstream::usingTopoControl(topoControls::Ctrl)) \
|
||||||
|
{ \
|
||||||
|
os << (count++ ? ' ' : '(') << Name; \
|
||||||
|
}
|
||||||
|
|
||||||
|
PrintControl(broadcast, "broadcast");
|
||||||
|
PrintControl(reduce, "reduce");
|
||||||
|
PrintControl(gather, "gather");
|
||||||
|
PrintControl(combine, "combine");
|
||||||
|
PrintControl(mapGather, "mapGather");
|
||||||
|
PrintControl(gatherList, "gatherList");
|
||||||
|
|
||||||
|
#undef PrintControl
|
||||||
|
}
|
||||||
|
|
||||||
|
if (count)
|
||||||
|
{
|
||||||
|
os << ')'; // End the list
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
os << "none";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user