summaryrefslogtreecommitdiffstats
path: root/src/H5Dcontig.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2012-04-16 21:20:26 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2012-04-16 21:20:26 (GMT)
commita07c8f924703bdf3d1654b59cabf847f5d0f2683 (patch)
tree976dad3d894cfab9b88972a9e85d6bdfcf248f0d /src/H5Dcontig.c
parentbdb6e538ac8c4eae6413b2a7583289644dc9c90f (diff)
downloadhdf5-a07c8f924703bdf3d1654b59cabf847f5d0f2683.zip
hdf5-a07c8f924703bdf3d1654b59cabf847f5d0f2683.tar.gz
hdf5-a07c8f924703bdf3d1654b59cabf847f5d0f2683.tar.bz2
[svn-r22287] Description:
Clean up more FUNC_ENTER/FUNC_LEAVE macros and move H5D & H5T code toward the final design (as exemplified by the H5EA & H5FA code). Tested on: Mac OSX/64 10.7.3 (amazon) w/debug & parallel
Diffstat (limited to 'src/H5Dcontig.c')
-rw-r--r--src/H5Dcontig.c227
1 files changed, 101 insertions, 126 deletions
diff --git a/src/H5Dcontig.c b/src/H5Dcontig.c
index c1ff68c..acc7124 100644
--- a/src/H5Dcontig.c
+++ b/src/H5Dcontig.c
@@ -95,20 +95,20 @@ typedef struct H5D_contig_writevv_ud_t {
/********************/
/* Layout operation callbacks */
-static herr_t H5D_contig_construct(H5F_t *f, H5D_t *dset);
-static herr_t H5D_contig_io_init(const H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
+static herr_t H5D__contig_construct(H5F_t *f, H5D_t *dset);
+static herr_t H5D__contig_io_init(const H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
hsize_t nelmts, const H5S_t *file_space, const H5S_t *mem_space,
H5D_chunk_map_t *cm);
-static ssize_t H5D_contig_readvv(const H5D_io_info_t *io_info,
+static ssize_t H5D__contig_readvv(const H5D_io_info_t *io_info,
size_t dset_max_nseq, size_t *dset_curr_seq, size_t dset_len_arr[], hsize_t dset_offset_arr[],
size_t mem_max_nseq, size_t *mem_curr_seq, size_t mem_len_arr[], hsize_t mem_offset_arr[]);
-static ssize_t H5D_contig_writevv(const H5D_io_info_t *io_info,
+static ssize_t H5D__contig_writevv(const H5D_io_info_t *io_info,
size_t dset_max_nseq, size_t *dset_curr_seq, size_t dset_len_arr[], hsize_t dset_offset_arr[],
size_t mem_max_nseq, size_t *mem_curr_seq, size_t mem_len_arr[], hsize_t mem_offset_arr[]);
-static herr_t H5D_contig_flush(H5D_t *dset, hid_t dxpl_id);
+static herr_t H5D__contig_flush(H5D_t *dset, hid_t dxpl_id);
/* Helper routines */
-static herr_t H5D_contig_write_one(H5D_io_info_t *io_info, hsize_t offset,
+static herr_t H5D__contig_write_one(H5D_io_info_t *io_info, hsize_t offset,
size_t size);
@@ -118,19 +118,19 @@ static herr_t H5D_contig_write_one(H5D_io_info_t *io_info, hsize_t offset,
/* Contiguous storage layout I/O ops */
const H5D_layout_ops_t H5D_LOPS_CONTIG[1] = {{
- H5D_contig_construct,
+ H5D__contig_construct,
NULL,
- H5D_contig_is_space_alloc,
- H5D_contig_io_init,
- H5D_contig_read,
- H5D_contig_write,
+ H5D__contig_is_space_alloc,
+ H5D__contig_io_init,
+ H5D__contig_read,
+ H5D__contig_write,
#ifdef H5_HAVE_PARALLEL
- H5D_contig_collective_read,
- H5D_contig_collective_write,
+ H5D__contig_collective_read,
+ H5D__contig_collective_write,
#endif /* H5_HAVE_PARALLEL */
- H5D_contig_readvv,
- H5D_contig_writevv,
- H5D_contig_flush,
+ H5D__contig_readvv,
+ H5D__contig_writevv,
+ H5D__contig_flush,
NULL
}};
@@ -148,7 +148,7 @@ H5FL_BLK_EXTERN(type_conv);
/*-------------------------------------------------------------------------
- * Function: H5D_contig_alloc
+ * Function: H5D__contig_alloc
*
* Purpose: Allocate file space for a contiguously stored dataset
*
@@ -160,11 +160,11 @@ H5FL_BLK_EXTERN(type_conv);
*-------------------------------------------------------------------------
*/
herr_t
-H5D_contig_alloc(H5F_t *f, hid_t dxpl_id, H5O_storage_contig_t *storage /*out */ )
+H5D__contig_alloc(H5F_t *f, hid_t dxpl_id, H5O_storage_contig_t *storage /*out */ )
{
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI(FAIL)
+ FUNC_ENTER_PACKAGE
/* check args */
HDassert(f);
@@ -176,11 +176,11 @@ H5D_contig_alloc(H5F_t *f, hid_t dxpl_id, H5O_storage_contig_t *storage /*out */
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_alloc */
+} /* end H5D__contig_alloc */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_fill
+ * Function: H5D__contig_fill
*
* Purpose: Write fill values to a contiguously stored dataset.
*
@@ -192,7 +192,7 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5D_contig_fill(H5D_t *dset, hid_t dxpl_id)
+H5D__contig_fill(H5D_t *dset, hid_t dxpl_id)
{
H5D_io_info_t ioinfo; /* Dataset I/O info */
H5D_storage_t store; /* Union of storage info for dataset */
@@ -213,7 +213,7 @@ H5D_contig_fill(H5D_t *dset, hid_t dxpl_id)
hid_t my_dxpl_id; /* DXPL ID to use for this operation */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI(FAIL)
+ FUNC_ENTER_PACKAGE
/* Check args */
HDassert(TRUE == H5P_isa_class(dxpl_id, H5P_DATASET_XFER));
@@ -249,7 +249,7 @@ H5D_contig_fill(H5D_t *dset, hid_t dxpl_id)
#endif /* H5_HAVE_PARALLEL */
/* Fill the DXPL cache values for later use */
- if(H5D_get_dxpl_cache(my_dxpl_id, &dxpl_cache) < 0)
+ if(H5D__get_dxpl_cache(my_dxpl_id, &dxpl_cache) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't fill dxpl cache")
/* Initialize storage info for this dataset */
@@ -262,7 +262,7 @@ H5D_contig_fill(H5D_t *dset, hid_t dxpl_id)
H5_ASSIGN_OVERFLOW(npoints, snpoints, hssize_t, size_t);
/* Initialize the fill value buffer */
- if(H5D_fill_init(&fb_info, NULL, NULL, NULL, NULL, NULL,
+ if(H5D__fill_init(&fb_info, NULL, NULL, NULL, NULL, NULL,
&dset->shared->dcpl_cache.fill,
dset->shared->type, dset->shared->type_id, npoints,
dxpl_cache->max_temp_buf, my_dxpl_id) < 0)
@@ -293,7 +293,7 @@ H5D_contig_fill(H5D_t *dset, hid_t dxpl_id)
/* Check for VL datatype & non-default fill value */
if(fb_info.has_vlen_fill_type)
/* Re-fill the buffer to use for this I/O operation */
- if(H5D_fill_refill_vl(&fb_info, curr_points, my_dxpl_id) < 0)
+ if(H5D__fill_refill_vl(&fb_info, curr_points, my_dxpl_id) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTCONVERT, FAIL, "can't refill fill value buffer")
#ifdef H5_HAVE_PARALLEL
@@ -302,7 +302,7 @@ H5D_contig_fill(H5D_t *dset, hid_t dxpl_id)
/* Write the chunks out from only one process */
/* !! Use the internal "independent" DXPL!! -QAK */
if(H5_PAR_META_WRITE == mpi_rank)
- if(H5D_contig_write_one(&ioinfo, offset, size) < 0)
+ if(H5D__contig_write_one(&ioinfo, offset, size) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to write fill value to dataset")
/* Indicate that blocks are being written */
@@ -311,7 +311,7 @@ H5D_contig_fill(H5D_t *dset, hid_t dxpl_id)
else {
#endif /* H5_HAVE_PARALLEL */
H5_CHECK_OVERFLOW(size, size_t, hsize_t);
- if(H5D_contig_write_one(&ioinfo, offset, size) < 0)
+ if(H5D__contig_write_one(&ioinfo, offset, size) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to write fill value to dataset")
#ifdef H5_HAVE_PARALLEL
} /* end else */
@@ -336,15 +336,15 @@ H5D_contig_fill(H5D_t *dset, hid_t dxpl_id)
done:
/* Release the fill buffer info, if it's been initialized */
- if(fb_info_init && H5D_fill_term(&fb_info) < 0)
+ if(fb_info_init && H5D__fill_term(&fb_info) < 0)
HDONE_ERROR(H5E_DATASET, H5E_CANTFREE, FAIL, "Can't release fill buffer info")
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_fill() */
+} /* end H5D__contig_fill() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_delete
+ * Function: H5D__contig_delete
*
* Purpose: Delete the file space for a contiguously stored dataset
*
@@ -356,11 +356,11 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5D_contig_delete(H5F_t *f, hid_t dxpl_id, const H5O_storage_t *storage)
+H5D__contig_delete(H5F_t *f, hid_t dxpl_id, const H5O_storage_t *storage)
{
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI(FAIL)
+ FUNC_ENTER_PACKAGE
/* check args */
HDassert(f);
@@ -372,36 +372,11 @@ H5D_contig_delete(H5F_t *f, hid_t dxpl_id, const H5O_storage_t *storage)
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_delete */
+} /* end H5D__contig_delete */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_get_addr
- *
- * Purpose: Get the offset of the contiguous data on disk
- *
- * Return: Non-negative on success/Negative on failure
- *
- * Programmer: Quincey Koziol
- * June 2, 2004
- *
- *-------------------------------------------------------------------------
- */
-haddr_t
-H5D_contig_get_addr(const H5D_t *dset)
-{
- FUNC_ENTER_NOAPI_NOERR
-
- /* check args */
- HDassert(dset);
- HDassert(dset->shared->layout.type == H5D_CONTIGUOUS);
-
- FUNC_LEAVE_NOAPI(dset->shared->layout.storage.u.contig.addr)
-} /* end H5D_contig_get_addr() */
-
-
-/*-------------------------------------------------------------------------
- * Function: H5D_contig_construct
+ * Function: H5D__contig_construct
*
* Purpose: Constructs new contiguous layout information for dataset
*
@@ -414,7 +389,7 @@ H5D_contig_get_addr(const H5D_t *dset)
*/
/* ARGSUSED */
static herr_t
-H5D_contig_construct(H5F_t *f, H5D_t *dset)
+H5D__contig_construct(H5F_t *f, H5D_t *dset)
{
hssize_t snelmts; /* Temporary holder for number of elements in dataspace */
hsize_t nelmts; /* Number of elements in dataspace */
@@ -427,7 +402,7 @@ H5D_contig_construct(H5F_t *f, H5D_t *dset)
int i; /* Local index variable */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Sanity checks */
HDassert(f);
@@ -477,11 +452,11 @@ H5D_contig_construct(H5F_t *f, H5D_t *dset)
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_construct() */
+} /* end H5D__contig_construct() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_is_space_alloc
+ * Function: H5D__contig_is_space_alloc
*
* Purpose: Query if space is allocated for layout
*
@@ -493,11 +468,11 @@ done:
*-------------------------------------------------------------------------
*/
hbool_t
-H5D_contig_is_space_alloc(const H5O_storage_t *storage)
+H5D__contig_is_space_alloc(const H5O_storage_t *storage)
{
hbool_t ret_value; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT_NOERR
+ FUNC_ENTER_PACKAGE_NOERR
/* Sanity checks */
HDassert(storage);
@@ -506,11 +481,11 @@ H5D_contig_is_space_alloc(const H5O_storage_t *storage)
ret_value = (hbool_t)H5F_addr_defined(storage->u.contig.addr);
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_is_space_alloc() */
+} /* end H5D__contig_is_space_alloc() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_io_init
+ * Function: H5D__contig_io_init
*
* Purpose: Performs initialization before any sort of I/O on the raw data
*
@@ -522,21 +497,21 @@ H5D_contig_is_space_alloc(const H5O_storage_t *storage)
*-------------------------------------------------------------------------
*/
static herr_t
-H5D_contig_io_init(const H5D_io_info_t *io_info, const H5D_type_info_t UNUSED *type_info,
+H5D__contig_io_init(const H5D_io_info_t *io_info, const H5D_type_info_t UNUSED *type_info,
hsize_t UNUSED nelmts, const H5S_t UNUSED *file_space, const H5S_t UNUSED *mem_space,
H5D_chunk_map_t UNUSED *cm)
{
- FUNC_ENTER_NOAPI_NOINIT_NOERR
+ FUNC_ENTER_STATIC_NOERR
io_info->store->contig.dset_addr = io_info->dset->shared->layout.storage.u.contig.addr;
io_info->store->contig.dset_size = io_info->dset->shared->layout.storage.u.contig.size;
FUNC_LEAVE_NOAPI(SUCCEED)
-} /* end H5D_contig_io_init() */
+} /* end H5D__contig_io_init() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_read
+ * Function: H5D__contig_read
*
* Purpose: Read from a contiguous dataset.
*
@@ -548,13 +523,13 @@ H5D_contig_io_init(const H5D_io_info_t *io_info, const H5D_type_info_t UNUSED *t
*-------------------------------------------------------------------------
*/
herr_t
-H5D_contig_read(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
+H5D__contig_read(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
hsize_t nelmts, const H5S_t *file_space, const H5S_t *mem_space,
H5D_chunk_map_t UNUSED *fm)
{
herr_t ret_value = SUCCEED; /*return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_PACKAGE
/* Sanity check */
HDassert(io_info);
@@ -569,11 +544,11 @@ H5D_contig_read(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_read() */
+} /* end H5D__contig_read() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_write
+ * Function: H5D__contig_write
*
* Purpose: Write to a contiguous dataset.
*
@@ -585,13 +560,13 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5D_contig_write(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
+H5D__contig_write(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
hsize_t nelmts, const H5S_t *file_space, const H5S_t *mem_space,
H5D_chunk_map_t UNUSED *fm)
{
herr_t ret_value = SUCCEED; /*return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_PACKAGE
/* Sanity check */
HDassert(io_info);
@@ -606,11 +581,11 @@ H5D_contig_write(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_write() */
+} /* end H5D__contig_write() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_write_one
+ * Function: H5D__contig_write_one
*
* Purpose: Writes some data from a dataset into a buffer.
* The data is contiguous. The address is relative to the base
@@ -624,7 +599,7 @@ done:
*-------------------------------------------------------------------------
*/
static herr_t
-H5D_contig_write_one(H5D_io_info_t *io_info, hsize_t offset, size_t size)
+H5D__contig_write_one(H5D_io_info_t *io_info, hsize_t offset, size_t size)
{
hsize_t dset_off = offset; /* Offset in dataset */
size_t dset_len = size; /* Length in dataset */
@@ -634,23 +609,23 @@ H5D_contig_write_one(H5D_io_info_t *io_info, hsize_t offset, size_t size)
size_t mem_curr_seq = 0; /* "Current sequence" in memory */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
HDassert(io_info);
- if(H5D_contig_writevv(io_info, (size_t)1, &dset_curr_seq, &dset_len, &dset_off,
+ if(H5D__contig_writevv(io_info, (size_t)1, &dset_curr_seq, &dset_len, &dset_off,
(size_t)1, &mem_curr_seq, &mem_len, &mem_off) < 0)
HGOTO_ERROR(H5E_IO, H5E_WRITEERROR, FAIL, "vector write failed")
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_write_one() */
+} /* end H5D__contig_write_one() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_readvv_sieve_cb
+ * Function: H5D__contig_readvv_sieve_cb
*
- * Purpose: Callback operator for H5D_contig_readvv() with sieve buffer.
+ * Purpose: Callback operator for H5D__contig_readvv() with sieve buffer.
*
* Return: Non-negative on success/Negative on failure
*
@@ -660,7 +635,7 @@ done:
*-------------------------------------------------------------------------
*/
static herr_t
-H5D_contig_readvv_sieve_cb(hsize_t dst_off, hsize_t src_off, size_t len,
+H5D__contig_readvv_sieve_cb(hsize_t dst_off, hsize_t src_off, size_t len,
void *_udata)
{
H5D_contig_readvv_sieve_ud_t *udata = (H5D_contig_readvv_sieve_ud_t *)_udata; /* User data for H5V_opvv() operator */
@@ -676,7 +651,7 @@ H5D_contig_readvv_sieve_cb(hsize_t dst_off, hsize_t src_off, size_t len,
hsize_t max_data; /* Actual maximum size of data to cache */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Stash local copies of these value */
if(dset_contig->sieve_buf != NULL) {
@@ -811,13 +786,13 @@ H5D_contig_readvv_sieve_cb(hsize_t dst_off, hsize_t src_off, size_t len,
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_readvv_sieve_cb() */
+} /* end H5D__contig_readvv_sieve_cb() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_readvv_cb
+ * Function: H5D__contig_readvv_cb
*
- * Purpose: Callback operator for H5D_contig_readvv() without sieve buffer.
+ * Purpose: Callback operator for H5D__contig_readvv() without sieve buffer.
*
* Return: Non-negative on success/Negative on failure
*
@@ -827,12 +802,12 @@ done:
*-------------------------------------------------------------------------
*/
static herr_t
-H5D_contig_readvv_cb(hsize_t dst_off, hsize_t src_off, size_t len, void *_udata)
+H5D__contig_readvv_cb(hsize_t dst_off, hsize_t src_off, size_t len, void *_udata)
{
H5D_contig_readvv_ud_t *udata = (H5D_contig_readvv_ud_t *)_udata; /* User data for H5V_opvv() operator */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Write data */
if(H5F_block_read(udata->file, H5FD_MEM_DRAW, (udata->dset_addr + dst_off),
@@ -841,11 +816,11 @@ H5D_contig_readvv_cb(hsize_t dst_off, hsize_t src_off, size_t len, void *_udata)
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_readvv_cb() */
+} /* end H5D__contig_readvv_cb() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_readvv
+ * Function: H5D__contig_readvv
*
* Purpose: Reads some data vectors from a dataset into a buffer.
* The data is contiguous. The address is the start of the dataset,
@@ -863,13 +838,13 @@ done:
*-------------------------------------------------------------------------
*/
static ssize_t
-H5D_contig_readvv(const H5D_io_info_t *io_info,
+H5D__contig_readvv(const H5D_io_info_t *io_info,
size_t dset_max_nseq, size_t *dset_curr_seq, size_t dset_len_arr[], hsize_t dset_off_arr[],
size_t mem_max_nseq, size_t *mem_curr_seq, size_t mem_len_arr[], hsize_t mem_off_arr[])
{
ssize_t ret_value; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Check args */
HDassert(io_info);
@@ -894,7 +869,7 @@ H5D_contig_readvv(const H5D_io_info_t *io_info,
/* Call generic sequence operation routine */
if((ret_value = H5V_opvv(dset_max_nseq, dset_curr_seq, dset_len_arr, dset_off_arr,
mem_max_nseq, mem_curr_seq, mem_len_arr, mem_off_arr,
- H5D_contig_readvv_sieve_cb, &udata)) < 0)
+ H5D__contig_readvv_sieve_cb, &udata)) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTOPERATE, FAIL, "can't perform vectorized sieve buffer read")
} /* end if */
else {
@@ -909,19 +884,19 @@ H5D_contig_readvv(const H5D_io_info_t *io_info,
/* Call generic sequence operation routine */
if((ret_value = H5V_opvv(dset_max_nseq, dset_curr_seq, dset_len_arr, dset_off_arr,
mem_max_nseq, mem_curr_seq, mem_len_arr, mem_off_arr,
- H5D_contig_readvv_cb, &udata)) < 0)
+ H5D__contig_readvv_cb, &udata)) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTOPERATE, FAIL, "can't perform vectorized read")
} /* end else */
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_readvv() */
+} /* end H5D__contig_readvv() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_writevv_sieve_cb
+ * Function: H5D__contig_writevv_sieve_cb
*
- * Purpose: Callback operator for H5D_contig_writevv() with sieve buffer.
+ * Purpose: Callback operator for H5D__contig_writevv() with sieve buffer.
*
* Return: Non-negative on success/Negative on failure
*
@@ -931,7 +906,7 @@ done:
*-------------------------------------------------------------------------
*/
static herr_t
-H5D_contig_writevv_sieve_cb(hsize_t dst_off, hsize_t src_off, size_t len,
+H5D__contig_writevv_sieve_cb(hsize_t dst_off, hsize_t src_off, size_t len,
void *_udata)
{
H5D_contig_writevv_sieve_ud_t *udata = (H5D_contig_writevv_sieve_ud_t *)_udata; /* User data for H5V_opvv() operator */
@@ -947,7 +922,7 @@ H5D_contig_writevv_sieve_cb(hsize_t dst_off, hsize_t src_off, size_t len,
hsize_t max_data; /* Actual maximum size of data to cache */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Stash local copies of these values */
if(dset_contig->sieve_buf != NULL) {
@@ -1133,13 +1108,13 @@ if(dset_contig->sieve_size > len)
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_writevv_sieve_cb() */
+} /* end H5D__contig_writevv_sieve_cb() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_writevv_cb
+ * Function: H5D__contig_writevv_cb
*
- * Purpose: Callback operator for H5D_contig_writevv().
+ * Purpose: Callback operator for H5D__contig_writevv().
*
* Return: Non-negative on success/Negative on failure
*
@@ -1149,12 +1124,12 @@ done:
*-------------------------------------------------------------------------
*/
static herr_t
-H5D_contig_writevv_cb(hsize_t dst_off, hsize_t src_off, size_t len, void *_udata)
+H5D__contig_writevv_cb(hsize_t dst_off, hsize_t src_off, size_t len, void *_udata)
{
H5D_contig_writevv_ud_t *udata = (H5D_contig_writevv_ud_t *)_udata; /* User data for H5V_opvv() operator */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Write data */
if(H5F_block_write(udata->file, H5FD_MEM_DRAW, (udata->dset_addr + dst_off), len, udata->dxpl_id, (udata->wbuf + src_off)) < 0)
@@ -1162,11 +1137,11 @@ H5D_contig_writevv_cb(hsize_t dst_off, hsize_t src_off, size_t len, void *_udata
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_writevv_cb() */
+} /* end H5D__contig_writevv_cb() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_writevv
+ * Function: H5D__contig_writevv
*
* Purpose: Writes some data vectors into a dataset from vectors into a
* buffer. The address is the start of the dataset,
@@ -1184,13 +1159,13 @@ done:
*-------------------------------------------------------------------------
*/
static ssize_t
-H5D_contig_writevv(const H5D_io_info_t *io_info,
+H5D__contig_writevv(const H5D_io_info_t *io_info,
size_t dset_max_nseq, size_t *dset_curr_seq, size_t dset_len_arr[], hsize_t dset_off_arr[],
size_t mem_max_nseq, size_t *mem_curr_seq, size_t mem_len_arr[], hsize_t mem_off_arr[])
{
ssize_t ret_value; /* Return value (Size of sequence in bytes) */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Check args */
HDassert(io_info);
@@ -1215,7 +1190,7 @@ H5D_contig_writevv(const H5D_io_info_t *io_info,
/* Call generic sequence operation routine */
if((ret_value = H5V_opvv(dset_max_nseq, dset_curr_seq, dset_len_arr, dset_off_arr,
mem_max_nseq, mem_curr_seq, mem_len_arr, mem_off_arr,
- H5D_contig_writevv_sieve_cb, &udata)) < 0)
+ H5D__contig_writevv_sieve_cb, &udata)) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTOPERATE, FAIL, "can't perform vectorized sieve buffer write")
} /* end if */
else {
@@ -1230,17 +1205,17 @@ H5D_contig_writevv(const H5D_io_info_t *io_info,
/* Call generic sequence operation routine */
if((ret_value = H5V_opvv(dset_max_nseq, dset_curr_seq, dset_len_arr, dset_off_arr,
mem_max_nseq, mem_curr_seq, mem_len_arr, mem_off_arr,
- H5D_contig_writevv_cb, &udata)) < 0)
+ H5D__contig_writevv_cb, &udata)) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTOPERATE, FAIL, "can't perform vectorized read")
} /* end else */
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_writevv() */
+} /* end H5D__contig_writevv() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_flush
+ * Function: H5D__contig_flush
*
* Purpose: Writes all dirty data to disk.
*
@@ -1252,26 +1227,26 @@ done:
*-------------------------------------------------------------------------
*/
static herr_t
-H5D_contig_flush(H5D_t *dset, hid_t dxpl_id)
+H5D__contig_flush(H5D_t *dset, hid_t dxpl_id)
{
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Sanity check */
HDassert(dset);
/* Flush any data in sieve buffer */
- if(H5D_flush_sieve_buf(dset, dxpl_id) < 0)
+ if(H5D__flush_sieve_buf(dset, dxpl_id) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTFLUSH, FAIL, "unable to flush sieve buffer")
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_flush() */
+} /* end H5D__contig_flush() */
/*-------------------------------------------------------------------------
- * Function: H5D_contig_copy
+ * Function: H5D__contig_copy
*
* Purpose: Copy contiguous storage raw data from SRC file to DST file.
*
@@ -1283,7 +1258,7 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5D_contig_copy(H5F_t *f_src, const H5O_storage_contig_t *storage_src,
+H5D__contig_copy(H5F_t *f_src, const H5O_storage_contig_t *storage_src,
H5F_t *f_dst, H5O_storage_contig_t *storage_dst, H5T_t *dt_src,
H5O_copy_t *cpy_info, hid_t dxpl_id)
{
@@ -1315,7 +1290,7 @@ H5D_contig_copy(H5F_t *f_src, const H5O_storage_contig_t *storage_src,
hbool_t fix_ref = FALSE; /* Flag to indicate that ref values should be fixed */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI(FAIL)
+ FUNC_ENTER_PACKAGE
/* Check args */
HDassert(f_src);
@@ -1325,7 +1300,7 @@ H5D_contig_copy(H5F_t *f_src, const H5O_storage_contig_t *storage_src,
HDassert(dt_src);
/* Allocate space for destination raw data */
- if(H5D_contig_alloc(f_dst, dxpl_id, storage_dst) < 0)
+ if(H5D__contig_alloc(f_dst, dxpl_id, storage_dst) < 0)
HGOTO_ERROR(H5E_IO, H5E_CANTINIT, FAIL, "unable to allocate contiguous storage")
/* Set up number of bytes to copy, and initial buffer size */
@@ -1532,5 +1507,5 @@ done:
bkg = H5FL_BLK_FREE(type_conv, bkg);
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5D_contig_copy() */
+} /* end H5D__contig_copy() */