@@ -167,7 +167,7 @@ ncmpio_create(MPI_Comm comm,
167167
168168 /* Extract hints from user_info. Two hints must be extracted now in order
169169 * to continue:
170- * pnc_driver: whether to user MPI-IO or PnetCDF's PNCIO driver.
170+ * pnc_driver: whether to use MPI-IO or PnetCDF's PNCIO driver.
171171 * nc_num_aggrs_per_node: number of processes per node to be the INA
172172 * aggregators.
173173 *
@@ -274,7 +274,7 @@ if (rank == 0) printf("%s at %d fstype=%s\n", __func__,__LINE__,(ncp->fstype ==
274274#ifdef HAVE_UNLINK
275275 /* unlink() is likely faster then truncate(). However, unlink()
276276 * can be expensive when the file size is large. For example,
277- * it taook 1.1061 seconds to delete a file of size 27.72 GiB
277+ * it took 1.1061 seconds to delete a file of size 27.72 GiB
278278 * on Perlmutter at NERSC.
279279 */
280280 err = unlink (filename );
@@ -288,7 +288,12 @@ if (rank == 0) printf("%s at %d fstype=%s\n", __func__,__LINE__,(ncp->fstype ==
288288 if (ncp -> fstype != PNCIO_FSTYPE_MPIIO )
289289 err = PNCIO_File_delete (filename );
290290 else {
291+ #ifdef MPICH_VERSION
292+ /* MPICH recognizes file system type acronym prefixed to the file name */
291293 TRACE_IO (MPI_File_delete , (path , MPI_INFO_NULL ));
294+ #else
295+ TRACE_IO (MPI_File_delete , (filename , MPI_INFO_NULL ));
296+ #endif
292297 if (mpireturn != MPI_SUCCESS ) {
293298 int errorclass ;
294299 MPI_Error_class (mpireturn , & errorclass );
@@ -342,7 +347,12 @@ if (rank == 0) printf("%s at %d fstype=%s\n", __func__,__LINE__,(ncp->fstype ==
342347 NCI_Free (pncio_fh );
343348 }
344349 else {
350+ #ifdef MPICH_VERSION
351+ /* MPICH recognizes file system type acronym prefixed to the file name */
345352 TRACE_IO (MPI_File_open , (MPI_COMM_SELF , path , MPI_MODE_RDWR , MPI_INFO_NULL , & fh ));
353+ #else
354+ TRACE_IO (MPI_File_open , (MPI_COMM_SELF , filename , MPI_MODE_RDWR , MPI_INFO_NULL , & fh ));
355+ #endif
346356 if (mpireturn != MPI_SUCCESS ) {
347357 int errorclass ;
348358 MPI_Error_class (mpireturn , & errorclass );
@@ -537,8 +547,8 @@ if (rank == 0) printf("%s at %d fstype=%s\n", __func__,__LINE__,(ncp->fstype ==
537547 if (ncp -> rank == 0 &&
538548 striping_factor * striping_unit == 0 &&
539549 striping_factor + striping_unit > 0 ) {
540- /* rank 0 retreives folder's striping settings */
541- lustre_get_striping (path , & striping_factor , & striping_unit );
550+ /* rank 0 retrieves folder's striping settings */
551+ lustre_get_striping (filename , & striping_factor , & striping_unit );
542552 /* error is ignored, if there is any */
543553 stripings [0 ] = striping_factor ;
544554 stripings [1 ] = striping_unit ;
@@ -558,7 +568,12 @@ if (rank == 0) printf("%s at %d fstype=%s\n", __func__,__LINE__,(ncp->fstype ==
558568 }
559569 }
560570
571+ #ifdef MPICH_VERSION
572+ /* MPICH recognizes file system type acronym prefixed to the file name */
561573 TRACE_IO (MPI_File_open , (comm , path , mpiomode , user_info , & fh ));
574+ #else
575+ TRACE_IO (MPI_File_open , (comm , filename , mpiomode , user_info , & fh ));
576+ #endif
562577 if (mpireturn != MPI_SUCCESS ) {
563578#ifndef HAVE_ACCESS
564579 if (fIsSet (cmode , NC_NOCLOBBER )) {
0 commit comments