summaryrefslogtreecommitdiffstats
path: root/src/H5EAiblock.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2008-09-25 23:14:43 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2008-09-25 23:14:43 (GMT)
commitf9f71a001ba65fbc515b440bf5cbace452947800 (patch)
tree22affd8e35a5bedb34827439b029214f58d8a851 /src/H5EAiblock.c
parent6a1614de3ea33c98e8fe6d11b8ac0a590f4d445a (diff)
downloadhdf5-f9f71a001ba65fbc515b440bf5cbace452947800.zip
hdf5-f9f71a001ba65fbc515b440bf5cbace452947800.tar.gz
hdf5-f9f71a001ba65fbc515b440bf5cbace452947800.tar.bz2
[svn-r15703] Description:
Further progress on extensible array implementation - add support for more data blocks from index block. Tested on: Mac OS X/32 10.5.4 (amazon) in debug mode Mac OS X/32 10.5.4 (amazon) w/C++ & FORTRAN, w/threadsafe, in production mode FreeBSD/32 6.3 (duty) in debug mode FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode Linux/32 2.6 (kagiso) w/PGI compilers, w/C++ & FORTRAN, w/threadsafe, in debug mode Linux/64-amd64 2.6 (smirom) w/Intel compilers w/default API=1.6.x, w/C++ & FORTRAN, in production mode Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN, w/szip filter, in production mode Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN, in production mode Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in production mode Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode
Diffstat (limited to 'src/H5EAiblock.c')
-rw-r--r--src/H5EAiblock.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/H5EAiblock.c b/src/H5EAiblock.c
index bf3fac4..75c2c85 100644
--- a/src/H5EAiblock.c
+++ b/src/H5EAiblock.c
@@ -123,8 +123,8 @@ H5EA__iblock_alloc(H5EA_hdr_t *hdr))
iblock->addr = HADDR_UNDEF;
/* Compute information */
- iblock->nsblks = 2 * H5V_log2_of2((uint32_t)hdr->sup_blk_min_data_ptrs);
- iblock->ndblk_addrs = 2 * ((size_t)hdr->sup_blk_min_data_ptrs - 1);
+ iblock->nsblks = 2 * H5V_log2_of2((uint32_t)hdr->cparam.sup_blk_min_data_ptrs);
+ iblock->ndblk_addrs = 2 * ((size_t)hdr->cparam.sup_blk_min_data_ptrs - 1);
iblock->nsblk_addrs = hdr->nsblks - iblock->nsblks;
#ifdef QAK
HDfprintf(stderr, "%s: iblock->nsblks = %u\n", FUNC, iblock->nsblks);
@@ -133,8 +133,8 @@ HDfprintf(stderr, "%s: iblock->nsblk_addrs = %Zu\n", FUNC, iblock->nsblk_addrs);
#endif /* QAK */
/* Allocate buffer for elements in index block */
- if(hdr->idx_blk_elmts > 0)
- if(NULL == (iblock->elmts = H5FL_BLK_MALLOC(idx_blk_elmt_buf, (size_t)(hdr->idx_blk_elmts * hdr->cls->nat_elmt_size))))
+ if(hdr->cparam.idx_blk_elmts > 0)
+ if(NULL == (iblock->elmts = H5FL_BLK_MALLOC(idx_blk_elmt_buf, (size_t)(hdr->cparam.idx_blk_elmts * hdr->cparam.cls->nat_elmt_size))))
H5E_THROW(H5E_CANTALLOC, "memory allocation failed for index block data element buffer")
/* Allocate buffer for data block addresses in index block */
@@ -201,13 +201,13 @@ HDfprintf(stderr, "%s: iblock->size = %Zu\n", FUNC, iblock->size);
#endif /* QAK */
/* Allocate space for the index block on disk */
- if(HADDR_UNDEF == (iblock->addr = H5MF_alloc(hdr->f, H5FD_MEM_EARRAY_IBLOCK, dxpl_id, iblock->size)))
+ if(HADDR_UNDEF == (iblock->addr = H5MF_alloc(hdr->f, H5FD_MEM_EARRAY_IBLOCK, dxpl_id, (hsize_t)iblock->size)))
H5E_THROW(H5E_CANTALLOC, "file allocation failed for extensible array index block")
/* Clear any elements in index block to fill value */
- if(hdr->idx_blk_elmts > 0) {
+ if(hdr->cparam.idx_blk_elmts > 0) {
/* Call the class's 'fill' callback */
- if((hdr->cls->fill)(iblock->elmts, (size_t)hdr->idx_blk_elmts) < 0)
+ if((hdr->cparam.cls->fill)(iblock->elmts, (size_t)hdr->cparam.idx_blk_elmts) < 0)
H5E_THROW(H5E_CANTSET, "can't set extensible array index block elements to class's fill value")
} /* end if */
@@ -431,7 +431,7 @@ H5EA__iblock_dest(H5F_t *f, H5EA_iblock_t *iblock))
iblock->hdr->f = f;
/* Check if we've got elements in the index block */
- if(iblock->hdr->idx_blk_elmts > 0) {
+ if(iblock->hdr->cparam.idx_blk_elmts > 0) {
/* Free buffer for index block elements */
HDassert(iblock->elmts);
(void)H5FL_BLK_FREE(idx_blk_elmt_buf, iblock->elmts);