2003-04-01 02:30:57 +08:00
|
|
|
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
2007-02-07 22:56:24 +08:00
|
|
|
* Copyright by The HDF Group. *
|
2003-04-01 02:30:57 +08:00
|
|
|
* Copyright by the Board of Trustees of the University of Illinois. *
|
|
|
|
* All rights reserved. *
|
|
|
|
* *
|
|
|
|
* This file is part of HDF5. The full HDF5 copyright notice, including *
|
|
|
|
* terms governing use, modification, and redistribution, is contained in *
|
|
|
|
* the files COPYING and Copyright.html. COPYING can be found at the root *
|
|
|
|
* of the source code distribution tree; Copyright.html can be found at the *
|
|
|
|
* root level of an installed copy of the electronic HDF5 document set and *
|
|
|
|
* is linked from the top-level documents page. It can also be found at *
|
2007-02-07 22:56:24 +08:00
|
|
|
* http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have *
|
|
|
|
* access to either file, you may request a copy from help@hdfgroup.org. *
|
2003-04-01 02:30:57 +08:00
|
|
|
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
|
|
|
|
1999-08-11 04:21:32 +08:00
|
|
|
/*
|
|
|
|
* Programmer: Robb Matzke <matzke@llnl.gov>
|
|
|
|
* Monday, August 2, 1999
|
|
|
|
*
|
|
|
|
* Purpose: The public header file for the mpio driver.
|
|
|
|
*/
|
|
|
|
#ifndef H5FDmpio_H
|
|
|
|
#define H5FDmpio_H
|
|
|
|
|
2014-03-22 07:02:24 +08:00
|
|
|
/* Macros */
|
|
|
|
|
1999-11-23 02:08:32 +08:00
|
|
|
#ifdef H5_HAVE_PARALLEL
|
1999-08-11 04:21:32 +08:00
|
|
|
# define H5FD_MPIO (H5FD_mpio_init())
|
|
|
|
#else
|
|
|
|
# define H5FD_MPIO (-1)
|
2002-06-20 01:07:52 +08:00
|
|
|
#endif /* H5_HAVE_PARALLEL */
|
1999-08-11 04:21:32 +08:00
|
|
|
|
[svn-r5894] Purpose:
Bug fix/Code cleanup/New Feature
Description:
Correct problems with writing fill-values to external storage and allocate
the data storage at the correct times.
Also, mostly straighten out the strange code which allocates and fills
raw data storage for datasets. Things are still a bit odd in that the
fill-values for chunked datasets are written when the space is allocated,
instead of in a separate routine, but there are two reasons for this:
it's inefficient (especially in parallel) to iterate through all the chunks
twice, and (more importantly) the space needed to store compressed chunks
isn't known until we've got a buffer of compressed fill-values ready to
write to the chunk.
Additionally, add in the H5D_SPACE_ALLOC_INCR and H5D_SPACE_ALLOC_DEFAULT
setting for the "space time", which incorporate the previous behavior of
the space allocation for chunked datasets.
The default settings for the different types of dataset storage are now
as follows:
Contiguous - Late
Chunked - Incremental
Compact - Early
This checkin also incorporates a change to the behavior of external data
storage in two ways - fill-values are _never_ written to external storage
(under the assumption that writing fill-values is triggered by allocating
space in an HDF5 file, and since space is not allocated in the file, the
fill-values should not be written) and external data files are now created
if they don't exist when data is written to them. The fill-value will
probably need to be revisited at some time in the future, this just seemed
like the safer course currently.
I think I cleaned up some compiler errors also, before getting bogged down
in the fixes for the space allocation and fill-values.
Platforms tested:
FreeBSD 4.6 (sleipnir) w/serial & parallel. Will be testing on IRIX64
6.5 (modi4) in serial & parallel shortly.
2002-08-27 21:41:32 +08:00
|
|
|
#ifdef H5_HAVE_PARALLEL
|
2000-04-11 02:22:10 +08:00
|
|
|
/*Turn on H5FDmpio_debug if H5F_DEBUG is on */
|
|
|
|
#ifdef H5F_DEBUG
|
|
|
|
#ifndef H5FDmpio_DEBUG
|
|
|
|
#define H5FDmpio_DEBUG
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
2014-03-22 07:02:24 +08:00
|
|
|
/* Global var whose value comes from environment variable */
|
|
|
|
/* (Defined in H5FDmpio.c) */
|
|
|
|
H5_DLLVAR hbool_t H5FD_mpi_opt_types_g;
|
|
|
|
|
2000-03-24 10:12:44 +08:00
|
|
|
/* Function prototypes */
|
2001-06-02 00:18:01 +08:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
2002-09-21 04:36:09 +08:00
|
|
|
H5_DLL hid_t H5FD_mpio_init(void);
|
|
|
|
H5_DLL herr_t H5Pset_fapl_mpio(hid_t fapl_id, MPI_Comm comm, MPI_Info info);
|
|
|
|
H5_DLL herr_t H5Pget_fapl_mpio(hid_t fapl_id, MPI_Comm *comm/*out*/,
|
1999-08-11 04:21:32 +08:00
|
|
|
MPI_Info *info/*out*/);
|
2002-09-21 04:36:09 +08:00
|
|
|
H5_DLL herr_t H5Pset_dxpl_mpio(hid_t dxpl_id, H5FD_mpio_xfer_t xfer_mode);
|
|
|
|
H5_DLL herr_t H5Pget_dxpl_mpio(hid_t dxpl_id, H5FD_mpio_xfer_t *xfer_mode/*out*/);
|
2006-08-09 11:00:11 +08:00
|
|
|
H5_DLL herr_t H5Pset_dxpl_mpio_collective_opt(hid_t dxpl_id, H5FD_mpio_collective_opt_t opt_mode);
|
2006-03-15 02:29:35 +08:00
|
|
|
H5_DLL herr_t H5Pset_dxpl_mpio_chunk_opt(hid_t dxpl_id, H5FD_mpio_chunk_opt_t opt_mode);
|
|
|
|
H5_DLL herr_t H5Pset_dxpl_mpio_chunk_opt_num(hid_t dxpl_id, unsigned num_chunk_per_proc);
|
|
|
|
H5_DLL herr_t H5Pset_dxpl_mpio_chunk_opt_ratio(hid_t dxpl_id, unsigned percent_num_proc_per_chunk);
|
2001-06-02 00:18:01 +08:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
1999-08-11 04:21:32 +08:00
|
|
|
|
2002-06-20 01:07:52 +08:00
|
|
|
#endif /* H5_HAVE_PARALLEL */
|
1999-08-11 04:21:32 +08:00
|
|
|
|
|
|
|
#endif
|
2011-04-21 21:55:52 +08:00
|
|
|
|