summaryrefslogtreecommitdiffstats
path: root/src/H5HFcache.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2006-08-14 02:50:11 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2006-08-14 02:50:11 (GMT)
commit89f36d62b776ef955eed82a109b83a187ef115bb (patch)
tree4a8276f4a9ef5e614e9b829931d1094b9346e6d9 /src/H5HFcache.c
parentc4a5b8e16cdf66d1cf4b70587a6747f03557b2ef (diff)
downloadhdf5-89f36d62b776ef955eed82a109b83a187ef115bb.zip
hdf5-89f36d62b776ef955eed82a109b83a187ef115bb.tar.gz
hdf5-89f36d62b776ef955eed82a109b83a187ef115bb.tar.bz2
[svn-r12575] Description:
Allow the heap ID length to be chosen at heap creation time, to allow for making heap IDs long enough to directly embed the file offset & length of 'huge' objects in the heap ID (which allows them to be retrieved directly from disk, instead of requiring them to be looked up in the B-tree that tracks 'huge' objects) Tested on: FreeBSD/32 4.11 (sleipnir) Linux/64 2.4 (mir) Solaris/64 9 (shanti)
Diffstat (limited to 'src/H5HFcache.c')
-rw-r--r--src/H5HFcache.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/H5HFcache.c b/src/H5HFcache.c
index 4915533..e174260 100644
--- a/src/H5HFcache.c
+++ b/src/H5HFcache.c
@@ -309,6 +309,9 @@ HDfprintf(stderr, "%s: Load heap header, addr = %a\n", FUNC, addr);
if(metadata_chksum != 0)
HGOTO_ERROR(H5E_HEAP, H5E_CANTLOAD, NULL, "incorrect metadata checksum for fractal heap header")
+ /* Heap ID length */
+ UINT16DECODE(p, hdr->id_len);
+
/* Heap status flags */
/* (bit 0: "huge" object IDs have wrapped) */
heap_flags = *p++;
@@ -419,6 +422,9 @@ HDfprintf(stderr, "%s: Flushing heap header, addr = %a, destroy = %u\n", FUNC, a
HDmemset(p, 0, (size_t)4);
p += 4;
+ /* Heap ID length */
+ UINT16ENCODE(p, hdr->id_len);
+
/* Heap status flags */
/* (bit 0: "huge" object IDs have wrapped) */
heap_flags = 0;