summaryrefslogtreecommitdiffstats
path: root/src/H5EAiblock.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5EAiblock.c')
-rw-r--r--src/H5EAiblock.c24
1 files changed, 11 insertions, 13 deletions
diff --git a/src/H5EAiblock.c b/src/H5EAiblock.c
index 2d93015..9920277 100644
--- a/src/H5EAiblock.c
+++ b/src/H5EAiblock.c
@@ -178,7 +178,7 @@ END_FUNC(PKG) /* end H5EA__iblock_alloc() */
*/
BEGIN_FUNC(PKG, ERR,
haddr_t, HADDR_UNDEF, HADDR_UNDEF,
-H5EA__iblock_create(H5EA_hdr_t *hdr, hid_t dxpl_id, hbool_t *hdr_dirty))
+H5EA__iblock_create(H5EA_hdr_t *hdr, hid_t dxpl_id, hbool_t *stats_changed))
/* Local variables */
H5EA_iblock_t *iblock = NULL; /* Extensible array index block */
@@ -190,7 +190,7 @@ HDfprintf(stderr, "%s: Called\n", FUNC);
/* Sanity check */
HDassert(hdr);
- HDassert(hdr_dirty);
+ HDassert(stats_changed);
/* Allocate the index block */
if(NULL == (iblock = H5EA__iblock_alloc(hdr)))
@@ -235,16 +235,16 @@ HDfprintf(stderr, "%s: iblock->size = %Zu\n", FUNC, iblock->size);
H5E_THROW(H5E_CANTINSERT, "can't add extensible array index block to cache")
/* Update extensible array index block statistics */
- HDassert(0 == hdr->stats.nindex_blks);
- HDassert(0 == hdr->stats.index_blk_size);
- hdr->stats.nindex_blks = 1;
- hdr->stats.index_blk_size = iblock->size;
+ HDassert(0 == hdr->stats.computed.nindex_blks);
+ HDassert(0 == hdr->stats.computed.index_blk_size);
+ hdr->stats.computed.nindex_blks = 1;
+ hdr->stats.computed.index_blk_size = iblock->size;
/* Increment count of elements "realized" */
- hdr->stats.nelmts += hdr->cparam.idx_blk_elmts;
+ hdr->stats.stored.nelmts += hdr->cparam.idx_blk_elmts;
- /* Mark the header dirty (for updating statistics) */
- *hdr_dirty = TRUE;
+ /* Mark the statistics as changed */
+ *stats_changed = TRUE;
/* Set address of index block to return */
ret_value = iblock_addr;
@@ -281,8 +281,6 @@ BEGIN_FUNC(PKG, ERR,
H5EA_iblock_t *, NULL, NULL,
H5EA__iblock_protect(H5EA_hdr_t *hdr, hid_t dxpl_id, H5AC_protect_t rw))
- /* Local variables */
-
#ifdef QAK
HDfprintf(stderr, "%s: Called\n", FUNC);
#endif /* QAK */
@@ -378,7 +376,7 @@ HDfprintf(stderr, "%s: Called\n", FUNC);
/* Check for data block existing */
if(H5F_addr_defined(iblock->dblk_addrs[u])) {
/* Delete data block */
- if(H5EA__dblock_delete(hdr, dxpl_id, iblock->dblk_addrs[u], hdr->sblk_info[sblk_idx].dblk_nelmts) < 0)
+ if(H5EA__dblock_delete(hdr, dxpl_id, iblock, iblock->dblk_addrs[u], hdr->sblk_info[sblk_idx].dblk_nelmts) < 0)
H5E_THROW(H5E_CANTDELETE, "unable to delete extensible array data block")
iblock->dblk_addrs[u] = HADDR_UNDEF;
} /* end if */
@@ -403,7 +401,7 @@ HDfprintf(stderr, "%s: Called\n", FUNC);
/* Check for data block existing */
if(H5F_addr_defined(iblock->sblk_addrs[u])) {
/* Delete super block */
- if(H5EA__sblock_delete(hdr, dxpl_id, iblock->sblk_addrs[u], (unsigned)(u + iblock->nsblks)) < 0)
+ if(H5EA__sblock_delete(hdr, dxpl_id, iblock, iblock->sblk_addrs[u], (unsigned)(u + iblock->nsblks)) < 0)
H5E_THROW(H5E_CANTDELETE, "unable to delete extensible array super block")
iblock->sblk_addrs[u] = HADDR_UNDEF;
} /* end if */