summaryrefslogtreecommitdiffstats
path: root/test/earray.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2009-03-26 22:06:57 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2009-03-26 22:06:57 (GMT)
commit383f266ef1df526ea3ebeadd1b49099361ada7a9 (patch)
treea2246a7cffcdfdb362e914b09a9c63730f357ee0 /test/earray.c
parentf842a26c63ffe3fa24e6ab031f49c1aafcbc6ad2 (diff)
downloadhdf5-383f266ef1df526ea3ebeadd1b49099361ada7a9.zip
hdf5-383f266ef1df526ea3ebeadd1b49099361ada7a9.tar.gz
hdf5-383f266ef1df526ea3ebeadd1b49099361ada7a9.tar.bz2
[svn-r16623] Description:
Revise how code for array statistics works. Tested on: FreeBSD/32 6.3 (duty) in debug mode FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode Linux/32 2.6 (jam) 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 Mac OS X/32 10.5.6 (amazon) in debug mode Mac OS X/32 10.5.6 (amazon) w/C++ & FORTRAN, w/threadsafe, in production mode
Diffstat (limited to 'test/earray.c')
-rw-r--r--test/earray.c44
1 files changed, 22 insertions, 22 deletions
diff --git a/test/earray.c b/test/earray.c
index 7b68e95..cccb5a0 100644
--- a/test/earray.c
+++ b/test/earray.c
@@ -312,51 +312,51 @@ check_stats(const H5EA_t *ea, const earray_state_t *state)
FAIL_STACK_ERROR
/* Compare information */
- if(earray_stats.max_idx_set != state->max_idx_set) {
- HDfprintf(stdout, "earray_stats.max_idx_set = %Hu, state->max_idx_set = %Hu\n", earray_stats.max_idx_set, state->max_idx_set);
+ if(earray_stats.stored.max_idx_set != state->max_idx_set) {
+ HDfprintf(stdout, "earray_stats.stored.max_idx_set = %Hu, state->max_idx_set = %Hu\n", earray_stats.stored.max_idx_set, state->max_idx_set);
TEST_ERROR
} /* end if */
- if(earray_stats.nelmts != state->nelmts) {
- HDfprintf(stdout, "earray_stats.nelmts = %Hu, state->nelmts = %Hu\n", earray_stats.nelmts, state->nelmts);
+ if(earray_stats.stored.nelmts != state->nelmts) {
+ HDfprintf(stdout, "earray_stats.stored.nelmts = %Hu, state->nelmts = %Hu\n", earray_stats.stored.nelmts, state->nelmts);
TEST_ERROR
} /* end if */
- if(earray_stats.hdr_size != state->hdr_size) {
- HDfprintf(stdout, "earray_stats.hdr_size = %Hu, state->hdr_size = %Hu\n", earray_stats.hdr_size, state->hdr_size);
+ if(earray_stats.computed.hdr_size != state->hdr_size) {
+ HDfprintf(stdout, "earray_stats.computed.hdr_size = %Hu, state->hdr_size = %Hu\n", earray_stats.computed.hdr_size, state->hdr_size);
TEST_ERROR
} /* end if */
- if(earray_stats.nindex_blks != state->nindex_blks) {
- HDfprintf(stdout, "earray_stats.nindex_blks = %Hu, state->nindex_blks = %Hu\n", earray_stats.nindex_blks, state->nindex_blks);
+ if(earray_stats.computed.nindex_blks != state->nindex_blks) {
+ HDfprintf(stdout, "earray_stats.computed.nindex_blks = %Hu, state->nindex_blks = %Hu\n", earray_stats.computed.nindex_blks, state->nindex_blks);
TEST_ERROR
} /* end if */
- if(earray_stats.index_blk_size != state->index_blk_size) {
- HDfprintf(stdout, "earray_stats.index_blk_size = %Hu, state->index_blk_size = %Hu\n", earray_stats.index_blk_size, state->index_blk_size);
+ if(earray_stats.computed.index_blk_size != state->index_blk_size) {
+ HDfprintf(stdout, "earray_stats.computed.index_blk_size = %Hu, state->index_blk_size = %Hu\n", earray_stats.computed.index_blk_size, state->index_blk_size);
TEST_ERROR
} /* end if */
- if(earray_stats.ndata_blks != state->ndata_blks) {
- HDfprintf(stdout, "earray_stats.ndata_blks = %Hu, state->ndata_blks = %Hu\n", earray_stats.ndata_blks, state->ndata_blks);
+ if(earray_stats.stored.ndata_blks != state->ndata_blks) {
+ HDfprintf(stdout, "earray_stats.stored.ndata_blks = %Hu, state->ndata_blks = %Hu\n", earray_stats.stored.ndata_blks, state->ndata_blks);
TEST_ERROR
} /* end if */
/* Don't compare this currently, it's very hard to compute */
#ifdef NOT_YET
- if(earray_stats.data_blk_size != state->data_blk_size) {
- HDfprintf(stdout, "earray_stats.data_blk_size = %Hu, state->data_blk_size = %Hu\n", earray_stats.data_blk_size, state->data_blk_size);
+ if(earray_stats.stored.data_blk_size != state->data_blk_size) {
+ HDfprintf(stdout, "earray_stats.stored.data_blk_size = %Hu, state->data_blk_size = %Hu\n", earray_stats.stored.data_blk_size, state->data_blk_size);
TEST_ERROR
} /* end if */
#endif /* NOT_YET */
- if(earray_stats.nsuper_blks != state->nsuper_blks) {
- HDfprintf(stdout, "earray_stats.nsuper_blks = %Hu, state->nsuper_blks = %Hu\n", earray_stats.nsuper_blks, state->nsuper_blks);
+ if(earray_stats.stored.nsuper_blks != state->nsuper_blks) {
+ HDfprintf(stdout, "earray_stats.stored.nsuper_blks = %Hu, state->nsuper_blks = %Hu\n", earray_stats.stored.nsuper_blks, state->nsuper_blks);
TEST_ERROR
} /* end if */
/* Don't compare this currently, it's very hard to compute */
#ifdef NOT_YET
- if(earray_stats.super_blk_size != state->super_blk_size) {
- HDfprintf(stdout, "earray_stats.super_blk_size = %Hu, state->super_blk_size = %Hu\n", earray_stats.super_blk_size, state->super_blk_size);
+ if(earray_stats.stored.super_blk_size != state->super_blk_size) {
+ HDfprintf(stdout, "earray_stats.stored.super_blk_size = %Hu, state->super_blk_size = %Hu\n", earray_stats.stored.super_blk_size, state->super_blk_size);
TEST_ERROR
} /* end if */
#endif /* NOT_YET */
#ifdef QAK
-HDfprintf(stderr, "nelmts = %Hu, total EA size = %Hu\n", earray_stats.nelmts,
- (earray_stats.hdr_size + earray_stats.index_blk_size + earray_stats.super_blk_size + earray_stats.data_blk_size));
+HDfprintf(stderr, "nelmts = %Hu, total EA size = %Hu\n", earray_stats.stored.nelmts,
+ (earray_stats.computed.hdr_size + earray_stats.computed.index_blk_size + earray_stats.stored.super_blk_size + earray_stats.stored.data_blk_size));
#endif /* QAK */
/* All tests passed */
@@ -1198,7 +1198,7 @@ eiter_fw_state(void *_eiter, const H5EA_create_t *cparam,
/* Compute the state of the extensible array */
state->hdr_size = EA_HDR_SIZE;
state->nindex_blks = 1;
- state->index_blk_size = 298;
+ state->index_blk_size = EA_IBLOCK_SIZE;
state->max_idx_set = idx + 1;
if(idx < cparam->idx_blk_elmts) {
state->nelmts = (hsize_t)cparam->idx_blk_elmts;
@@ -1416,7 +1416,7 @@ eiter_rv_state(void *_eiter, const H5EA_create_t *cparam,
/* Compute the state of the extensible array */
state->hdr_size = EA_HDR_SIZE;
state->nindex_blks = 1;
- state->index_blk_size = 298;
+ state->index_blk_size = EA_IBLOCK_SIZE;
state->max_idx_set = eiter->max + 1;
if(eiter->max < cparam->idx_blk_elmts) {
state->nelmts = (hsize_t)cparam->idx_blk_elmts;