diff options
author | Albert Cheng <acheng@hdfgroup.org> | 2009-08-11 10:34:58 (GMT) |
---|---|---|
committer | Albert Cheng <acheng@hdfgroup.org> | 2009-08-11 10:34:58 (GMT) |
commit | 5aa72127e6577068d848219f1c3feabf62a0cc1d (patch) | |
tree | 460d22d38b4932943e8d2653553914e3a7fc5b65 /testpar/t_file.c | |
parent | 908ce6d7214948e71dbeb01f129789c4c669861a (diff) | |
download | hdf5-5aa72127e6577068d848219f1c3feabf62a0cc1d.zip hdf5-5aa72127e6577068d848219f1c3feabf62a0cc1d.tar.gz hdf5-5aa72127e6577068d848219f1c3feabf62a0cc1d.tar.bz2 |
[svn-r17317] Did some code cleanup.
t_file.c: replace the old variable, color, with a more meaningfule name of
is_old.
t_mpi.c: use the official mpi_file_delete, instead of remove, to delete a file
in MPI environment.
Tested:
Only jam in parallel as changes are trivial.
Diffstat (limited to 'testpar/t_file.c')
-rw-r--r-- | testpar/t_file.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/testpar/t_file.c b/testpar/t_file.c index 9de4e0e..ff983a9 100644 --- a/testpar/t_file.c +++ b/testpar/t_file.c @@ -36,7 +36,7 @@ test_split_comm_access(void) int mpi_size, mpi_rank; MPI_Comm comm; MPI_Info info = MPI_INFO_NULL; - int color, mrc; + int is_old, mrc; int newrank, newprocs; hid_t fid; /* file IDs */ hid_t acc_tpl; /* File access properties */ @@ -52,13 +52,13 @@ test_split_comm_access(void) /* set up MPI parameters */ MPI_Comm_size(MPI_COMM_WORLD,&mpi_size); MPI_Comm_rank(MPI_COMM_WORLD,&mpi_rank); - color = mpi_rank%2; - mrc = MPI_Comm_split (MPI_COMM_WORLD, color, mpi_rank, &comm); + is_old = mpi_rank%2; + mrc = MPI_Comm_split (MPI_COMM_WORLD, is_old, mpi_rank, &comm); VRFY((mrc==MPI_SUCCESS), ""); MPI_Comm_size(comm,&newprocs); MPI_Comm_rank(comm,&newrank); - if (color){ + if (is_old){ /* odd-rank processes */ mrc = MPI_Barrier(comm); VRFY((mrc==MPI_SUCCESS), ""); |