Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libcdi
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mpim-sw
libcdi
Commits
f7848266
Commit
f7848266
authored
9 years ago
by
Thomas Jahns
Browse files
Options
Downloads
Patches
Plain Diff
Move simplified function to setup file-writing backends to pio_interface.c.
parent
f1709959
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/pio.c
+0
-51
0 additions, 51 deletions
src/pio.c
src/pio.h
+0
-1
0 additions, 1 deletion
src/pio.h
src/pio_interface.c
+36
-0
36 additions, 0 deletions
src/pio_interface.c
with
36 additions
and
52 deletions
src/pio.c
+
0
−
51
View file @
f7848266
...
...
@@ -2,22 +2,10 @@
#include
"config.h"
#endif
#include
<ctype.h>
#include
<yaxt.h>
#include
"file.h"
#include
"cdi_int.h"
#include
"namespace.h"
#include
"pio.h"
#include
"cdi.h"
#include
"cdipio.h"
#include
"pio_comm.h"
#include
"pio_impl.h"
#include
"pio_interface.h"
#include
"pio_rpc.h"
#include
"pio_util.h"
const
char
*
const
cdiPioCmdStrTab
[]
=
{
"IO_Open_file"
,
...
...
@@ -28,45 +16,6 @@ const char *const cdiPioCmdStrTab[] = {
"IO_Finalize"
};
/***************************************************************/
void
cdiPioFileWritingInit
(
void
)
{
int
IOMode
=
commInqIOMode
();
xassert
(
IOMode
!=
PIO_NONE
||
commInqSizeGlob
()
==
1
);
switch
(
IOMode
)
{
case
PIO_NONE
:
break
;
case
PIO_MPI
:
initMPINONB
();
break
;
#ifndef _SX
case
PIO_ASYNCH
:
#endif
case
PIO_WRITER
:
pioSendInitialize
();
break
;
case
PIO_FPGUARD
:
initPOSIXFPGUARDSENDRECV
();
break
;
}
}
/***************************************************************/
static
void
cdiPioFileWritingFinalizeDefault
(
void
)
{
xabort
(
"error: failed to setup file writing finalization function!"
);
}
void
(
*
cdiPioFileWritingFinalize
)(
void
)
=
cdiPioFileWritingFinalizeDefault
;
/***************************************************************/
/*
* Local Variables:
* c-file-style: "Java"
...
...
This diff is collapsed.
Click to expand it.
src/pio.h
+
0
−
1
View file @
f7848266
...
...
@@ -9,7 +9,6 @@
#include
<mpi.h>
void
cdiPioFileWritingInit
(
void
);
extern
void
(
*
cdiPioFileWritingFinalize
)(
void
);
#endif
...
...
This diff is collapsed.
Click to expand it.
src/pio_interface.c
+
36
−
0
View file @
f7848266
...
...
@@ -19,6 +19,7 @@
#include
"pio.h"
#include
"pio_client.h"
#include
"pio_id_set.h"
#include
"pio_impl.h"
#include
"pio_serialize.h"
#include
"pio_interface.h"
#include
"pio_comm.h"
...
...
@@ -473,6 +474,8 @@ pioInit(MPI_Comm commGlob, int nProcsIO, int IOMode,
pioNamespace
,
partInflate
,
postCommSetupActions
);
}
static
void
cdiPioFileWritingInit
(
void
);
MPI_Comm
cdiPioInit
(
MPI_Comm
commGlob
,
int
IOMode
,
int
clientServerRole
,
int
*
pioNamespace
,
float
partInflate
,
...
...
@@ -534,6 +537,39 @@ cdiPioInit(MPI_Comm commGlob, int IOMode, int clientServerRole,
return
commInqCommModel
();
}
static
void
cdiPioFileWritingInit
(
void
)
{
int
IOMode
=
commInqIOMode
();
xassert
(
IOMode
!=
PIO_NONE
||
commInqSizeGlob
()
==
1
);
switch
(
IOMode
)
{
case
PIO_NONE
:
break
;
case
PIO_MPI
:
initMPINONB
();
break
;
#ifndef _SX
case
PIO_ASYNCH
:
#endif
case
PIO_WRITER
:
pioSendInitialize
();
break
;
case
PIO_FPGUARD
:
initPOSIXFPGUARDSENDRECV
();
break
;
}
}
static
void
cdiPioFileWritingFinalizeDefault
(
void
)
{
xabort
(
"error: failed to setup file writing finalization function!"
);
}
void
(
*
cdiPioFileWritingFinalize
)(
void
)
=
cdiPioFileWritingFinalizeDefault
;
/*****************************************************************************/
void
pioEndDef
(
void
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment