Skip to content

Commit f2f6f7b

Browse files
committed
add MPI_File_fence
1 parent c5b12c1 commit f2f6f7b

File tree

19 files changed

+175
-0
lines changed

19 files changed

+175
-0
lines changed

src/mpi/romio/adio/ad_gpfs/ad_gpfs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ struct ADIOI_Fns_struct ADIO_GPFS_operations = {
4545
ADIOI_GEN_IreadStrided, /* IreadStrided */
4646
ADIOI_GEN_IwriteStrided, /* IwriteStrided */
4747
ADIOI_GPFS_Flush, /* Flush */
48+
ADIOI_GEN_Fence, /* Fence */
4849
ADIOI_GEN_Resize, /* Resize */
4950
ADIOI_GEN_Delete, /* Delete */
5051
ADIOI_GEN_Feature, /* Features */

src/mpi/romio/adio/ad_lustre/ad_lustre.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ struct ADIOI_Fns_struct ADIO_LUSTRE_operations = {
3232
ADIOI_GEN_IreadStrided, /* IreadStrided */
3333
ADIOI_GEN_IwriteStrided, /* IwriteStrided */
3434
ADIOI_GEN_Flush, /* Flush */
35+
ADIOI_GEN_Fence, /* Fence */
3536
ADIOI_GEN_Resize, /* Resize */
3637
ADIOI_GEN_Delete, /* Delete */
3738
ADIOI_GEN_Feature, /* Features */

src/mpi/romio/adio/ad_nfs/ad_nfs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ struct ADIOI_Fns_struct ADIO_NFS_operations = {
3232
ADIOI_GEN_IreadStrided, /* IreadStrided */
3333
ADIOI_GEN_IwriteStrided, /* IwriteStrided */
3434
ADIOI_GEN_Flush, /* Flush */
35+
ADIOI_GEN_Fence, /* Fence */
3536
ADIOI_NFS_Resize, /* Resize */
3637
ADIOI_GEN_Delete, /* Delete */
3738
ADIOI_NFS_Feature, /* Features */

src/mpi/romio/adio/ad_testfs/Makefile.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ romio_other_sources += \
2020
adio/ad_testfs/ad_testfs_iwrite.c \
2121
adio/ad_testfs/ad_testfs_wait.c \
2222
adio/ad_testfs/ad_testfs_flush.c \
23+
adio/ad_testfs/ad_testfs_fence.c \
2324
adio/ad_testfs/ad_testfs_seek.c \
2425
adio/ad_testfs/ad_testfs_resize.c \
2526
adio/ad_testfs/ad_testfs_hints.c \

src/mpi/romio/adio/ad_testfs/ad_testfs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ struct ADIOI_Fns_struct ADIO_TESTFS_operations = {
3030
ADIOI_TESTFS_IreadStrided, /* IreadStrided */
3131
ADIOI_TESTFS_IwriteStrided, /* IwriteStrided */
3232
ADIOI_TESTFS_Flush, /* Flush */
33+
ADIOI_TESTFS_Fence, /* Fence */
3334
ADIOI_TESTFS_Resize, /* Resize */
3435
ADIOI_TESTFS_Delete, /* Delete */
3536
ADIOI_GEN_Feature, /* Features */

src/mpi/romio/adio/ad_testfs/ad_testfs.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ void ADIOI_TESTFS_IwriteStrided(ADIO_File fd, const void *buf, int count,
6262
ADIO_Offset offset, ADIO_Request * request, int
6363
*error_code);
6464
void ADIOI_TESTFS_Flush(ADIO_File fd, int *error_code);
65+
void ADIOI_TESTFS_Fence(ADIO_File fd, int *error_code);
6566
void ADIOI_TESTFS_Resize(ADIO_File fd, ADIO_Offset size, int *error_code);
6667
ADIO_Offset ADIOI_TESTFS_SeekIndividual(ADIO_File fd, ADIO_Offset offset,
6768
int whence, int *error_code);
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/*
2+
* Copyright (C) by Argonne National Laboratory
3+
* See COPYRIGHT in top-level directory
4+
*/
5+
6+
#include "ad_testfs.h"
7+
#include "adioi.h"
8+
9+
void ADIOI_TESTFS_Fence(ADIO_File fd, int *error_code)
10+
{
11+
int myrank, nprocs;
12+
13+
*error_code = MPI_SUCCESS;
14+
15+
MPI_Comm_size(fd->comm, &nprocs);
16+
MPI_Comm_rank(fd->comm, &myrank);
17+
FPRINTF(stdout, "[%d/%d] ADIOI_TESTFS_Fence called on %s\n", myrank, nprocs, fd->filename);
18+
}

src/mpi/romio/adio/ad_ufs/ad_ufs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ struct ADIOI_Fns_struct ADIO_UFS_operations = {
3535
ADIOI_GEN_IreadStrided, /* IreadStrided */
3636
ADIOI_GEN_IwriteStrided, /* IwriteStrided */
3737
ADIOI_GEN_Flush, /* Flush */
38+
ADIOI_GEN_Fence, /* Fence */
3839
ADIOI_GEN_Resize, /* Resize */
3940
ADIOI_GEN_Delete, /* Delete */
4041
ADIOI_GEN_Feature, /* Features */

src/mpi/romio/adio/ad_unify/Makefile.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ romio_other_sources += \
1515
adio/ad_unify/ad_unify_close.c \
1616
adio/ad_unify/ad_unify_io.c \
1717
adio/ad_unify/ad_unify_flush.c \
18+
adio/ad_unify/ad_unify_fence.c \
1819
adio/ad_unify/ad_unify_delete.c \
1920
adio/ad_unify/ad_unify_fcntl.c \
2021
adio/ad_unify/ad_unify_resize.c \

src/mpi/romio/adio/ad_unify/ad_unify.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ struct ADIOI_Fns_struct ADIO_UNIFY_operations = {
3535
ADIOI_FAKE_IreadStrided, /* IreadStrided */
3636
ADIOI_FAKE_IwriteStrided, /* IwriteStrided */
3737
ADIOI_UNIFY_Flush, /* Flush */
38+
ADIOI_UNIFY_Fence, /* Fence */
3839
ADIOI_UNIFY_Resize, /* Resize */
3940
ADIOI_UNIFY_Delete, /* Delete */
4041
ADIOI_UNIFY_Feature,

0 commit comments

Comments
 (0)