diff --git a/applications/test/gatherValues1/Test-gatherValues1.C b/applications/test/gatherValues1/Test-gatherValues1.C index 7fdbf92bf3..773e1b9d25 100644 --- a/applications/test/gatherValues1/Test-gatherValues1.C +++ b/applications/test/gatherValues1/Test-gatherValues1.C @@ -68,6 +68,29 @@ int main(int argc, char *argv[]) } + // This now compiles (and works) + // - reverts to normal gather for non-contiguous + { + const wordList sendData({"hello", "world"}); + + // One-sided sizing! master only + const globalIndex allProcAddr + ( + sendData.size(), + globalIndex::gatherOnly{} + ); + + Pout<< "listGather sizes: " << flatOutput(allProcAddr.sizes()) << nl; + + // Collect all values + wordList allValues + ( + allProcAddr.mpiGather(sendData) + ); + + Pout<< "all-data: " << allValues << endl; + } + // Gather all values { const auto& sendData = localValues; @@ -75,8 +98,8 @@ int main(int argc, char *argv[]) // One-sided sizing! master only const globalIndex allProcAddr ( - UPstream::listGatherValues