summaryrefslogtreecommitdiffstats
path: root/src/H5Opkg.h
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2007-03-11 23:15:03 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2007-03-11 23:15:03 (GMT)
commite6b818134e24b1d4d99a612218e0a50ffa08bd28 (patch)
tree1f1e5b6b3bd58d92e395762ccfec6ffde5eaee0a /src/H5Opkg.h
parent0b3cccd0cb2521ef77077d677581d2d3342cdc6f (diff)
downloadhdf5-e6b818134e24b1d4d99a612218e0a50ffa08bd28.zip
hdf5-e6b818134e24b1d4d99a612218e0a50ffa08bd28.tar.gz
hdf5-e6b818134e24b1d4d99a612218e0a50ffa08bd28.tar.bz2
[svn-r13497] Description:
Move ref. count of # of links to an object out of the object header's prefix and make it a header message instead (since it's a "rare" occurence), eliminating some more space for each object in the file. Inserting this "ref. count" message exposed a flaw in the library's mechanism for locating a message to promote to another chunk and replace with a continuation message, which required some additional work to fix. It's still not completely robust, but it's working for more cases now and detects failures robustly. Reduced the minimum size of an object header chunk to just enough to contain a header message prefix and continuation message. Tested on: FreeBSD/32 6.2 (duty)
Diffstat (limited to 'src/H5Opkg.h')
-rw-r--r--src/H5Opkg.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/H5Opkg.h b/src/H5Opkg.h
index 0eed076..68a286d 100644
--- a/src/H5Opkg.h
+++ b/src/H5Opkg.h
@@ -29,8 +29,8 @@
/* Object header macros */
#define H5O_NMESGS 8 /*initial number of messages */
#define H5O_NCHUNKS 2 /*initial number of chunks */
-#define H5O_MIN_SIZE 32 /*min obj header data size */
-#define H5O_MSG_TYPES 22 /* # of types of messages */
+#define H5O_MIN_SIZE 22 /* Min. obj header data size (must be big enough for a message prefix and a continuation message) */
+#define H5O_MSG_TYPES 23 /* # of types of messages */
#define H5O_MAX_CRT_ORDER_IDX 65535 /* Max. creation order index value */
/* Versions of object header structure */
@@ -109,7 +109,6 @@
(H5O_SIZEOF_MAGIC + /*magic number */ \
1 + /*version number */ \
1 + /*flags */ \
- 4 + /*reference count */ \
(((O)->flags & H5O_HDR_STORE_TIMES) ? ( \
4 + /*access time */ \
4 + /*modification time */ \
@@ -247,6 +246,7 @@ struct H5O_t {
size_t sizeof_addr; /* Size of file addresses */
/* Object information (stored) */
+ hbool_t has_refcount_msg; /* Whether the object has a ref. count message */
unsigned nlink; /*link count */
uint8_t version; /*version number */
uint8_t flags; /*flags */
@@ -434,6 +434,9 @@ H5_DLLVAR const H5O_msg_class_t H5O_MSG_DRVINFO[1];
/* Attribute Information Message. (0x0015) */
H5_DLLVAR const H5O_msg_class_t H5O_MSG_AINFO[1];
+/* Reference Count Message. (0x0016) */
+H5_DLLVAR const H5O_msg_class_t H5O_MSG_REFCOUNT[1];
+
/*
* Object header "object" types