From 382976f3e9822b3e003cc7a1b090bb3698850bd6 Mon Sep 17 00:00:00 2001 From: Mohamad Chaarawi Date: Wed, 9 Jul 2014 10:19:11 -0500 Subject: [svn-r25398] add a check to make sure MPI_File_get_size() returns correct value (HDFFV-8856). --- testpar/t_mpi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/testpar/t_mpi.c b/testpar/t_mpi.c index 27dc956..7bd2f58 100644 --- a/testpar/t_mpi.c +++ b/testpar/t_mpi.c @@ -379,7 +379,7 @@ test_mpio_gb_file(char *filename) mrc = MPI_Barrier(MPI_COMM_WORLD); VRFY((mrc==MPI_SUCCESS), "Sync before leaving test"); - printf("Test if MPI_File_get_size works with %s\n", filename); + printf("Test if MPI_File_get_size works correctly with %s\n", filename); mrc = MPI_File_open(MPI_COMM_WORLD, filename, MPI_MODE_RDONLY, info, &fh); VRFY((mrc==MPI_SUCCESS), ""); @@ -387,6 +387,7 @@ test_mpio_gb_file(char *filename) if (MAINPROCESS){ /* only process 0 needs to check it*/ mrc = MPI_File_get_size(fh, &size); VRFY((mrc==MPI_SUCCESS), ""); + VRFY((size == mpi_off+MB), "MPI_File_get_size doesn't return correct file size."); } /* close file and free the communicator */ -- cgit v0.12