12 #include "ncdispatch.h"
16 nc_create_par(
const char *path,
int cmode, MPI_Comm comm,
17 MPI_Info info,
int *ncidp)
32 return NC_create(path, cmode, 0, 0, NULL, 1, &data, ncidp);
38 nc_open_par(
const char *path,
int mode, MPI_Comm comm,
39 MPI_Info info,
int *ncidp)
48 if ((mode &
NC_MPIIO) || (mode & NC_MPIPOSIX)) {
58 return NC_open(path, mode, 0, NULL, 1, &mpi_data, ncidp);
64 nc_open_par_fortran(
const char *path,
int mode,
int comm,
75 #ifdef HAVE_MPI_COMM_F2C
76 comm_c = MPI_Comm_f2c(comm);
77 info_c = MPI_Info_f2c(info);
79 comm_c = (MPI_Comm)comm;
80 info_c = (MPI_Info)info;
83 return nc_open_par(path, mode, comm_c, info_c, ncidp);
90 nc_var_par_access(
int ncid,
int varid,
int par_access)
96 if ((stat = NC_check_id(ncid, &ncp)))
102 return ncp->dispatch->var_par_access(ncid,varid,par_access);
108 nc_create_par_fortran(
const char *path,
int cmode,
int comm,
109 int info,
int *ncidp)
119 #ifdef HAVE_MPI_COMM_F2C
120 comm_c = MPI_Comm_f2c(comm);
121 info_c = MPI_Info_f2c(info);
123 comm_c = (MPI_Comm)comm;
124 info_c = (MPI_Info)info;
127 return nc_create_par(path, cmode, comm_c, info_c, ncidp);
#define NC_PNETCDF
Use parallel-netcdf library.
#define NC_MPIIO
Turn on MPI I/O.
#define NC_EINVAL
Invalid Argument.
#define NC_ENOPAR
Parallel operation on file opened for non-parallel access.
#define NC_NOERR
No Error.
#define NC_MPIPOSIX
Turn on MPI POSIX I/O.