Reverting debug change: file based communication replaced by Pstream.

This commit is contained in:
Hrvoje Jasak 2019-05-08 11:48:51 +01:00
parent 7ef4377a9c
commit 8a64613197

View file

@ -35,9 +35,6 @@ License
#include "cloudDistribute.H" #include "cloudDistribute.H"
#include "meshObjectBase.H" #include "meshObjectBase.H"
#include "IFstream.H"
#include "OFstream.H"
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
bool Foam::topoChangerFvMesh::loadBalance(const dictionary& decompDict) bool Foam::topoChangerFvMesh::loadBalance(const dictionary& decompDict)
@ -309,16 +306,11 @@ bool Foam::topoChangerFvMesh::loadBalance(const dictionary& decompDict)
{ {
Pout<< "Send mesh and fields to processor " << procI << endl; Pout<< "Send mesh and fields to processor " << procI << endl;
OFstream toProc OPstream toProc
( (
"from" + Foam::name(Pstream::myProcNo()) Pstream::blocking,
+ "To" + Foam::name(procI) procI
); );
// OPstream toProc
// (
// Pstream::blocking,
// procI
// );
// Send the mesh and fields to target processor // Send the mesh and fields to target processor
toProc << procMesh << nl; toProc << procMesh << nl;
@ -470,16 +462,11 @@ bool Foam::topoChangerFvMesh::loadBalance(const dictionary& decompDict)
Pout<< "Receive mesh and fields from " << procI << endl; Pout<< "Receive mesh and fields from " << procI << endl;
// Note: communication can be optimised. HJ, 27/Feb/2018 // Note: communication can be optimised. HJ, 27/Feb/2018
IFstream fromProc IPstream fromProc
( (
"from" + Foam::name(procI) Pstream::blocking,
+ "To" + Foam::name(Pstream::myProcNo()) procI
); );
// IPstream fromProc
// (
// Pstream::blocking,
// procI
// );
// Receive the mesh // Receive the mesh
procMeshes.set procMeshes.set