diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2015-02-17 20:11:39 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2015-02-17 20:11:39 (GMT) |
commit | 85504f53761f96a5903ee176bed25cb3c50d6c54 (patch) | |
tree | 1a17e5252623b17d0af38b616859e0370751f6f7 | |
parent | 595b01658e965b977dd980421cd1bfee27f74dfc (diff) | |
download | hdf5-85504f53761f96a5903ee176bed25cb3c50d6c54.zip hdf5-85504f53761f96a5903ee176bed25cb3c50d6c54.tar.gz hdf5-85504f53761f96a5903ee176bed25cb3c50d6c54.tar.bz2 |
[svn-r26195] Description:
Switch from enum H5D_CHUNK_BTREE to H5D_CHUNK_IDX_BTREE, along with a couple
of minor whitespace touchups.
Tested on:
Mac OSX/64 10.10.2 (amazon) w/serial & parallel
Linux/32 2.6.x (jam) w/serial
-rw-r--r-- | src/H5Dbtree.c | 12 | ||||
-rw-r--r-- | src/H5Dpkg.h | 2 | ||||
-rw-r--r-- | src/H5Dpublic.h | 3 | ||||
-rw-r--r-- | src/H5Olayout.c | 6 | ||||
-rw-r--r-- | src/H5Pdcpl.c | 2 | ||||
-rw-r--r-- | src/H5VM.c | 2 |
6 files changed, 14 insertions, 13 deletions
diff --git a/src/H5Dbtree.c b/src/H5Dbtree.c index 039ebdc..35c2afa 100644 --- a/src/H5Dbtree.c +++ b/src/H5Dbtree.c @@ -195,7 +195,7 @@ H5B_class_t H5B_BTREE[1] = {{ H5D__btree_remove, /*remove */ H5D__btree_decode_key, /*decode */ H5D__btree_encode_key, /*encode */ - H5D__btree_debug_key, /*debug */ + H5D__btree_debug_key /*debug */ }}; @@ -228,7 +228,7 @@ H5D__btree_get_shared(const H5F_t UNUSED *f, const void *_udata) HDassert(udata); HDassert(udata->storage); - HDassert(udata->storage->idx_type == H5D_CHUNK_BTREE); + HDassert(udata->storage->idx_type == H5D_CHUNK_IDX_BTREE); HDassert(udata->storage->u.btree.shared); /* Return the pointer to the ref-count object */ @@ -868,7 +868,7 @@ done: static herr_t H5D__btree_idx_create(const H5D_chk_idx_info_t *idx_info) { - H5D_chunk_common_ud_t udata; /* User data for B-tree callback */ + H5D_chunk_common_ud_t udata; /* User data for B-tree callback */ herr_t ret_value = SUCCEED; /* Return value */ FUNC_ENTER_STATIC @@ -939,7 +939,7 @@ H5D__btree_idx_is_space_alloc(const H5O_storage_chunk_t *storage) static herr_t H5D__btree_idx_insert(const H5D_chk_idx_info_t *idx_info, H5D_chunk_ud_t *udata) { - herr_t ret_value = SUCCEED; /* Return value */ + herr_t ret_value = SUCCEED; /* Return value */ FUNC_ENTER_STATIC @@ -1111,7 +1111,7 @@ H5D__btree_idx_iterate(const H5D_chk_idx_info_t *idx_info, static herr_t H5D__btree_idx_remove(const H5D_chk_idx_info_t *idx_info, H5D_chunk_common_ud_t *udata) { - herr_t ret_value = SUCCEED; /* Return value */ + herr_t ret_value = SUCCEED; /* Return value */ FUNC_ENTER_STATIC @@ -1453,7 +1453,7 @@ H5D_btree_debug(H5F_t *f, hid_t dxpl_id, haddr_t addr, FILE * stream, int indent /* Reset "fake" storage info */ HDmemset(&storage, 0, sizeof(storage)); - storage.idx_type = H5D_CHUNK_BTREE; + storage.idx_type = H5D_CHUNK_IDX_BTREE; /* Allocate the shared structure */ if(H5D__btree_shared_create(f, &storage, ndims) < 0) diff --git a/src/H5Dpkg.h b/src/H5Dpkg.h index 5a785a3..6128d7e 100644 --- a/src/H5Dpkg.h +++ b/src/H5Dpkg.h @@ -362,7 +362,7 @@ typedef struct H5D_chunk_map_t { } H5D_chunk_map_t; /* Cached information about a particular chunk */ -typedef struct H5D_chunk_cached_t{ +typedef struct H5D_chunk_cached_t { hbool_t valid; /*whether cache info is valid*/ hsize_t offset[H5O_LAYOUT_NDIMS]; /*logical offset to start*/ uint32_t nbytes; /*size of stored data */ diff --git a/src/H5Dpublic.h b/src/H5Dpublic.h index e7ae3ae..1b5fed7 100644 --- a/src/H5Dpublic.h +++ b/src/H5Dpublic.h @@ -56,7 +56,8 @@ typedef enum H5D_layout_t { /* Types of chunk index data structures */ typedef enum H5D_chunk_index_t { - H5D_CHUNK_BTREE = 0 /* v1 B-tree index */ + H5D_CHUNK_IDX_BTREE = 0, /* v1 B-tree index */ + H5D_CHUNK_IDX_NTYPES /* this one must be last! */ } H5D_chunk_index_t; /* Values for the space allocation time property */ diff --git a/src/H5Olayout.c b/src/H5Olayout.c index 4c43873..816242f 100644 --- a/src/H5Olayout.c +++ b/src/H5Olayout.c @@ -147,7 +147,7 @@ H5O_layout_decode(H5F_t *f, hid_t UNUSED dxpl_id, H5O_t UNUSED *open_oh, /* Set the chunk operations */ /* (Only "btree" indexing type currently supported in this version) */ - mesg->storage.u.chunk.idx_type = H5D_CHUNK_BTREE; + mesg->storage.u.chunk.idx_type = H5D_CHUNK_IDX_BTREE; mesg->storage.u.chunk.ops = H5D_COPS_BTREE; } /* end if */ else { @@ -234,7 +234,7 @@ H5O_layout_decode(H5F_t *f, hid_t UNUSED dxpl_id, H5O_t UNUSED *open_oh, /* Set the chunk operations */ /* (Only "btree" indexing type supported with v3 of message format) */ - mesg->storage.u.chunk.idx_type = H5D_CHUNK_BTREE; + mesg->storage.u.chunk.idx_type = H5D_CHUNK_IDX_BTREE; mesg->storage.u.chunk.ops = H5D_COPS_BTREE; /* Set the layout operations */ @@ -715,7 +715,7 @@ H5O_layout_debug(H5F_t UNUSED *f, hid_t UNUSED dxpl_id, const void *_mesg, /* Index information */ switch(mesg->storage.u.chunk.idx_type) { - case H5D_CHUNK_BTREE: + case H5D_CHUNK_IDX_BTREE: HDfprintf(stream, "%*s%-*s %s\n", indent, "", fwidth, "Index Type:", "v1 B-tree"); HDfprintf(stream, "%*s%-*s %a\n", indent, "", fwidth, diff --git a/src/H5Pdcpl.c b/src/H5Pdcpl.c index a753209..949cefa 100644 --- a/src/H5Pdcpl.c +++ b/src/H5Pdcpl.c @@ -53,7 +53,7 @@ /* Define default layout information */ #define H5D_DEF_STORAGE_COMPACT_INIT {(hbool_t)FALSE, (size_t)0, NULL} #define H5D_DEF_STORAGE_CONTIG_INIT {HADDR_UNDEF, (hsize_t)0} -#define H5D_DEF_STORAGE_CHUNK_INIT {H5D_CHUNK_BTREE, HADDR_UNDEF, NULL, {{HADDR_UNDEF, NULL}}} +#define H5D_DEF_STORAGE_CHUNK_INIT {H5D_CHUNK_IDX_BTREE, HADDR_UNDEF, NULL, {{HADDR_UNDEF, NULL}}} #define H5D_DEF_LAYOUT_CHUNK_INIT {(unsigned)0, {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, (uint32_t)0, (hsize_t)0, {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}} #ifdef H5_HAVE_C99_DESIGNATED_INITIALIZER #define H5D_DEF_STORAGE_COMPACT {H5D_COMPACT, { .compact = H5D_DEF_STORAGE_COMPACT_INIT }} @@ -1089,7 +1089,7 @@ H5VM_array_offset_pre(unsigned n, const hsize_t *acc, const hsize_t *offset) HDassert(offset); /* Compute offset in array */ - for (i=(int)(n-1), ret_value=0; i>=0; --i) + for(i = (int)(n - 1), ret_value = 0; i >= 0; --i) ret_value += acc[i] * offset[i]; FUNC_LEAVE_NOAPI(ret_value) |