diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2002-05-17 12:53:46 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2002-05-17 12:53:46 (GMT) |
commit | a6b4cba798a494dea1d29474cc5658f7003615d9 (patch) | |
tree | 5ffa6f7b9868849e81a6392b29ad59ec9218dfe1 /src/H5FDmpio.c | |
parent | 567c04276158059089d64e0e9fd5b9c7e1b8d7ba (diff) | |
download | hdf5-a6b4cba798a494dea1d29474cc5658f7003615d9.zip hdf5-a6b4cba798a494dea1d29474cc5658f7003615d9.tar.gz hdf5-a6b4cba798a494dea1d29474cc5658f7003615d9.tar.bz2 |
[svn-r5429] Purpose:
Bug fix/Code improvement.
Description:
Currently, the chunk data allocation routine invoked to allocate space for
the entire dataset is inefficient. It writes out each chunk in the dataset,
whether it is already allocated or not. Additionally, this happens not
only when it is created, but also anytime it is opened for writing, or the
dataset is extended. Worse, there's too much parallel I/O syncronization,
which slows things down even more.
Solution:
Only attempt to write out chunks that don't already exist. Additionally,
share the I/O writing between all the nodes, instead of writing everything
with process 0. Then, only block with MPI_Barrier if chunks were actually
created.
Platforms tested:
IRIX64 6.5 (modi4)
Diffstat (limited to 'src/H5FDmpio.c')
-rw-r--r-- | src/H5FDmpio.c | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/src/H5FDmpio.c b/src/H5FDmpio.c index f4ba335..3572390 100644 --- a/src/H5FDmpio.c +++ b/src/H5FDmpio.c @@ -449,6 +449,62 @@ H5FD_mpio_communicator(H5FD_t *_file) /*------------------------------------------------------------------------- + * Function: H5FD_mpio_mpi_rank + * + * Purpose: Returns the MPI rank for a process + * + * Return: Success: non-negative + * Failure: negative + * + * Programmer: Quincey Koziol + * Thursday, May 16, 2002 + * + * Modifications: + * + *------------------------------------------------------------------------- + */ +int +H5FD_mpio_mpi_rank(H5FD_t *_file) +{ + H5FD_mpio_t *file = (H5FD_mpio_t*)_file; + + FUNC_ENTER(H5FD_mpio_mpi_rank, FAIL); + assert(file); + assert(H5FD_MPIO==file->pub.driver_id); + + FUNC_LEAVE(file->mpi_rank); +} /* end H5FD_mpio_mpi_rank() */ + + +/*------------------------------------------------------------------------- + * Function: H5FD_mpio_mpi_size + * + * Purpose: Returns the number of MPI processes + * + * Return: Success: non-negative + * Failure: negative + * + * Programmer: Quincey Koziol + * Thursday, May 16, 2002 + * + * Modifications: + * + *------------------------------------------------------------------------- + */ +int +H5FD_mpio_mpi_size(H5FD_t *_file) +{ + H5FD_mpio_t *file = (H5FD_mpio_t*)_file; + + FUNC_ENTER(H5FD_mpio_mpi_rank, FAIL); + assert(file); + assert(H5FD_MPIO==file->pub.driver_id); + + FUNC_LEAVE(file->mpi_size); +} /* end H5FD_mpio_mpi_size() */ + + +/*------------------------------------------------------------------------- * Function: H5FD_mpio_setup * * Purpose: Set the buffer type BTYPE, file type FTYPE, and absolute base |