Commit c7ce4b7c authored by Deike Kleberg's avatar Deike Kleberg
Browse files

interim 10

parent 53449397
......@@ -201,19 +201,15 @@ int pioFileOpenW ( const char *filename )
/***************************************************************/
MPI_Comm backendInit ( int ptype, MPI_Comm comm, int *color, int *nnodes )
MPI_Comm backendInit ( void )
{
int size, rank;
int collectingData = 1;
int IOModus = commInqIOModus ();
#ifdef USE_MPI
xmpi ( MPI_Comm_size ( comm, &size ));
xmpi ( MPI_Comm_rank ( comm, &rank ));
commDefCommNode ();
if (( IOModus == PIO_NONE ) && ( commInqNNodes () != size ))
if (( IOModus == PIO_NONE ) && ( commInqSizeNode () != 1 ))
xabort ( "PIOTYPE, NNODES: not a valid combination" );
......
......@@ -19,7 +19,7 @@ typedef struct{
MPI_Comm collectorComm;
}pioInfo;
MPI_Comm backendInit ( int, MPI_Comm, int *, int * );
MPI_Comm backendInit ( void );
void backendFinalize ( void );
int pioFileOpenW ( const char* );
int pioFileClose ( int );
......
......@@ -325,6 +325,14 @@ MPI_Comm commInqCommNode ( void )
}
int commInqSizeNode ( void )
{
assert ( pioinfo2 != NULL &&
pioinfo2->sizeNode != CDI_UNDEFID );
return pioinfo2->sizeNode;
}
int commInqRankNode ( void )
{
assert ( pioinfo2 != NULL &&
......
......@@ -65,33 +65,40 @@ enum { sizeNodeInfo = 3,
void commInit ( void );
void commDestroy ( void );
void commDefCommGlob ( MPI_Comm );
MPI_Comm commInqCommGlob ( void );
int commInqSizeGlob ( void );
int commInqRankGlob ( void );
void commDefNProcsIO ( int );
int commInqNProcsIO ( void );
int commInqNProcsModel ( void );
void commDefIOModus ( int );
int commInqIOModus ( void );
void commDefCommPio ( void );
MPI_Comm commInqCommPio ( void );
MPI_Comm commInqCommModel ( void );
int commInqIsProcIO ( void );
void commDefCommNode ( void );
MPI_Comm commInqCommNode ( void );
int commInqSizeNode ( void );
int commInqRankNode ( void );
void commSendNodeInfo ( void );
void commRecvNodeMap ( void );// todo switch to gatherNodeInfo inside commpio
int * commInqNodeSizes ( void );
int commInqNNodes ( void );
void commDefCommColl ( int );
void commEvalPhysNodes ( void );
void commDefCommsIO ( void );
MPI_Comm commInqCommsIO ( int );
MPI_Comm commInqCommCalc ( void );
void commPrint ( FILE * );
void commSendNodeInfo ( void );
void commRecvNodeMap ( void );// todo switch to gatherNodeInfo inside commpio
int * commInqNodeSizes ( void );
......
......@@ -255,7 +255,7 @@ void IOServer ()
int nProcsCalc = commInqNProcsModel ();
nfinished = 0;
commColl = backendInit ( ptype, comm, &color, &nnodes );
commColl = backendInit ();
commCalc = commInqCommCalc ();
for ( ;; )
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment