summaryrefslogtreecommitdiffstats
path: root/testpar/testphdf5.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2002-07-15 15:21:44 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2002-07-15 15:21:44 (GMT)
commitb1aa07bd2a033591cdd9afae6c1274a83b308f1e (patch)
treeedfeceef8778bf203b036cc8cc61bed774d5db06 /testpar/testphdf5.c
parent363ec52b7cab5638e3d1479b67068754a2e10011 (diff)
downloadhdf5-b1aa07bd2a033591cdd9afae6c1274a83b308f1e.zip
hdf5-b1aa07bd2a033591cdd9afae6c1274a83b308f1e.tar.gz
hdf5-b1aa07bd2a033591cdd9afae6c1274a83b308f1e.tar.bz2
[svn-r5800] Purpose:
New feature. Description: Added MPI-posix VFL driver support. Platforms tested: FreeBSD 4.6 (sleipnir) w/parallel & IRIX64 6.5 (modi4) w/parallel
Diffstat (limited to 'testpar/testphdf5.c')
-rw-r--r--testpar/testphdf5.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/testpar/testphdf5.c b/testpar/testphdf5.c
index e193177..b650e00 100644
--- a/testpar/testphdf5.c
+++ b/testpar/testphdf5.c
@@ -107,6 +107,7 @@ usage(void)
printf("\t-v\t\tverbose on\n");
printf("\t-f <prefix>\tfilename prefix\n");
printf("\t-s\t\tuse Split-file together with MPIO\n");
+ printf("\t-p\t\tuse combo MPI-POSIX driver\n");
printf("\t-d <dim0> <dim1>\tdataset dimensions\n");
printf("\t-c <dim0> <dim1>\tdataset chunk dimensions\n");
printf("\tDefault: do write then read with dimensions %dx%d\n",
@@ -163,6 +164,9 @@ parse_options(int argc, char **argv)
}
paraprefix = *argv;
break;
+ case 'p': /* Use the MPI-POSIX driver access */
+ facc_type = FACC_MPIPOSIX;
+ break;
case 's': /* Use the split-file driver with MPIO access */
/* Can use $HDF5_METAPREFIX to define the */
/* meta-file-prefix. */
@@ -285,6 +289,13 @@ create_faccess_plist(MPI_Comm comm, MPI_Info info, int l_facc_type )
return(ret_pl);
}
+ if (l_facc_type == FACC_MPIPOSIX) {
+ /* set Parallel access with communicator */
+ ret = H5Pset_fapl_mpiposix(ret_pl, comm);
+ VRFY((ret >= 0), "");
+ return(ret_pl);
+ }
+
/* unknown file access types */
return (ret_pl);
}
@@ -294,6 +305,10 @@ int main(int argc, char **argv)
{
int mpi_size, mpi_rank; /* mpi variables */
+ /* Un-buffer the stdout and stderr */
+ setbuf(stderr, NULL);
+ setbuf(stdout, NULL);
+
MPI_Init(&argc, &argv);
MPI_Comm_size(MPI_COMM_WORLD, &mpi_size);
MPI_Comm_rank(MPI_COMM_WORLD, &mpi_rank);