Commit 4e4cb9fa authored by Deike Kleberg's avatar Deike Kleberg
Browse files

Remove old typedef pioInfo from pio.h, change interface of initPIOMODUS.

parent a6592784
......@@ -61,7 +61,6 @@ libcdi_la_SOURCES = \
pio_interface.c \
pio_interface.h \
pio_mpinonb.c \
pio_posixfpguardsendrecv.c \
pio_queue.c \
pio_rpc.c \
pio_rpc.h \
......
......@@ -82,10 +82,9 @@ am_libcdi_la_OBJECTS = basetime.lo binary.lo calendar.lo cdf.lo \
cgribexlib.lo dmemory.lo error.lo extralib.lo file.lo \
gaussgrid.lo gribapi.lo grid.lo ieglib.lo institution.lo \
model.lo namespace.lo pio.lo pio_comm.lo pio_dbuffer.lo \
pio_interface.lo pio_mpinonb.lo pio_posixfpguardsendrecv.lo \
pio_queue.lo pio_rpc.lo pio_server.lo pio_util.lo \
resource_handle.lo servicelib.lo stream_cdf.lo \
stream_cgribex.lo stream_ext.lo stream_grb.lo \
pio_interface.lo pio_mpinonb.lo pio_queue.lo pio_rpc.lo \
pio_server.lo pio_util.lo resource_handle.lo servicelib.lo \
stream_cdf.lo stream_cgribex.lo stream_ext.lo stream_grb.lo \
stream_gribapi.lo stream_history.lo stream_ieg.lo \
stream_int.lo stream_record.lo stream_srv.lo stream_var.lo \
table.lo taxis.lo timebase.lo tsteps.lo util.lo varscan.lo \
......@@ -331,7 +330,6 @@ libcdi_la_SOURCES = \
pio_interface.c \
pio_interface.h \
pio_mpinonb.c \
pio_posixfpguardsendrecv.c \
pio_queue.c \
pio_rpc.c \
pio_rpc.h \
......@@ -512,7 +510,6 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pio_dbuffer.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pio_interface.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pio_mpinonb.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pio_posixfpguardsendrecv.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pio_queue.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pio_rpc.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pio_server.Plo@am__quote@
......
......@@ -44,8 +44,6 @@ double accumSuspend = 0.0;
double accumWait = 0.0;
double accumWrite = 0.0;
pioInfo * pioinfo;
char *token = "%";
/***************************************************************/
......@@ -94,9 +92,11 @@ size_t pioFileWrite ( int fileID, int tsID, const void *buffer, size_t len )
break;
*/
#endif
/*
case PIO_POSIX_FPGUARD_SENDRECV:
iret = fwPOSIXFPGUARDSENDRECV ( fileID, tsID, buffer, len );
break;
*/
/*
case PIO_POSIX_FPGUARD_THREAD:
iret = fwPOSIXFPGUARDTHREAD ( fileID, tsID, buffer, len );
......@@ -134,9 +134,11 @@ int pioFileClose ( int id )
break;
*/
#endif
/*
case PIO_POSIX_FPGUARD_SENDRECV:
iret = fcPOSIXFPGUARDSENDRECV ( id );
break;
*/
/*
case PIO_POSIX_FPGUARD_THREAD:
iret = fcPOSIXFPGUARDTHREAD ( id );
......@@ -175,9 +177,11 @@ int pioFileOpenW ( const char *filename )
break;
*/
#endif
/*
case PIO_POSIX_FPGUARD_SENDRECV:
iret = fowPOSIXFPGUARDSENDRECV ( filename );
break;
*/
/*
case PIO_POSIX_FPGUARD_THREAD:
iret = fowPOSIXFPGUARDTHREAD ( filename );
......@@ -203,7 +207,6 @@ int pioFileOpenW ( const char *filename )
void backendInit ( void )
{
int collectingData = 1;
int IOModus = commInqIOModus ();
#ifdef USE_MPI
......@@ -215,14 +218,11 @@ void backendInit ( void )
switch ( IOModus )
{
/*
case PIO_NONE:
xmpi ( MPI_Comm_dup ( pioinfo->comm, &( pioinfo->collectorComm )));
collectingData = 1;
commDefCommColl ( 1 );
break;
*/
case PIO_MPI_NONB:
collectingData = initMPINONB ();
initMPINONB ();
break;
#ifndef _SX
/*
......@@ -253,39 +253,13 @@ void backendInit ( void )
*/
}
#endif
#ifdef USE_MPI
// TODO: change interface!
assert ( pioinfo2 != NULL && pioinfo2->commColl != MPI_COMM_NULL );
return pioinfo2->commColl;
#else
return 0;
#endif
}
/***************************************************************/
void backendFinalize ()
void backendFinalize ( void )
{
#ifdef USE_MPI
/*
switch ( pioinfo->type )
{
case PIO_POSIX_FPGUARD_THREAD:
finalizePOSIXFPGUARDTHREAD ();
break;
}
if ( pioinfo->collectorComm != MPI_COMM_NULL )
xmpi ( MPI_Comm_free ( &( pioinfo->collectorComm )));
if ( pioinfo->comm != MPI_COMM_NULL )
xmpi ( MPI_Comm_free ( &( pioinfo->comm )));
free ( pioinfo );
*/
#endif
}
/*
......
......@@ -9,21 +9,11 @@
#include <stdlib.h>
#include <mpi.h>
typedef struct{
int type;
MPI_Comm comm;
int color;
int size;
int rank;
int specialRank;
MPI_Comm collectorComm;
}pioInfo;
void backendInit ( void );
void backendFinalize ( void );
int pioFileOpenW ( const char* );
int pioFileClose ( int );
size_t pioFileWrite ( int, int, const void*, size_t );
int pioFileOpenW ( const char* );
int pioFileClose ( int );
size_t pioFileWrite ( int, int, const void*, size_t );
#else
typedef int MPI_Comm;
......
......@@ -76,7 +76,7 @@ int queueDelNode ( queue_t *, int );
int fowMPINONB ( const char * );
int fcMPINONB ( int );
size_t fwMPINONB( int, int, const void *, size_t );
int initMPINONB ( void );
void initMPINONB ( void );
/* pio_posixasynch.c */
#ifndef _SX
......
......@@ -26,9 +26,6 @@ extern double accumSend;
extern double accumSuspend;
extern double accumWait;
extern double accumWrite;
extern pioInfo *pioinfo;
typedef struct
{
char *name;
......@@ -369,10 +366,8 @@ int fowMPINONB ( const char *filename )
/***************************************************************/
int initMPINONB ()
void initMPINONB ( void )
{
int collectingData = 1;
commDefCommColl ( 1 );
commSendNodeInfo ();
commRecvNodeMap ();
......@@ -382,8 +377,6 @@ int initMPINONB ()
if ( bibAFiledataM == NULL )
xabort ( "queueInit did not succeed" );
return collectingData;
}
#endif
......
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