diff options
author | Dana Robinson <derobins@hdfgroup.org> | 2021-05-07 02:48:58 (GMT) |
---|---|---|
committer | Dana Robinson <derobins@hdfgroup.org> | 2021-05-07 02:48:58 (GMT) |
commit | 7a5b440fa89538b94088cc89a1188aef27033e74 (patch) | |
tree | 2ee57d411d75cf7b74595722a5653e0842e6db68 /test/fheap.c | |
parent | f2cb86499efa2fe6f44ca2f4e93ea62e952d0fb0 (diff) | |
download | hdf5-7a5b440fa89538b94088cc89a1188aef27033e74.zip hdf5-7a5b440fa89538b94088cc89a1188aef27033e74.tar.gz hdf5-7a5b440fa89538b94088cc89a1188aef27033e74.tar.bz2 |
Brings H5Z and many test changes from develop
Diffstat (limited to 'test/fheap.c')
-rw-r--r-- | test/fheap.c | 1853 |
1 files changed, 861 insertions, 992 deletions
diff --git a/test/fheap.c b/test/fheap.c index e8cde89..cb9c080 100644 --- a/test/fheap.c +++ b/test/fheap.c @@ -69,20 +69,22 @@ /* #define ALL_INSERT_TESTS */ /* Heap metadata macros */ -#define MAX_HEAP_ID_LEN 64 /* Max. # of bytes to use for heap ID */ -#define HEAP_ID_LEN 7 /* # of bytes to use for heap ID */ -#define SMALL_HEAP_ID_LEN 7 /* # of bytes to use for "small" heap's IDs */ -#define LARGE_HEAP_ID_LEN 12 /* # of bytes to use for "large" heap's IDs */ -#define HEAP_MAX_ROOT_ROWS(fh) H5HF_get_max_root_rows(fh) /* Max. # of rows in root indirect block */ -#define DTABLE_WIDTH(fh) H5HF_get_dtable_width_test(fh) /* Width of doubling table for heap */ -#define DTABLE_MAX_DROWS(fh) \ - H5HF_get_dtable_max_drows_test(fh) /* Max. # of direct block rows in any indirect block */ -#define IBLOCK_MAX_DROWS(fh, pos) \ - H5HF_get_iblock_max_drows_test(fh, pos) /* Max. # of direct block rows in a indirect block */ -#define DBLOCK_SIZE(fh, r) H5HF_get_dblock_size_test(fh, r) /* Size of a direct block in a given row */ -#define DBLOCK_FREE(fh, r) \ - H5HF_get_dblock_free_test(fh, r) /* Free space in a direct block of a given row \ - */ +#define MAX_HEAP_ID_LEN 64 /* Max. # of bytes to use for heap ID */ +#define HEAP_ID_LEN 7 /* # of bytes to use for heap ID */ +#define SMALL_HEAP_ID_LEN 7 /* # of bytes to use for "small" heap's IDs */ +#define LARGE_HEAP_ID_LEN 12 /* # of bytes to use for "large" heap's IDs */ +/* Max. # of rows in root indirect block */ +#define HEAP_MAX_ROOT_ROWS(fh) H5HF_get_max_root_rows(fh) +/* Width of doubling table for heap */ +#define DTABLE_WIDTH(fh) H5HF_get_dtable_width_test(fh) +/* Max. # of direct block rows in any indirect block */ +#define DTABLE_MAX_DROWS(fh) H5HF_get_dtable_max_drows_test(fh) +/* Max. # of direct block rows in a indirect block */ +#define IBLOCK_MAX_DROWS(fh, pos) H5HF_get_iblock_max_drows_test(fh, pos) +/* Size of a direct block in a given row */ +#define DBLOCK_SIZE(fh, r) H5HF_get_dblock_size_test(fh, r) +/* Free space in a direct block of a given row */ +#define DBLOCK_FREE(fh, r) H5HF_get_dblock_free_test(fh, r) /* The number of settings for testing: page buffering, file space strategy and persisting free-space */ #define NUM_PB_FS 6 @@ -176,16 +178,16 @@ static int del_objs(H5F_t *f, H5HF_t **fh, fheap_test_param_t *tparam, fheap_hea fheap_heap_ids_t *keep_ids); /*------------------------------------------------------------------------- - * Function: init_small_cparam + * Function: init_small_cparam * - * Purpose: Initialize heap creation parameter structure with small + * Purpose: Initialize heap creation parameter structure with small * settings * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 21, 2006 * *------------------------------------------------------------------------- @@ -212,16 +214,16 @@ init_small_cparam(H5HF_create_t *cparam) } /* init_small_cparam() */ /*------------------------------------------------------------------------- - * Function: init_large_cparam + * Function: init_large_cparam * - * Purpose: Initialize heap creation parameter structure with large + * Purpose: Initialize heap creation parameter structure with large * settings * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 21, 2006 * *------------------------------------------------------------------------- @@ -248,15 +250,15 @@ init_large_cparam(H5HF_create_t *cparam) } /* init_large_cparam() */ /*------------------------------------------------------------------------- - * Function: check_stats + * Function: check_stats * - * Purpose: Verify stats for a heap + * Purpose: Verify stats for a heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 6, 2006 * *------------------------------------------------------------------------- @@ -270,43 +272,45 @@ check_stats(const H5HF_t *fh, const fheap_heap_state_t *state) if (H5HF_stat_info(fh, &heap_stats) < 0) FAIL_STACK_ERROR if (heap_stats.man_nobjs != state->man_nobjs) { - HDfprintf(stdout, "heap_stats.man_nobjs = %Hu, state->man_nobjs = %Zu\n", heap_stats.man_nobjs, - state->man_nobjs); + HDfprintf(stdout, "heap_stats.man_nobjs = %" PRIuHSIZE ", state->man_nobjs = %zu\n", + heap_stats.man_nobjs, state->man_nobjs); TEST_ERROR } /* end if */ if (heap_stats.man_size != state->man_size) { - HDfprintf(stdout, "heap_stats.man_size = %Hu, state->man_size = %Hu\n", heap_stats.man_size, - state->man_size); + HDfprintf(stdout, "heap_stats.man_size = %" PRIuHSIZE ", state->man_size = %" PRIuHSIZE "\n", + heap_stats.man_size, state->man_size); TEST_ERROR } /* end if */ if (heap_stats.man_alloc_size != state->man_alloc_size) { - HDfprintf(stdout, "heap_stats.man_alloc_size = %Hu, state->man_alloc_size = %Hu\n", + HDfprintf(stdout, + "heap_stats.man_alloc_size = %" PRIuHSIZE ", state->man_alloc_size = %" PRIuHSIZE "\n", heap_stats.man_alloc_size, state->man_alloc_size); TEST_ERROR } /* end if */ if (heap_stats.man_free_space != state->man_free_space) { - HDfprintf(stdout, "heap_stats.man_free_space = %Hu, state->man_free_space = %Hu\n", + HDfprintf(stdout, + "heap_stats.man_free_space = %" PRIuHSIZE ", state->man_free_space = %" PRIuHSIZE "\n", heap_stats.man_free_space, state->man_free_space); TEST_ERROR } /* end if */ if (heap_stats.huge_nobjs != state->huge_nobjs) { - HDfprintf(stdout, "heap_stats.huge_nobjs = %Hu, state->huge_nobjs = %Zu\n", heap_stats.huge_nobjs, - state->huge_nobjs); + HDfprintf(stdout, "heap_stats.huge_nobjs = %" PRIuHSIZE ", state->huge_nobjs = %zu\n", + heap_stats.huge_nobjs, state->huge_nobjs); TEST_ERROR } /* end if */ if (heap_stats.huge_size != state->huge_size) { - HDfprintf(stdout, "heap_stats.huge_size = %Hu, state->huge_size = %Hu\n", heap_stats.huge_size, - state->huge_size); + HDfprintf(stdout, "heap_stats.huge_size = %" PRIuHSIZE ", state->huge_size = %" PRIuHSIZE "\n", + heap_stats.huge_size, state->huge_size); TEST_ERROR } /* end if */ if (heap_stats.tiny_nobjs != state->tiny_nobjs) { - HDfprintf(stdout, "heap_stats.tiny_nobjs = %Hu, state->tiny_nobjs = %Zu\n", heap_stats.tiny_nobjs, - state->tiny_nobjs); + HDfprintf(stdout, "heap_stats.tiny_nobjs = %" PRIuHSIZE ", state->tiny_nobjs = %zu\n", + heap_stats.tiny_nobjs, state->tiny_nobjs); TEST_ERROR } /* end if */ if (heap_stats.tiny_size != state->tiny_size) { - HDfprintf(stdout, "heap_stats.tiny_size = %Hu, state->tiny_size = %Hu\n", heap_stats.tiny_size, - state->tiny_size); + HDfprintf(stdout, "heap_stats.tiny_size = %" PRIuHSIZE ", state->tiny_size = %" PRIuHSIZE "\n", + heap_stats.tiny_size, state->tiny_size); TEST_ERROR } /* end if */ @@ -318,15 +322,15 @@ error: } /* check_stats() */ /*------------------------------------------------------------------------- - * Function: op_memcpy + * Function: op_memcpy * - * Purpose: Perform 'memcpy' for an object + * Purpose: Perform 'memcpy' for an object * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, September 11, 2006 * *------------------------------------------------------------------------- @@ -341,9 +345,9 @@ op_memcpy(const void *obj, size_t obj_len, void *op_data) } /* op_memcpy() */ /*------------------------------------------------------------------------- - * Function: add_obj + * Function: add_obj * - * Purpose: Add an object to heap + * Purpose: Add an object to heap * * Note: The following fields in the 'state' structure are set to * the values expected _after_ any block created for the object: @@ -355,11 +359,11 @@ op_memcpy(const void *obj, size_t obj_len, void *op_data) * the current state, before any block has been created: * nobjs * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -420,7 +424,7 @@ add_obj(H5HF_t *fh, size_t obj_off, size_t obj_size, fheap_heap_state_t *state, TEST_ERROR if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(obj, shared_robj_g, obj_size)) + if (HDmemcmp(obj, shared_robj_g, obj_size) != 0) TEST_ERROR /* If the heap IDs are to be retained, append them to the list */ @@ -463,15 +467,15 @@ error: } /* add_obj() */ /*------------------------------------------------------------------------- - * Function: get_del_string + * Function: get_del_string * - * Purpose: Return string describing the kind of deletion to perform + * Purpose: Return string describing the kind of deletion to perform * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, June 6, 2006 * *------------------------------------------------------------------------- @@ -499,14 +503,14 @@ get_del_string(const fheap_test_param_t *tparam) } /* get_del_string() */ /*------------------------------------------------------------------------- - * Function: get_fill_size + * Function: get_fill_size * - * Purpose: Retrieve the size of objects to "bulk" fill blocks with + * Purpose: Retrieve the size of objects to "bulk" fill blocks with * - * Return: Size of object to pass down to "fill_heap" routine on + * Return: Size of object to pass down to "fill_heap" routine on * success/can't fail * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Thursday, July 27, 2006 * *------------------------------------------------------------------------- @@ -530,15 +534,15 @@ get_fill_size(const fheap_test_param_t *tparam) } /* get_fill_size() */ /*------------------------------------------------------------------------- - * Function: begin_test + * Function: begin_test * - * Purpose: Perform common "test being" operations + * Purpose: Perform common "test being" operations * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 4, 2006 * *------------------------------------------------------------------------- @@ -561,8 +565,11 @@ begin_test(fheap_test_param_t *tparam, const char *base_desc, fheap_heap_ids_t * */ del_str = get_del_string(tparam); HDassert(del_str); - TESTING(base_desc, del_str); + test_desc = (char *)H5MM_malloc(HDstrlen(del_str) + HDstrlen(base_desc)); + HDsprintf(test_desc, base_desc, del_str); + TESTING(test_desc); H5MM_xfree(del_str); + H5MM_xfree(test_desc); /* Initialize the heap ID structure */ HDmemset(keep_ids, 0, sizeof(fheap_heap_ids_t)); @@ -577,14 +584,14 @@ begin_test(fheap_test_param_t *tparam, const char *base_desc, fheap_heap_ids_t * H5_GCC_DIAG_ON("format-nonliteral") /*------------------------------------------------------------------------- - * Function: reopen_file + * Function: reopen_file * - * Purpose: Perform common "re-open" operations on file & heap for testing + * Purpose: Perform common "re-open" operations on file & heap for testing * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 18, 2006 * *------------------------------------------------------------------------- @@ -632,15 +639,15 @@ error: } /* end reopen_file() */ /*------------------------------------------------------------------------- - * Function: open_heap + * Function: open_heap * - * Purpose: Perform common "open" operations on file & heap for testing + * Purpose: Perform common "open" operations on file & heap for testing * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 4, 2006 * *------------------------------------------------------------------------- @@ -743,15 +750,15 @@ error: } /* end open_heap() */ /*------------------------------------------------------------------------- - * Function: reopen_heap + * Function: reopen_heap * - * Purpose: Perform common "re-open" operations on heap for testing + * Purpose: Perform common "re-open" operations on heap for testing * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 4, 2006 * *------------------------------------------------------------------------- @@ -779,14 +786,14 @@ error: } /* end reopen_heap() */ /*------------------------------------------------------------------------- - * Function: close_heap + * Function: close_heap * - * Purpose: Perform common "close" operations on file & heap for testing + * Purpose: Perform common "close" operations on file & heap for testing * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 4, 2006 * *------------------------------------------------------------------------- @@ -844,15 +851,15 @@ error: } /* end close_heap() */ /*------------------------------------------------------------------------- - * Function: del_objs_half_refill + * Function: del_objs_half_refill * - * Purpose: Remove half of objects from heap and refill + * Purpose: Remove half of objects from heap and refill * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, June 6, 2006 * *------------------------------------------------------------------------- @@ -936,15 +943,15 @@ error: } /* del_objs_half_refill() */ /*------------------------------------------------------------------------- - * Function: del_objs + * Function: del_objs * - * Purpose: Remove objects from heap + * Purpose: Remove objects from heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, June 6, 2006 * *------------------------------------------------------------------------- @@ -1017,9 +1024,9 @@ error: } /* del_objs() */ /*------------------------------------------------------------------------- - * Function: fill_heap + * Function: fill_heap * - * Purpose: Insert (small) objects to fill up the free space in a heap block + * Purpose: Insert (small) objects to fill up the free space in a heap block * * Note: The following fields in the 'state' structure are set to * the values expected _after_ the block has been created: @@ -1031,11 +1038,11 @@ error: * the current state, before the block has been created: * nobjs * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 7, 2006 * *------------------------------------------------------------------------- @@ -1185,7 +1192,7 @@ fill_heap(H5HF_t *fh, unsigned block_row, size_t obj_size, fheap_heap_state_t *s /* Check that object is correct */ wobj = &shared_wobj_g[*curr_off_ptr]; - if (HDmemcmp(wobj, shared_robj_g, *curr_len_ptr)) + if (HDmemcmp(wobj, shared_robj_g, *curr_len_ptr) != 0) TEST_ERROR /* Adjust object & ID pointers */ @@ -1227,15 +1234,15 @@ error: } /* fill_heap() */ /*------------------------------------------------------------------------- - * Function: fill_root_row + * Function: fill_root_row * - * Purpose: Fill up a row of direct blocks in the root indirect block + * Purpose: Fill up a row of direct blocks in the root indirect block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1323,15 +1330,15 @@ error: } /* fill_root_row() */ /*------------------------------------------------------------------------- - * Function: fill_partial row + * Function: fill_partial row * - * Purpose: Fill up part of a row of direct blocks in an non-root indirect block + * Purpose: Fill up part of a row of direct blocks in an non-root indirect block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, July 11, 2006 * *------------------------------------------------------------------------- @@ -1368,15 +1375,15 @@ error: } /* fill_partial_row() */ /*------------------------------------------------------------------------- - * Function: fill_row + * Function: fill_row * - * Purpose: Fill up entire row of direct blocks in an non-root indirect block + * Purpose: Fill up entire row of direct blocks in an non-root indirect block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1400,18 +1407,18 @@ error: } /* fill_row() */ /*------------------------------------------------------------------------- - * Function: fill_root_direct + * Function: fill_root_direct * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in the root indirect block * (Generally used to create & fill up direct blocks in a new * indirect block) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 3, 2006 * *------------------------------------------------------------------------- @@ -1439,17 +1446,17 @@ error: } /* fill_root_direct() */ /*------------------------------------------------------------------------- - * Function: fill_2nd_indirect + * Function: fill_2nd_indirect * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in a second-level indirect block (which only has * direct blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1478,16 +1485,16 @@ error: } /* fill_2nd_direct() */ /*------------------------------------------------------------------------- - * Function: fill_all_direct + * Function: fill_all_direct * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks up to the maximum direct block size * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1515,17 +1522,17 @@ error: } /* fill_all_direct() */ /*------------------------------------------------------------------------- - * Function: fill_2nd_indirect_row + * Function: fill_2nd_indirect_row * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in a row of second-level indirect block (which only * have direct blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1553,17 +1560,17 @@ error: } /* fill_2nd_direct_row() */ /*------------------------------------------------------------------------- - * Function: fill_all_2nd_indirect_rows + * Function: fill_all_2nd_indirect_rows * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in all rows of second-level indirect blocks (which only * have direct blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1590,17 +1597,17 @@ error: } /* fill_2nd_direct_row() */ /*------------------------------------------------------------------------- - * Function: fill_3rd_indirect + * Function: fill_3rd_indirect * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in a third-level indirect block (which * has one more level of indirect blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, April 18, 2006 * *------------------------------------------------------------------------- @@ -1628,17 +1635,17 @@ error: } /* fill_3rd_indirect() */ /*------------------------------------------------------------------------- - * Function: fill_3rd_indirect_row + * Function: fill_3rd_indirect_row * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in a row of third-level indirect block (which * have one more level of indirect blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1667,17 +1674,17 @@ error: } /* fill_3rd_direct_row() */ /*------------------------------------------------------------------------- - * Function: fill_all_3rd_indirect_rows + * Function: fill_all_3rd_indirect_rows * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in all rows of third-level indirect blocks (which * have one more level of indirect blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1705,17 +1712,17 @@ error: } /* fill_all_3rd_direct_rows() */ /*------------------------------------------------------------------------- - * Function: fill_4th_indirect_row + * Function: fill_4th_indirect_row * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in a row of fourth-level indirect blocks (which * have two more levels of indirect blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1754,17 +1761,17 @@ error: } /* fill_4th_direct_row() */ /*------------------------------------------------------------------------- - * Function: fill_all_4th_indirect_rows + * Function: fill_all_4th_indirect_rows * - * Purpose: Insert (small) objects to fill up the free space in all direct + * Purpose: Insert (small) objects to fill up the free space in all direct * heap blocks in all rows of fourth-level indirect blocks (which * have two more levels of indirect blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 10, 2006 * *------------------------------------------------------------------------- @@ -1810,14 +1817,14 @@ error: } /* fill_all_4th_direct_rows() */ /*------------------------------------------------------------------------- - * Function: test_create + * Function: test_create * - * Purpose: Create fractal heap + * Purpose: Create fractal heap * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, February 24, 2006 * *------------------------------------------------------------------------- @@ -1929,14 +1936,14 @@ error: } /* test_create() */ /*------------------------------------------------------------------------- - * Function: test_reopen + * Function: test_reopen * - * Purpose: Create & reopen a fractal heap + * Purpose: Create & reopen a fractal heap * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, April 18, 2006 * *------------------------------------------------------------------------- @@ -2082,14 +2089,14 @@ error: } /* test_reopen() */ /*------------------------------------------------------------------------- - * Function: test_open_twice + * Function: test_open_twice * - * Purpose: Open a fractal heap twice + * Purpose: Open a fractal heap twice * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 18, 2006 * *------------------------------------------------------------------------- @@ -2260,14 +2267,14 @@ error: } /* test_open_twice() */ /*------------------------------------------------------------------------- - * Function: test_delete_open + * Function: test_delete_open * - * Purpose: Delete opened fractal heap (& open deleted heap) + * Purpose: Delete opened fractal heap (& open deleted heap) * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, January 5, 2007 * *------------------------------------------------------------------------- @@ -2438,14 +2445,14 @@ error: } /* test_delete_open() */ /*------------------------------------------------------------------------- - * Function: test_id_limits + * Function: test_id_limits * - * Purpose: Test limits for heap ID lengths + * Purpose: Test limits for heap ID lengths * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, August 14, 2006 * *------------------------------------------------------------------------- @@ -2776,14 +2783,14 @@ error: } /* test_id_limits() */ /*------------------------------------------------------------------------- - * Function: test_filtered_create + * Function: test_filtered_create * - * Purpose: Test creating a heap with I/O filters + * Purpose: Test creating a heap with I/O filters * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, August 14, 2006 * *------------------------------------------------------------------------- @@ -2898,14 +2905,14 @@ error: } /* test_filtered_create() */ /*------------------------------------------------------------------------- - * Function: test_size + * Function: test_size * - * Purpose: Test querying heap size + * Purpose: Test querying heap size * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, August 14, 2007 * *------------------------------------------------------------------------- @@ -3171,17 +3178,15 @@ error: return (1); } /* test_reopen_hdr() */ -#ifndef QAK2 - /*------------------------------------------------------------------------- - * Function: test_man_insert_weird + * Function: test_man_insert_weird * - * Purpose: Test inserting "weird" sized objects into absolute heap + * Purpose: Test inserting "weird" sized objects into absolute heap * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 18, 2006 * *------------------------------------------------------------------------- @@ -3288,15 +3293,15 @@ error: #ifdef ALL_INSERT_TESTS /*------------------------------------------------------------------------- - * Function: test_man_insert_first + * Function: test_man_insert_first * - * Purpose: Test inserting first object into absolute heap + * Purpose: Test inserting first object into absolute heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, February 24, 2006 * *------------------------------------------------------------------------- @@ -3389,15 +3394,15 @@ error: } /* test_man_insert_first() */ /*------------------------------------------------------------------------- - * Function: test_man_insert_second + * Function: test_man_insert_second * - * Purpose: Test inserting two objects into absolute heap + * Purpose: Test inserting two objects into absolute heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 6, 2006 * *------------------------------------------------------------------------- @@ -3484,16 +3489,16 @@ error: } /* test_man_insert_second() */ /*------------------------------------------------------------------------- - * Function: test_man_insert_root_mult + * Function: test_man_insert_root_mult * - * Purpose: Test inserting mult. objects into absolute heap, up to the + * Purpose: Test inserting mult. objects into absolute heap, up to the * limit of a root direct block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 6, 2006 * *------------------------------------------------------------------------- @@ -3582,17 +3587,17 @@ error: } /* test_man_insert_root_mult() */ /*------------------------------------------------------------------------- - * Function: test_man_insert_force_indirect + * Function: test_man_insert_force_indirect * - * Purpose: Test inserting mult. objects into absolute heap, filling the + * Purpose: Test inserting mult. objects into absolute heap, filling the * root direct block and forcing the root block to be converted * into an indirect block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 6, 2006 * *------------------------------------------------------------------------- @@ -3688,17 +3693,17 @@ error: } /* test_man_insert_force_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_insert_fill_second + * Function: test_man_insert_fill_second * - * Purpose: Test inserting mult. objects into absolute heap, filling the + * Purpose: Test inserting mult. objects into absolute heap, filling the * root direct block, forcing the root block to be converted * into an indirect block and filling the secnod indirect block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 7, 2006 * *------------------------------------------------------------------------- @@ -3794,18 +3799,18 @@ error: } /* test_man_insert_fill_second() */ /*------------------------------------------------------------------------- - * Function: test_man_insert_third_direct + * Function: test_man_insert_third_direct * - * Purpose: Test inserting mult. objects into absolute heap, filling the + * Purpose: Test inserting mult. objects into absolute heap, filling the * root direct block, forcing the root block to be converted * into an indirect block, filling the secnod indirect block and * creating a third direct block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 7, 2006 * *------------------------------------------------------------------------- @@ -3906,17 +3911,17 @@ error: } /* test_man_insert_third_direct() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_first_row + * Function: test_man_fill_first_row * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill first row of root indirect * block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 13, 2006 * *------------------------------------------------------------------------- @@ -4002,17 +4007,17 @@ error: } /* test_man_fill_first_row() */ /*------------------------------------------------------------------------- - * Function: test_man_start_second_row + * Function: test_man_start_second_row * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill first row of root indirect * block, then add another object to start second row. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 14, 2006 * *------------------------------------------------------------------------- @@ -4105,17 +4110,17 @@ error: } /* test_man_start_second_row() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_second_row + * Function: test_man_fill_second_row * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill first row of root indirect * block, then fill the second row also. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 14, 2006 * *------------------------------------------------------------------------- @@ -4205,18 +4210,18 @@ error: } /* test_man_fill_second_row() */ /*------------------------------------------------------------------------- - * Function: test_man_start_third_row + * Function: test_man_start_third_row * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill first row of root indirect * block, fill the second row also, then add another object to * start the third row. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 20, 2006 * *------------------------------------------------------------------------- @@ -4316,17 +4321,17 @@ error: } /* test_man_start_third_row() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_fourth_row + * Function: test_man_fill_fourth_row * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill first four rows of root indirect * block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 20, 2006 * *------------------------------------------------------------------------- @@ -4414,17 +4419,17 @@ error: } /* test_man_fill_fourth_row() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_all_root_direct + * Function: test_man_fill_all_root_direct * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 20, 2006 * *------------------------------------------------------------------------- @@ -4510,17 +4515,17 @@ error: } /* test_man_fill_all_root_direct() */ /*------------------------------------------------------------------------- - * Function: test_man_first_recursive_indirect + * Function: test_man_first_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block and create first recursive indirect block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 20, 2006 * *------------------------------------------------------------------------- @@ -4611,18 +4616,18 @@ error: } /* test_man_first_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_second_direct_recursive_indirect + * Function: test_man_second_direct_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, create first recursive indirect block and start second * direct block in that indirect block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 21, 2006 * *------------------------------------------------------------------------- @@ -4721,18 +4726,18 @@ error: } /* test_man_second_direct_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_first_recursive_indirect + * Function: test_man_fill_first_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, create first recursive indirect block and filling all * direct blocks in that indirect block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 21, 2006 * *------------------------------------------------------------------------- @@ -4823,19 +4828,19 @@ error: } /* test_man_fill_first_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_second_recursive_indirect + * Function: test_man_second_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, create first recursive indirect block, filling all * direct blocks in that indirect block and adding another * object to force creation of second recursive indirect block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 21, 2006 * *------------------------------------------------------------------------- @@ -4933,20 +4938,20 @@ error: } /* test_man_second_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_second_recursive_indirect + * Function: test_man_fill_second_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, create first recursive indirect block, filling all * direct blocks in that indirect block and then create second * recursive indirect block and fill all direct blocks in that * indirect block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 21, 2006 * *------------------------------------------------------------------------- @@ -5041,20 +5046,20 @@ error: } /* test_man_fill_second_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_recursive_indirect_row + * Function: test_man_fill_recursive_indirect_row * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, create first recursive indirect block, filling all * direct blocks in that indirect block and then create second * recursive indirect block and fill all direct blocks in that * indirect block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 21, 2006 * *------------------------------------------------------------------------- @@ -5141,18 +5146,18 @@ error: } /* test_man_fill_recursive_indirect_row() */ /*------------------------------------------------------------------------- - * Function: test_man_start_2nd_recursive_indirect + * Function: test_man_start_2nd_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the first row of indirect * blocks and start on first block in second row of indirect blocks * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -5250,18 +5255,18 @@ error: } /* test_man_start_2nd_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_recursive_indirect_two_deep + * Function: test_man_recursive_indirect_two_deep * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -5352,19 +5357,19 @@ error: } /* test_man_recursive_indirect_two_deep() */ /*------------------------------------------------------------------------- - * Function: test_man_start_3rd_recursive_indirect + * Function: test_man_start_3rd_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep and start first direct block * in 3rd level of indirect blocks * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -5462,19 +5467,19 @@ error: } /* test_man_start_3rd_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_first_3rd_recursive_indirect + * Function: test_man_fill_first_3rd_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep and fill first indirect block * in 3rd level of indirect blocks * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -5573,19 +5578,19 @@ error: } /* test_man_fill_first_3rd_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_3rd_recursive_indirect_row + * Function: test_man_fill_3rd_recursive_indirect_row * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep and fill all indirect blocks * first row of 3rd level of indirect blocks * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -5681,19 +5686,19 @@ error: } /* test_man_fill_3rd_recursive_indirect_row() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_all_3rd_recursive_indirect + * Function: test_man_fill_all_3rd_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep and fill all indirect blocks * that are three levels deep * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -5789,20 +5794,20 @@ error: } /* test_man_fill_all_3rd_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_start_4th_recursive_indirect + * Function: test_man_start_4th_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep, fill all indirect blocks * that are three levels deep and start first direct block that * is four levels deep * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -5904,20 +5909,20 @@ error: } /* test_man_start_4th_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_first_4th_recursive_indirect + * Function: test_man_fill_first_4th_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep, fill all indirect blocks * that are three levels deep and fill the first (3rd level) * indirect block that is four levels deep * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -6025,20 +6030,20 @@ error: } /* test_man_fill_first_4th_recursive_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_4th_recursive_indirect_row + * Function: test_man_fill_4th_recursive_indirect_row * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep, fill all indirect blocks * that are three levels deep and fill the first row of * indirect block that is four levels deep * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -6137,20 +6142,20 @@ error: } /* test_man_fill_4th_recursive_indirect_row() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_all_4th_recursive_indirect + * Function: test_man_fill_all_4th_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep, fill all indirect blocks * that are three levels deep and fill all rows of * indirect blocks that are four levels deep * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -6249,12 +6254,10 @@ error: } /* test_man_fill_all_4th_recursive_indirect() */ #endif /* ALL_INSERT_TESTS */ -#ifndef QAK - /*------------------------------------------------------------------------- - * Function: test_man_start_5th_recursive_indirect + * Function: test_man_start_5th_recursive_indirect * - * Purpose: Test inserting mult. objects into absolute heap, creating + * Purpose: Test inserting mult. objects into absolute heap, creating * enough direct blocks to fill all direct rows of root indirect * block, fill all direct blocks in the row of indirect * blocks that are 2 levels deep, fill all indirect blocks @@ -6262,11 +6265,11 @@ error: * that are four levels deep and start first direct block in * indirect blocks five levels deep * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -6383,20 +6386,17 @@ error: H5E_END_TRY; return (1); } /* test_man_start_5th_recursive_indirect() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_man_remove_bogus + * Function: test_man_remove_bogus * - * Purpose: Test removing bogus heap IDs + * Purpose: Test removing bogus heap IDs * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, May 15, 2006 * *------------------------------------------------------------------------- @@ -6462,10 +6462,10 @@ test_man_remove_bogus(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpa /* Choose random # seed */ seed = (unsigned long)HDtime(NULL); -#ifdef QAK - /* seed = (unsigned long)1155438845; */ - HDfprintf(stderr, "Random # seed was: %lu\n", seed); -#endif /* QAK */ +#if 0 +/* seed = (unsigned long)1155438845; */ +HDfprintf(stderr, "Random # seed was: %lu\n", seed); +#endif HDsrandom((unsigned)seed); /* Set heap ID to random (non-null) value */ @@ -6548,15 +6548,15 @@ error: } /* test_man_remove_bogus() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_one + * Function: test_man_remove_one * - * Purpose: Test removing single object from heap + * Purpose: Test removing single object from heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, May 15, 2006 * *------------------------------------------------------------------------- @@ -6712,15 +6712,15 @@ error: } /* test_man_remove_one() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_two + * Function: test_man_remove_two * - * Purpose: Test removing two objects from heap + * Purpose: Test removing two objects from heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, May 22, 2006 * *------------------------------------------------------------------------- @@ -6905,16 +6905,16 @@ error: } /* test_man_remove_two() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_one_larger + * Function: test_man_remove_one_larger * - * Purpose: Test removing single larger (but < standalone size) object + * Purpose: Test removing single larger (but < standalone size) object * from heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, June 6, 2006 * *------------------------------------------------------------------------- @@ -7074,16 +7074,16 @@ error: } /* test_man_remove_one_larger() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_two_larger + * Function: test_man_remove_two_larger * - * Purpose: Test removing two larger (but < standalone size) objects + * Purpose: Test removing two larger (but < standalone size) objects * from heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Saturday, June 10, 2006 * *------------------------------------------------------------------------- @@ -7293,11 +7293,7 @@ test_man_remove_two_larger(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR - /* Verify the file is correct size */ -#ifdef QAK - HDfprintf(stderr, "empty_size = %lu\n", (unsigned long)empty_size); - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ + /* Verify the file is correct size */ if (file_size != empty_size) TEST_ERROR @@ -7318,16 +7314,16 @@ error: } /* test_man_remove_two_larger() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_three_larger + * Function: test_man_remove_three_larger * - * Purpose: Test removing three larger (but < standalone size) objects + * Purpose: Test removing three larger (but < standalone size) objects * from heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, June 12, 2006 * *------------------------------------------------------------------------- @@ -7597,11 +7593,7 @@ test_man_remove_three_larger(hid_t fapl, H5HF_create_t *cparam, fheap_test_param if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR - /* Verify the file is correct size */ -#ifdef QAK - HDfprintf(stderr, "empty_size = %lu\n", (unsigned long)empty_size); - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ + /* Verify the file is correct size */ if (file_size != empty_size) TEST_ERROR @@ -7622,14 +7614,14 @@ error: } /* test_man_remove_three_larger() */ /*------------------------------------------------------------------------- - * Function: test_man_incr_insert_remove + * Function: test_man_incr_insert_remove * - * Purpose: Test incremental insert & removal of objects in heap + * Purpose: Test incremental insert & removal of objects in heap * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Sunday, April 1, 2012 * *------------------------------------------------------------------------- @@ -7748,21 +7740,18 @@ error: return 1; } /* test_man_incr_insert_remove() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_man_remove_root_direct + * Function: test_man_remove_root_direct * - * Purpose: Test filling and removing all objects from root direct block in + * Purpose: Test filling and removing all objects from root direct block in * heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, May 22, 2006 * *------------------------------------------------------------------------- @@ -7779,8 +7768,8 @@ test_man_remove_root_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_ h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "removing all objects from root direct block of absolute heap %s"; /* Test description */ + /* Test description */ + const char *base_desc = "removing all objects from root direct block of absolute heap %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -7826,16 +7815,16 @@ error: } /* test_man_remove_root_direct() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_two_direct + * Function: test_man_remove_two_direct * - * Purpose: Test filling and removing all objects from (first) two direct + * Purpose: Test filling and removing all objects from (first) two direct * blocks in heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, May 22, 2006 * *------------------------------------------------------------------------- @@ -7852,8 +7841,8 @@ test_man_remove_two_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "removing all objects from two direct blocks of absolute heap %s"; /* Test description */ + /* Test description */ + const char *base_desc = "removing all objects from two direct blocks of absolute heap %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -7914,16 +7903,16 @@ error: } /* test_man_remove_two_direct() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_first_row + * Function: test_man_remove_first_row * - * Purpose: Test filling and removing all objects from first row of direct + * Purpose: Test filling and removing all objects from first row of direct * blocks in heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, June 5, 2006 * *------------------------------------------------------------------------- @@ -7940,8 +7929,8 @@ test_man_remove_first_row(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "removing all objects from first row of direct blocks of absolute heap %s"; /* Test description */ + /* Test description */ + const char *base_desc = "removing all objects from first row of direct blocks of absolute heap %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -7984,16 +7973,16 @@ error: } /* test_man_remove_first_row() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_first_two_rows + * Function: test_man_remove_first_two_rows * - * Purpose: Test filling and removing all objects from first two rows of + * Purpose: Test filling and removing all objects from first two rows of * direct blocks in heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, June 12, 2006 * *------------------------------------------------------------------------- @@ -8010,9 +7999,8 @@ test_man_remove_first_two_rows(hid_t fapl, H5HF_create_t *cparam, fheap_test_par h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "removing all objects from first two rows of direct blocks of absolute heap %s"; /* Test description - */ + /* Test description */ + const char *base_desc = "removing all objects from first two rows of direct blocks of absolute heap %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -8057,16 +8045,16 @@ error: } /* test_man_remove_first_two_rows() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_first_four_rows + * Function: test_man_remove_first_four_rows * - * Purpose: Test filling and removing all objects from first four rows of + * Purpose: Test filling and removing all objects from first four rows of * direct blocks in heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, June 13, 2006 * *------------------------------------------------------------------------- @@ -8083,9 +8071,8 @@ test_man_remove_first_four_rows(hid_t fapl, H5HF_create_t *cparam, fheap_test_pa h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "removing all objects from first four rows of direct blocks of absolute heap %s"; /* Test description - */ + /* Test description */ + const char *base_desc = "removing all objects from first four rows of direct blocks of absolute heap %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -8134,16 +8121,16 @@ error: } /* test_man_remove_first_four_rows() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_all_root_direct + * Function: test_man_remove_all_root_direct * - * Purpose: Test filling and removing all objects from all direct blocks + * Purpose: Test filling and removing all objects from all direct blocks * in root indirect block of heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, June 13, 2006 * *------------------------------------------------------------------------- @@ -8160,9 +8147,8 @@ test_man_remove_all_root_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_pa h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "removing all objects from all direct blocks of root group in absolute heap %s"; /* Test description - */ + /* Test description */ + const char *base_desc = "removing all objects from all direct blocks of root group in absolute heap %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -8205,16 +8191,16 @@ error: } /* test_man_remove_all_root_direct() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_2nd_indirect + * Function: test_man_remove_2nd_indirect * - * Purpose: Test filling and removing all objects up to 2nd level indirect + * Purpose: Test filling and removing all objects up to 2nd level indirect * blocks of heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, June 13, 2006 * *------------------------------------------------------------------------- @@ -8231,8 +8217,8 @@ test_man_remove_2nd_indirect(hid_t fapl, H5HF_create_t *cparam, fheap_test_param h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "removing all objects from 2nd level indirect blocks of absolute heap %s"; /* Test description */ + /* Test description */ + const char *base_desc = "removing all objects from 2nd level indirect blocks of absolute heap %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -8279,16 +8265,16 @@ error: } /* test_man_remove_2nd_indirect() */ /*------------------------------------------------------------------------- - * Function: test_man_remove_3rd_indirect + * Function: test_man_remove_3rd_indirect * - * Purpose: Test filling and removing all objects up to 3rd level indirect + * Purpose: Test filling and removing all objects up to 3rd level indirect * blocks of heap * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, July 24, 2006 * *------------------------------------------------------------------------- @@ -8305,8 +8291,8 @@ test_man_remove_3rd_indirect(hid_t fapl, H5HF_create_t *cparam, fheap_test_param h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "removing all objects from 3rd level indirect blocks of absolute heap %s"; /* Test description */ + /* Test description */ + const char *base_desc = "removing all objects from 3rd level indirect blocks of absolute heap %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -8355,24 +8341,21 @@ error: H5E_END_TRY; return (1); } /* test_man_remove_3rd_indirect() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_man_skip_start_block + * Function: test_man_skip_start_block * - * Purpose: Test inserting object into absolute heap which is too large + * Purpose: Test inserting object into absolute heap which is too large * for starting block size, which forces root indirect block * creation * * Then, remove all the objects, in various ways * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, March 27, 2006 * *------------------------------------------------------------------------- @@ -8389,9 +8372,9 @@ test_man_skip_start_block(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t obj_size; /* Size of object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "inserting object that is too large for starting block, then remove all objects %s"; /* Test - description */ + /* Test description */ + const char *base_desc = + "inserting object that is too large for starting block, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -8441,17 +8424,17 @@ error: } /* test_man_skip_start_block() */ /*------------------------------------------------------------------------- - * Function: test_man_skip_start_block_add_back + * Function: test_man_skip_start_block_add_back * - * Purpose: Test inserting object into absolute heap which is too large + * Purpose: Test inserting object into absolute heap which is too large * for starting block size, which forces root indirect block * creation, then add object which fits in skipped direct block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 28, 2006 * *------------------------------------------------------------------------- @@ -8468,10 +8451,9 @@ test_man_skip_start_block_add_back(hid_t fapl, H5HF_create_t *cparam, fheap_test h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t obj_size; /* Size of object */ fheap_heap_state_t state; /* State of fractal heap */ - const char *base_desc = "skipping starting block, then adding object back to first block, then remove " - "all objects %s"; /* Test - description - */ + /* Test description */ + const char *base_desc = + "skipping starting block, then adding object back to first block, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -8540,18 +8522,18 @@ error: } /* test_man_skip_start_block_add_back() */ /*------------------------------------------------------------------------- - * Function: test_man_skip_start_block_add_skipped + * Function: test_man_skip_start_block_add_skipped * - * Purpose: Test inserting object into absolute heap which is too large + * Purpose: Test inserting object into absolute heap which is too large * for starting block size, which forces root indirect block * creation, then add objects to fill skipped direct blocks * and add another object to start on next "normal" block * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, March 28, 2006 * *------------------------------------------------------------------------- @@ -8569,8 +8551,9 @@ test_man_skip_start_block_add_skipped(hid_t fapl, H5HF_create_t *cparam, fheap_t size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char *base_desc = "skipping starting block, then adding objects to backfill and extend, then " - "remove all objects %s"; /* Test description */ + /* Test description */ + const char *base_desc = + "skipping starting block, then adding objects to backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -8649,18 +8632,18 @@ error: } /* test_man_skip_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_skip_2nd_block + * Function: test_man_skip_2nd_block * - * Purpose: Test inserting object into absolute heap which is small + * Purpose: Test inserting object into absolute heap which is small * enough for starting block size, then add object too large * for any blocks in first row of direct blocks, to force * early creation of indirect block (and range of skipped blocks) * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Saturday, April 1, 2006 * *------------------------------------------------------------------------- @@ -8677,8 +8660,9 @@ test_man_skip_2nd_block(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *t h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t obj_size; /* Size of object */ fheap_heap_state_t state; /* State of fractal heap */ + /* Test description */ const char *base_desc = "insert object to initial block, then add object too large for starting direct " - "blocks, then remove all objects %s"; /* Test description */ + "blocks, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -8742,9 +8726,9 @@ error: } /* test_man_skip_2nd_block() */ /*------------------------------------------------------------------------- - * Function: test_man_skip_2nd_block_add_skipped + * Function: test_man_skip_2nd_block_add_skipped * - * Purpose: Test inserting object into absolute heap which is small + * Purpose: Test inserting object into absolute heap which is small * enough for starting block size, then add object too large * for any blocks in first row of direct blocks, to force * early creation of indirect block (and range of skipped blocks). @@ -8752,11 +8736,11 @@ error: * block and all the skipped blocks, and one more object (to * start next "normal" block). * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Saturday, April 1, 2006 * *------------------------------------------------------------------------- @@ -8774,10 +8758,10 @@ test_man_skip_2nd_block_add_skipped(hid_t fapl, H5HF_create_t *cparam, fheap_tes size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "insert object to initial block, then add object too large for starting direct blocks, then backfill " - "and extend, then remove all objects %s"; /* Test description */ - unsigned v; /* Local index variables */ + unsigned v; /* Local index variables */ + /* Test description */ + const char *base_desc = "insert object to initial block, then add object too large for starting direct " + "blocks, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -8885,9 +8869,9 @@ error: } /* test_man_skip_2nd_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_one_partial_skip_2nd_block_add_skipped + * Function: test_man_fill_one_partial_skip_2nd_block_add_skipped * - * Purpose: Test filling initial direct block, then add object small enough + * Purpose: Test filling initial direct block, then add object small enough * for initial block size (to create root indirect block), then * add object too large for any blocks in first three rows of * direct blocks, to force extension of indirect block (and range @@ -8897,11 +8881,11 @@ error: * block and all the skipped blocks, and one more object (to * start next "normal" block). * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 3, 2006 * *------------------------------------------------------------------------- @@ -8920,11 +8904,10 @@ test_man_fill_one_partial_skip_2nd_block_add_skipped(hid_t fapl, H5HF_create_t * size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char *base_desc = "skipping blocks with indirect root, then backfill and extend, then remove all " - "objects %s"; /* Test - description - */ - unsigned u; /* Local index variable */ + unsigned u; /* Local index variable */ + /* Test description */ + const char *base_desc = + "skipping blocks with indirect root, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -9054,9 +9037,9 @@ error: } /* test_man_fill_one_partial_skip_2nd_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_row_skip_add_skipped + * Function: test_man_fill_row_skip_add_skipped * - * Purpose: Test filling first row of direct blocks, then + * Purpose: Test filling first row of direct blocks, then * add object too large for any blocks in first three rows of * direct blocks, to force extension of indirect block (and range * of skipped blocks). @@ -9065,11 +9048,11 @@ error: * block and all the skipped blocks, and one more object (to * start next "normal" block). * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, May 15, 2006 * *------------------------------------------------------------------------- @@ -9087,10 +9070,9 @@ test_man_fill_row_skip_add_skipped(hid_t fapl, H5HF_create_t *cparam, fheap_test size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char *base_desc = "filling first row, then skipping rows, then backfill and extend, then remove " - "all objects %s"; /* Test - description - */ + /* Test description */ + const char *base_desc = + "filling first row, then skipping rows, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -9185,19 +9167,19 @@ error: } /* test_man_fill_row_skip_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_skip_direct_skip_indirect_two_rows_add_skipped + * Function: test_man_skip_direct_skip_indirect_two_rows_add_skipped * - * Purpose: Test adding object too large for all but the last row in the + * Purpose: Test adding object too large for all but the last row in the * direct blocks in root indirect block, then * add object too large for initial block in first two rows of * indirect blocks, to force extension of non-root * indirect block (and range of skipped blocks). * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Saturday, April 15, 2006 * *------------------------------------------------------------------------- @@ -9217,10 +9199,10 @@ test_man_skip_direct_skip_indirect_two_rows_add_skipped(hid_t fapl, H5HF_create_ h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t obj_size; /* Size of object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "skipping direct blocks to last row and skipping two rows of root indirect block, then backfill and " - "extend, then remove all objects %s"; /* Test description */ - unsigned v; /* Local index variables */ + unsigned v; /* Local index variables */ + /* Test description */ + const char *base_desc = "skipping direct blocks to last row and skipping two rows of root indirect " + "block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -9314,18 +9296,18 @@ error: } /* test_man_skip_direct_skip_indirect_two_rows_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_direct_skip_indirect_start_block_add_skipped + * Function: test_man_fill_direct_skip_indirect_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block, then + * Purpose: Test filling all direct blocks in root indirect block, then * add object too large for initial block in first row of direct * blocks in indirect block, to force extension of non-root * indirect block (and range of skipped blocks). * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 3, 2006 * *------------------------------------------------------------------------- @@ -9344,8 +9326,9 @@ test_man_fill_direct_skip_indirect_start_block_add_skipped(hid_t fapl, H5HF_crea size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ + /* Test description */ const char *base_desc = "filling direct blocks and skipping blocks in non-root indirect block, then " - "backfill and extend, then remove all objects %s"; /* Test description */ + "backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -9437,19 +9420,19 @@ error: } /* test_man_fill_direct_skip_indirect_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_direct_skip_2nd_indirect_start_block_add_skipped + * Function: test_man_fill_direct_skip_2nd_indirect_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block, then + * Purpose: Test filling all direct blocks in root indirect block, then * add object too large for all direct blocks in first row of * indirect blocks, to force skipping a row of indirect blocks * (and range of skipped blocks), then backfill all direct blocks * skipped and extend to next "normal" direct block. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 3, 2006 * *------------------------------------------------------------------------- @@ -9464,16 +9447,17 @@ test_man_fill_direct_skip_2nd_indirect_start_block_add_skipped(hid_t fapl, H5HF_ H5HF_t * fh = NULL; /* Fractal heap wrapper */ haddr_t fh_addr; /* Address of fractal heap */ fheap_heap_ids_t keep_ids; /* Structure to retain heap IDs */ - unsigned - num_first_indirect_rows; /* Number of rows (of direct blocks) in each of the first indirect blocks */ - unsigned row; /* Current row in indirect block */ - h5_stat_size_t empty_size; /* Size of a file with an empty heap */ - size_t obj_size; /* Size of object */ - size_t fill_size; /* Size of objects for "bulk" filled blocks */ - fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = "filling direct blocks and skipping row of non-root indirect blocks, then " - "backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u; /* Local index variable */ + unsigned num_first_indirect_rows; /* Number of rows (of direct blocks) in each of the */ + /* first indirect blocks */ + unsigned row; /* Current row in indirect block */ + h5_stat_size_t empty_size; /* Size of a file with an empty heap */ + size_t obj_size; /* Size of object */ + size_t fill_size; /* Size of objects for "bulk" filled blocks */ + fheap_heap_state_t state; /* State of fractal heap */ + unsigned u; /* Local index variable */ + /* Test description */ + const char *base_desc = "filling direct blocks and skipping row of non-root indirect blocks, then " + "backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -9567,20 +9551,20 @@ error: } /* test_man_fill_direct_skip_2nd_indirect_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_2nd_direct_less_one_wrap_start_block_add_skipped + * Function: test_man_fill_2nd_direct_less_one_wrap_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, except the last * one, then insert object insert object that is too large to * hold in row of 2nd level indirect blocks (forcing the use of * the next row of 2nd level blocks), then backfill all skipped * direct blocks & extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, April 18, 2006 * *------------------------------------------------------------------------- @@ -9601,13 +9585,11 @@ test_man_fill_2nd_direct_less_one_wrap_start_block_add_skipped(hid_t fapl, H5HF_ size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, except last one, and " - "insert object too " - "large for 2nd level indirect blocks, then backfill and extend, then remove all " - "objects %s"; /* Test - description - */ - unsigned u; /* Local index variables */ + unsigned u; /* Local index variables */ + /* Test description */ + const char *base_desc = + "filling direct blocks, filling 2nd level indirect blocks, except last one, and insert object too " + "large for 2nd level indirect blocks, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -9643,9 +9625,6 @@ test_man_fill_2nd_direct_less_one_wrap_start_block_add_skipped(hid_t fapl, H5HF_ * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -9715,9 +9694,9 @@ error: } /* test_man_fill_2nd_direct_less_one_wrap_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_direct_skip_2nd_indirect_skip_2nd_block_add_skipped + * Function: test_man_fill_direct_skip_2nd_indirect_skip_2nd_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block, then + * Purpose: Test filling all direct blocks in root indirect block, then * add object too large for all direct blocks in first row of * indirect blocks, to force skipping a row of indirect blocks * (and range of skipped blocks), then add object that is too @@ -9727,11 +9706,11 @@ error: * too large for initial block size in skipped indirect block * row's direct blocks). * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, April 11, 2006 * *------------------------------------------------------------------------- @@ -9753,10 +9732,10 @@ test_man_fill_direct_skip_2nd_indirect_skip_2nd_block_add_skipped(hid_t fapl, H5 size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "filling direct blocks and skipping row of non-root indirect blocks, then skip row of direct blocks, " - "then backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u; /* Local index variable */ + unsigned u; /* Local index variable */ + /* Test description */ + const char *base_desc = "filling direct blocks and skipping row of non-root indirect blocks, then skip " + "row of direct blocks, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -9782,9 +9761,6 @@ test_man_fill_direct_skip_2nd_indirect_skip_2nd_block_add_skipped(hid_t fapl, H5 * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -9804,9 +9780,6 @@ test_man_fill_direct_skip_2nd_indirect_skip_2nd_block_add_skipped(hid_t fapl, H5 /* Insert object too large for initial block size in skipped indirect blocks */ obj_size = (size_t)DBLOCK_SIZE(fh, 3) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, 4); if (add_obj(fh, (size_t)10, obj_size, &state, &keep_ids)) TEST_ERROR @@ -9817,9 +9790,6 @@ test_man_fill_direct_skip_2nd_indirect_skip_2nd_block_add_skipped(hid_t fapl, H5 /* Insert object to fill space in (medium) block just created */ obj_size = (size_t)DBLOCK_FREE(fh, 4) - obj_size; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -9892,18 +9862,18 @@ error: } /* test_man_fill_direct_skip_2nd_indirect_skip_2nd_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_direct_skip_indirect_two_rows_add_skipped + * Function: test_man_fill_direct_skip_indirect_two_rows_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block, then + * Purpose: Test filling all direct blocks in root indirect block, then * add object too large for initial block in first two rows of * indirect blocks, to force extension of non-root * indirect block (and range of skipped blocks). * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Saturday, April 15, 2006 * *------------------------------------------------------------------------- @@ -9925,9 +9895,10 @@ test_man_fill_direct_skip_indirect_two_rows_add_skipped(hid_t fapl, H5HF_create_ size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = "filling direct blocks and skipping two rows of root indirect block, then " - "backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "filling direct blocks and skipping two rows of root indirect block, then " + "backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -10045,20 +10016,20 @@ error: } /* test_man_fill_direct_skip_indirect_two_rows_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_direct_skip_indirect_two_rows_skip_indirect_row_add_skipped + * Function: test_man_fill_direct_skip_indirect_two_rows_skip_indirect_row_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block, then + * Purpose: Test filling all direct blocks in root indirect block, then * add object too large for initial block in first two rows of * indirect blocks, to force extension of non-root * indirect block, then add object too large for first row of * indirect blocks, (and ranges of skipped blocks), then backfill * and extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, July 11, 2006 * *------------------------------------------------------------------------- @@ -10080,10 +10051,11 @@ test_man_fill_direct_skip_indirect_two_rows_skip_indirect_row_add_skipped(hid_t size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "filling direct blocks and skipping two rows of root indirect block, skip one row of root indirect " - "block, then backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + "block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -10229,19 +10201,19 @@ error: } /* test_man_fill_direct_skip_indirect_two_rows_skip_indirect_row_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_2nd_direct_skip_start_block_add_skipped + * Function: test_man_fill_2nd_direct_skip_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, the insert object * that is too large to hold in first row of direct blocks of * 3rd level indirect block, then backfill & extend all skipped * 3rd level indirect block's direct blocks. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, April 11, 2006 * *------------------------------------------------------------------------- @@ -10260,10 +10232,10 @@ test_man_fill_2nd_direct_skip_start_block_add_skipped(hid_t fapl, H5HF_create_t size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = + /* Test description */ + const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, and skip first rows of direct blocks of " - "3rd level indirect block, then backfill and extend, then remove all objects %s"; /* Test description - */ + "3rd level indirect block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -10358,9 +10330,9 @@ error: } /* test_man_fill_2nd_direct_skip_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_2nd_direct_skip_2nd_indirect_start_block_add_skipped + * Function: test_man_fill_2nd_direct_skip_2nd_indirect_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, fill all direct * blocks in 3rd level indirect block, then insert object * that is too large to hold in first row of direct blocks of @@ -10368,11 +10340,11 @@ error: * backfill & extend all skipped 2nd level indirect block's direct * blocks. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, April 11, 2006 * *------------------------------------------------------------------------- @@ -10391,10 +10363,11 @@ test_man_fill_2nd_direct_skip_2nd_indirect_start_block_add_skipped(hid_t fapl, H size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = + /* Test description */ + const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level indirect block's direct " "blocks, and skip first rows of direct blocks of 3rd level indirect block's 2nd level indirect " - "block, then backfill and extend, then remove all objects %s"; /* Test description */ + "block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -10499,20 +10472,20 @@ error: } /* test_man_fill_2nd_direct_skip_2nd_indirect_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_block_add_skipped + * Function: test_man_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, fill all direct * blocks in 3rd level indirect block, then insert object * that is too large to hold in first row of 2nd level indirect * blocks of 3rd level indirect block, then backfill & extend all * skipped direct blocks. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, April 11, 2006 * *------------------------------------------------------------------------- @@ -10534,11 +10507,11 @@ test_man_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_block_add_skipped(h size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level indirect block's direct " - "blocks, and skip first row of indirect blocks of 3rd level indirect block, then backfill and " - "extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level " + "indirect block's direct blocks, and skip first row of indirect blocks of 3rd " + "level indirect block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -10580,9 +10553,6 @@ test_man_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_block_add_skipped(h * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -10654,21 +10624,21 @@ error: } /* test_man_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_2nd_direct_fill_direct_skip2_3rd_indirect_start_block_add_skipped + * Function: test_man_fill_2nd_direct_fill_direct_skip2_3rd_indirect_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, fill all direct * blocks in 3rd level indirect block, then insert object * that is too large to hold in first & second rows of 2nd level * indirect blocks (although this 3rd level indirect block only * has one row of 2nd level indirect blocks) of 3rd level indirect - * block, then backfill & extend all skipped direct blocks. + * block, then backfill & extend all skipped direct blocks. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, April 11, 2006 * *------------------------------------------------------------------------- @@ -10690,11 +10660,11 @@ test_man_fill_2nd_direct_fill_direct_skip2_3rd_indirect_start_block_add_skipped( size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level indirect block's direct " - "blocks, and skip first two rows of indirect blocks of 3rd level indirect block, then backfill and " - "extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level " + "indirect block's direct blocks, and skip first two rows of indirect blocks of " + "3rd level indirect block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -10706,9 +10676,6 @@ test_man_fill_2nd_direct_fill_direct_skip2_3rd_indirect_start_block_add_skipped( /* Retrieve info about heap */ num_first_indirect_rows = IBLOCK_MAX_DROWS(fh, 1); -#ifdef QAK - HDfprintf(stderr, "num_first_indirect_rows = %u\n", num_first_indirect_rows); -#endif /* QAK */ /* Fill direct blocks in root indirect block */ if (fill_root_direct(fh, fill_size, &state, &keep_ids)) @@ -10739,9 +10706,6 @@ test_man_fill_2nd_direct_fill_direct_skip2_3rd_indirect_start_block_add_skipped( * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows + 1); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -10752,9 +10716,6 @@ test_man_fill_2nd_direct_fill_direct_skip2_3rd_indirect_start_block_add_skipped( /* Insert object to fill space in (large) block created */ obj_size = (size_t)DBLOCK_FREE(fh, num_first_indirect_rows + 1) - obj_size; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -10820,9 +10781,9 @@ error: } /* test_man_fill_2nd_direct_fill_direct_skip2_3rd_indirect_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_3rd_direct_less_one_fill_direct_wrap_start_block_add_skipped + * Function: test_man_fill_3rd_direct_less_one_fill_direct_wrap_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, all 3rd level * indirect blocks in first row except the last one, fill direct * blocks in last 3rd level indirect block, then insert object @@ -10831,11 +10792,11 @@ error: * use of the next row of 3rd level blocks), then backfill all * skipped direct blocks & extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tues, April 18, 2006 * *------------------------------------------------------------------------- @@ -10856,12 +10817,12 @@ test_man_fill_3rd_direct_less_one_fill_direct_wrap_start_block_add_skipped(hid_t size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "filling direct blocks, filling 2nd level indirect blocks, filling first row of 3rd " - "level indirect blocks, except last one, fill all direct blocks in last 3rd level " - "indirect block, and insert object too large for it's 2nd level indirect blocks, then " - "backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = + "filling direct blocks, filling 2nd level indirect blocks, filling first row of 3rd level indirect " + "blocks, except last one, fill all direct blocks in last 3rd level indirect block, and insert object " + "too large for it's 2nd level indirect blocks, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -10913,9 +10874,6 @@ test_man_fill_3rd_direct_less_one_fill_direct_wrap_start_block_add_skipped(hid_t * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -10986,9 +10944,9 @@ error: } /* test_man_fill_3rd_direct_less_one_fill_direct_wrap_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_1st_row_3rd_direct_fill_2nd_direct_less_one_wrap_start_block_add_skipped + * Function: test_man_fill_1st_row_3rd_direct_fill_2nd_direct_less_one_wrap_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, all 3rd level * indirect blocks in first row, fill direct blocks in 2nd row 3rd * level indirect block, fill all direct blocks in 1st row of @@ -10998,11 +10956,11 @@ error: * next row of 2nd level blocks), then backfill all skipped direct * blocks & extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tues, April 18, 2006 * *------------------------------------------------------------------------- @@ -11019,16 +10977,16 @@ test_man_fill_1st_row_3rd_direct_fill_2nd_direct_less_one_wrap_start_block_add_s fheap_heap_ids_t keep_ids; /* Structure to retain heap IDs */ unsigned num_first_indirect_rows; /* Number of rows (of direct blocks) in each of the first indirect blocks */ - h5_stat_size_t empty_size; /* Size of a file with an empty heap */ - size_t obj_size; /* Size of object */ - size_t fill_size; /* Size of objects for "bulk" filled blocks */ - fheap_heap_state_t state; /* State of fractal heap */ + h5_stat_size_t empty_size; /* Size of a file with an empty heap */ + size_t obj_size; /* Size of object */ + size_t fill_size; /* Size of objects for "bulk" filled blocks */ + fheap_heap_state_t state; /* State of fractal heap */ + unsigned u; /* Local index variables */ /* Test description */ const char * base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling first row of 3rd level indirect " "blocks, fill all direct blocks in next 3rd level indirect block, fill all 1st row of 2nd level " "indirect blocks, except last one, and insert object too large for 2nd level indirect block, then " - "backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u; /* Local index variables */ + "backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -11087,9 +11045,6 @@ test_man_fill_1st_row_3rd_direct_fill_2nd_direct_less_one_wrap_start_block_add_s * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -11159,9 +11114,9 @@ error: } /* test_man_fill_1st_row_3rd_direct_fill_2nd_direct_less_one_wrap_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_3rd_direct_fill_direct_skip_start_block_add_skipped + * Function: test_man_fill_3rd_direct_fill_direct_skip_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, fill all direct * blocks and indirect blocks in 3rd level indirect block, then * fill all direct blocks in 4th level indirect block, then @@ -11169,11 +11124,11 @@ error: * level indirect blocks of 4th level indirect block, then * backfill all skipped direct blocks & extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Saturday, April 15, 2006 * *------------------------------------------------------------------------- @@ -11194,11 +11149,12 @@ test_man_fill_3rd_direct_fill_direct_skip_start_block_add_skipped(hid_t fapl, H5 size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level indirect blocks, fill " "4th level indirect block's direct blocks, and skip first row of 2nd indirect blocks of 4th level " - "indirect block, then backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + "indirect block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -11248,9 +11204,6 @@ test_man_fill_3rd_direct_fill_direct_skip_start_block_add_skipped(hid_t fapl, H5 * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -11322,9 +11275,9 @@ error: } /* test_man_fill_3rd_direct_fill_direct_skip_start_block_add_skipped() */ /*------------------------------------------------------------------------- - * Function: test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_block_add_skipped + * Function: test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, fill all direct * blocks and indirect blocks in 3rd level indirect block, then * fill all direct blocks and 2nd level indirect blocks in 4th @@ -11334,11 +11287,11 @@ error: * 3rd level indirect block, then * backfill all skipped direct blocks & extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 17, 2006 * *------------------------------------------------------------------------- @@ -11359,12 +11312,13 @@ test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_blo size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level indirect blocks, fill " "4th level indirect block's direct, 2nd level indirect blocks and 3rd level direct block, and skip " "first row of 2nd indirect blocks of 4th level indirect block's 3rd level indirect block, then " - "backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + "backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -11430,9 +11384,6 @@ test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_start_blo * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -11507,7 +11458,7 @@ error: * Function: *test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_two_rows_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, fill all direct * blocks and indirect blocks in 3rd level indirect block, fill all * direct & indirect blocks in first row of 4th level indirect @@ -11519,11 +11470,11 @@ error: * 3rd level indirect block (in 4th level indirect block), then * backfill all skipped direct blocks & extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 17, 2006 * *------------------------------------------------------------------------- @@ -11544,13 +11495,14 @@ test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_two_rows_ size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level indirect blocks, fill " "first row of 4th level indirect blocks, fill 2nd row 4th level indirect block's direct, 2nd level " "indirect blocks, first row of 3rd level indirect blocks, 3rd level direct block in 2nd row, and " "skip first row of 2nd indirect blocks of 4th level indirect block's 3rd level indirect block, then " - "backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + "backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -11649,9 +11601,6 @@ test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_two_rows_ * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -11727,7 +11676,7 @@ error: * Function: *test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_wrap_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, fill all direct * blocks and indirect blocks in 3rd level indirect block, fill all * direct & indirect blocks in 4th level indirect @@ -11741,11 +11690,11 @@ error: * 4th level block), then backfill all skipped direct blocks & * extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 17, 2006 * *------------------------------------------------------------------------- @@ -11766,17 +11715,13 @@ test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_wrap_star size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level " - "indirect blocks, fill " - "first row of 3rd level indirect blocks in 4th level indirect block except last " - "3rd level block, " - "fill direct blocks in 3rd level block, and skip row of 2nd indirect blocks of " - "4th level indirect " - "block's 3rd level indirect block, then backfill and extend, then remove all " - "objects %s"; /* Test - description - */ - unsigned u, v; /* Local index variables */ + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = + "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level indirect blocks, fill " + "first row of 3rd level indirect blocks in 4th level indirect block except last 3rd level block, " + "fill direct blocks in 3rd level block, and skip row of 2nd indirect blocks of 4th level indirect " + "block's 3rd level indirect block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -11857,9 +11802,6 @@ test_man_fill_3rd_direct_fill_2nd_direct_fill_direct_skip_3rd_indirect_wrap_star * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -11934,7 +11876,7 @@ error: * Function: *test_man_fill_4th_direct_less_one_fill_2nd_direct_fill_direct_skip_3rd_indirect_wrap_start_block_add_skipped * - * Purpose: Test filling all direct blocks in root indirect block and all + * Purpose: Test filling all direct blocks in root indirect block and all * direct blocks in 2nd level indirect blocks, fill all direct * blocks and indirect blocks in 3rd level indirect block, fill all * direct & indirect blocks in first row of 4th level indirect @@ -11948,11 +11890,11 @@ error: * next row of 4th level blocks), then backfill all skipped direct * blocks & extend. * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, April 17, 2006 * *------------------------------------------------------------------------- @@ -11973,13 +11915,14 @@ test_man_fill_4th_direct_less_one_fill_2nd_direct_fill_direct_skip_3rd_indirect_ size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "filling direct blocks, filling 2nd level indirect blocks, filling 3rd level indirect blocks, fill " "first row of 4th level indirect blocks, except last one, fill first row of 3rd level indirect " "blocks in last 4th level indirect block except last 3rd level block, fill direct blocks in 3rd " "level block, and skip row of 2nd indirect blocks of 4th level indirect block's 3rd level indirect " - "block, then backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + "block, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -12096,9 +12039,6 @@ test_man_fill_4th_direct_less_one_fill_2nd_direct_fill_direct_skip_3rd_indirect_ * object */ obj_size = (size_t)DBLOCK_SIZE(fh, num_first_indirect_rows - 1) + 1; -#ifdef QAK - HDfprintf(stderr, "obj_size = %Zu\n", obj_size); -#endif /* QAK */ state.man_alloc_size += DBLOCK_SIZE(fh, num_first_indirect_rows); if (add_obj(fh, (size_t)20, obj_size, &state, &keep_ids)) TEST_ERROR @@ -12169,25 +12109,22 @@ error: return (1); } /* test_man_fill_4th_direct_less_one_fill_2nd_direct_fill_direct_skip_3rd_indirect_wrap_start_block_add_skipped() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_man_frag_simple + * Function: test_man_frag_simple * - * Purpose: Test inserting objects small enough to fit into first row of + * Purpose: Test inserting objects small enough to fit into first row of * direct blocks, but not to share a block with another object, * until start-block-size * 2 blocks are reached. Then, go back * and fill in the space in the blocks skipped. * * Then, remove all the objects, in various ways * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, July 24, 2006 * *------------------------------------------------------------------------- @@ -12204,10 +12141,9 @@ test_man_frag_simple(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t obj_size; /* Size of object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "fragmenting small blocks, then backfill and extend, then remove all objects %s"; /* Test description - */ - unsigned u; /* Local index variables */ + unsigned u; /* Local index variables */ + /* Test description */ + const char *base_desc = "fragmenting small blocks, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -12307,19 +12243,19 @@ error: } /* test_man_frag_simple() */ /*------------------------------------------------------------------------- - * Function: test_man_frag_direct + * Function: test_man_frag_direct * - * Purpose: Test inserting small object to fit into each direct block + * Purpose: Test inserting small object to fit into each direct block * in root block, but not to share a block with another object, * Then, go back and fill in the space in the blocks skipped. * * Then, go back and remove all objects * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, July 25, 2006 * *------------------------------------------------------------------------- @@ -12337,10 +12273,9 @@ test_man_frag_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar h5_stat_size_t empty_size; /* Size of a file with an empty heap */ size_t obj_size; /* Size of object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "fragmenting direct blocks, then backfill and extend, then remove all objects %s"; /* Test description - */ - unsigned u, v; /* Local index variables */ + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "fragmenting direct blocks, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -12477,9 +12412,9 @@ error: } /* test_man_frag_direct() */ /*------------------------------------------------------------------------- - * Function: test_man_frag_2nd_direct + * Function: test_man_frag_2nd_direct * - * Purpose: Test filling all direct blocks in root indirect block, then + * Purpose: Test filling all direct blocks in root indirect block, then * inserting small object to fit into each direct block * in 2nd level indirect block, but not to share a block with * another object. @@ -12487,11 +12422,11 @@ error: * * Then, go back and remove all the objects * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, July 25, 2006 * *------------------------------------------------------------------------- @@ -12511,10 +12446,10 @@ test_man_frag_2nd_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t * size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "fill root direct blocks, then fragment 2nd level indirect block's direct blocks, then backfill and " - "extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "fill root direct blocks, then fragment 2nd level indirect block's direct " + "blocks, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -12526,9 +12461,6 @@ test_man_frag_2nd_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t * /* Compute # of bits used in first row */ num_first_indirect_rows = IBLOCK_MAX_DROWS(fh, 1); -#ifdef QAK - HDfprintf(stderr, "num_first_indirect_rows = %u\n", num_first_indirect_rows); -#endif /* QAK */ /* Fill direct blocks in root indirect block */ if (fill_root_direct(fh, fill_size, &state, &keep_ids)) @@ -12591,9 +12523,9 @@ error: } /* test_man_frag_2nd_direct() */ /*------------------------------------------------------------------------- - * Function: test_man_frag_3rd_direct + * Function: test_man_frag_3rd_direct * - * Purpose: Test filling all direct blocks in root indirect block and + * Purpose: Test filling all direct blocks in root indirect block and * all 2nd level indirect blocks, then * inserting small object to fit into each direct block * in 3rd level indirect block, but not to share a block with @@ -12602,11 +12534,11 @@ error: * * Then, go back and remove all objects * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, July 25, 2006 * *------------------------------------------------------------------------- @@ -12625,10 +12557,11 @@ test_man_frag_3rd_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t * size_t obj_size; /* Size of object */ size_t fill_size; /* Size of objects for "bulk" filled blocks */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = + unsigned u, v; /* Local index variables */ + /* Test description */ + const char *base_desc = "fill root direct blocks and 2nd level indirect blocks, then fragment 3rd level indirect block's " - "direct blocks, then backfill and extend, then remove all objects %s"; /* Test description */ - unsigned u, v; /* Local index variables */ + "direct blocks, then backfill and extend, then remove all objects %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, &fill_size) < 0) @@ -12708,21 +12641,18 @@ error: H5E_END_TRY; return (1); } /* test_man_frag_3rd_direct() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_huge_insert_one + * Function: test_huge_insert_one * - * Purpose: Test inserting one huge object in the heap + * Purpose: Test inserting one huge object in the heap * * Then, remove all the objects, in various ways * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, August 7, 2006 * *------------------------------------------------------------------------- @@ -12744,7 +12674,8 @@ test_huge_insert_one(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar size_t robj_size; /* Size of object read */ unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = "insert one huge object, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert one huge object, then remove %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -12791,7 +12722,7 @@ test_huge_insert_one(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -12830,9 +12761,6 @@ test_huge_insert_one(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -12865,16 +12793,16 @@ error: } /* test_huge_insert_one() */ /*------------------------------------------------------------------------- - * Function: test_huge_insert_two + * Function: test_huge_insert_two * - * Purpose: Test inserting two huge objects in the heap + * Purpose: Test inserting two huge objects in the heap * * Then, remove all the objects, in various ways * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 11, 2006 * *------------------------------------------------------------------------- @@ -12897,7 +12825,8 @@ test_huge_insert_two(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar size_t robj_size; /* Size of object read */ unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = "insert two huge objects, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert two huge objects, then remove %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -12946,7 +12875,7 @@ test_huge_insert_two(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert second object too large for managed heap blocks */ @@ -12976,7 +12905,7 @@ test_huge_insert_two(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id2, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -13060,9 +12989,6 @@ test_huge_insert_two(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -13097,16 +13023,16 @@ error: } /* test_huge_insert_two() */ /*------------------------------------------------------------------------- - * Function: test_huge_insert_three + * Function: test_huge_insert_three * - * Purpose: Test inserting three huge objects in the heap + * Purpose: Test inserting three huge objects in the heap * * Then, remove all the objects, in various ways * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 11, 2006 * *------------------------------------------------------------------------- @@ -13130,7 +13056,8 @@ test_huge_insert_three(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tp size_t robj_size; /* Size of object read */ unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = "insert three huge objects, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert three huge objects, then remove %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -13181,7 +13108,7 @@ test_huge_insert_three(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tp HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert second object too large for managed heap blocks */ @@ -13211,7 +13138,7 @@ test_huge_insert_three(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tp HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id2, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert third object too large for managed heap blocks */ @@ -13241,7 +13168,7 @@ test_huge_insert_three(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tp HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id3, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -13365,9 +13292,6 @@ test_huge_insert_three(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tp /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -13404,16 +13328,16 @@ error: } /* test_huge_insert_three() */ /*------------------------------------------------------------------------- - * Function: test_huge_insert_mix + * Function: test_huge_insert_mix * - * Purpose: Test inserting a mix of 'normal' & 'huge' objects in the heap + * Purpose: Test inserting a mix of 'normal' & 'huge' objects in the heap * * Then, remove all the objects, in various ways * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, August 11, 2006 * *------------------------------------------------------------------------- @@ -13439,7 +13363,8 @@ test_huge_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar size_t robj_size; /* Size of object read */ unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ - const char *base_desc = "insert mix of normal & huge objects, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert mix of normal & huge objects, then remove %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -13494,7 +13419,7 @@ test_huge_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert second object too large for managed heap blocks */ @@ -13524,7 +13449,7 @@ test_huge_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id2, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert third object too large for managed heap blocks */ @@ -13554,7 +13479,7 @@ test_huge_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id3, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert fourth object small enough to fit into 'normal' heap blocks */ @@ -13591,7 +13516,7 @@ test_huge_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id4, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert fifth object small enough to fit into 'normal' heap blocks */ @@ -13629,7 +13554,7 @@ test_huge_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id5, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -13788,9 +13713,6 @@ test_huge_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -13831,14 +13753,14 @@ error: } /* test_huge_insert_mix() */ /*------------------------------------------------------------------------- - * Function: test_filtered_huge + * Function: test_filtered_huge * - * Purpose: Test storing 'huge' object in a heap with I/O filters + * Purpose: Test storing 'huge' object in a heap with I/O filters * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, August 15, 2006 * *------------------------------------------------------------------------- @@ -13865,8 +13787,8 @@ test_filtered_huge(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tparam size_t old_actual_id_len = 0; /* Old actual ID length */ hbool_t huge_ids_direct; /* Are 'huge' objects directly acccessed? */ hbool_t pline_init = FALSE; /* Whether the I/O pipeline has been initialized */ - const char * base_desc = - "insert 'huge' object into heap with I/O filters, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert 'huge' object into heap with I/O filters, then remove %s"; /* Copy heap creation properties */ HDmemcpy(&tmp_cparam, cparam, sizeof(H5HF_create_t)); @@ -13929,7 +13851,6 @@ test_filtered_huge(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tparam if (reopen_heap(f, &fh, fh_addr, tparam) < 0) TEST_ERROR -/* QAK */ #ifdef QAK /* Close the fractal heap */ if (H5HF_close(fh) < 0) @@ -13956,7 +13877,6 @@ test_filtered_huge(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tparam if (NULL == (fh = H5HF_open(f, fh_addr))) FAIL_STACK_ERROR #endif /* QAK */ - /* QAK */ /* Check up on heap... */ state.huge_size = obj_size; @@ -13972,7 +13892,7 @@ test_filtered_huge(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tparam HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -14011,10 +13931,6 @@ test_filtered_huge(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tparam /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "empty_size = %lu, file_size = %lu\n", (unsigned long)empty_size, - (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -14046,21 +13962,18 @@ error: H5E_END_TRY; return (1); } /* test_filtered_huge() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_tiny_insert_one + * Function: test_tiny_insert_one * - * Purpose: Test inserting one tiny object in the heap + * Purpose: Test inserting one tiny object in the heap * * Then, remove all the objects, in various ways * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, August 14, 2006 * *------------------------------------------------------------------------- @@ -14082,7 +13995,8 @@ test_tiny_insert_one(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar size_t robj_size; /* Size of object read */ unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = "insert one tiny object, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert one tiny object, then remove %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -14129,7 +14043,7 @@ test_tiny_insert_one(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -14168,9 +14082,6 @@ test_tiny_insert_one(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -14203,16 +14114,16 @@ error: } /* test_tiny_insert_one() */ /*------------------------------------------------------------------------- - * Function: test_tiny_insert_two + * Function: test_tiny_insert_two * - * Purpose: Test inserting two tiny objects in the heap + * Purpose: Test inserting two tiny objects in the heap * * Then, remove all the objects, in various ways * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, August 14, 2006 * *------------------------------------------------------------------------- @@ -14235,7 +14146,8 @@ test_tiny_insert_two(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar size_t robj_size; /* Size of object read */ unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = "insert two tiny objects, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert two tiny objects, then remove %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -14284,7 +14196,7 @@ test_tiny_insert_two(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert second object small enough to encode in heap ID */ @@ -14314,7 +14226,7 @@ test_tiny_insert_two(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id2, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -14398,9 +14310,6 @@ test_tiny_insert_two(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -14435,17 +14344,17 @@ error: } /* test_tiny_insert_two() */ /*------------------------------------------------------------------------- - * Function: test_tiny_insert_mix + * Function: test_tiny_insert_mix * - * Purpose: Test inserting a mix of 'normal', 'huge' & 'tiny' objects in + * Purpose: Test inserting a mix of 'normal', 'huge' & 'tiny' objects in * the heap * * Then, remove all the objects, in various ways * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, August 14, 2006 * *------------------------------------------------------------------------- @@ -14473,8 +14382,8 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar size_t robj_size; /* Size of object read */ unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ - const char * base_desc = - "insert mix of normal, huge & tiny objects, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert mix of normal, huge & tiny objects, then remove %s"; /* Perform common test initialization operations */ if (begin_test(tparam, base_desc, &keep_ids, NULL) < 0) @@ -14533,14 +14442,14 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Check 'op' functionality on first huge object */ HDmemset(shared_robj_g, 0, obj_size); if (H5HF_op(fh, heap_id, op_memcpy, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert second object too large for managed heap blocks */ @@ -14570,14 +14479,14 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id2, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Check 'op' functionality on second huge object */ HDmemset(shared_robj_g, 0, obj_size); if (H5HF_op(fh, heap_id2, op_memcpy, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert third object too large for managed heap blocks */ @@ -14607,14 +14516,14 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id3, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Check 'op' functionality on third huge object */ HDmemset(shared_robj_g, 0, obj_size); if (H5HF_op(fh, heap_id3, op_memcpy, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert fourth object small enough to fit into 'normal' heap blocks */ @@ -14651,14 +14560,14 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id4, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Check 'op' functionality on fourth ('normal') object */ HDmemset(shared_robj_g, 0, obj_size); if (H5HF_op(fh, heap_id4, op_memcpy, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert fifth object small enough to fit into 'normal' heap blocks */ @@ -14696,14 +14605,14 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id5, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Check 'op' functionality on fifth ('normal') object */ HDmemset(shared_robj_g, 0, obj_size); if (H5HF_op(fh, heap_id5, op_memcpy, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert sixth object small enough to encode in heap ID */ @@ -14733,14 +14642,14 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id6, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Check 'op' functionality on sixth ('tiny') object */ HDmemset(shared_robj_g, 0, obj_size); if (H5HF_op(fh, heap_id6, op_memcpy, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Insert seventh object small enough to encode in heap ID */ @@ -14770,14 +14679,14 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id7, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Check 'op' functionality on seventh ('tiny') object */ HDmemset(shared_robj_g, 0, obj_size); if (H5HF_op(fh, heap_id7, op_memcpy, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -14998,9 +14907,6 @@ test_tiny_insert_mix(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -15043,20 +14949,16 @@ error: H5E_END_TRY; return (1); } /* test_tiny_insert_mix() */ -#endif /* QAK */ -#endif /* QAK2 */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_filtered_man_root_direct + * Function: test_filtered_man_root_direct * - * Purpose: Test storing one 'managed' object in a heap with I/O filters + * Purpose: Test storing one 'managed' object in a heap with I/O filters * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, August 14, 2006 * *------------------------------------------------------------------------- @@ -15081,8 +14983,8 @@ test_filtered_man_root_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_para unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ unsigned deflate_level; /* Deflation level */ - const char * base_desc = - "insert one 'managed' object into heap with I/O filters, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert one 'managed' object into heap with I/O filters, then remove %s"; /* Copy heap creation properties */ HDmemcpy(&tmp_cparam, cparam, sizeof(H5HF_create_t)); @@ -15154,7 +15056,7 @@ test_filtered_man_root_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_para HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -15196,10 +15098,6 @@ test_filtered_man_root_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_para /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "empty_size = %lu, file_size = %lu\n", (unsigned long)empty_size, - (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -15226,14 +15124,14 @@ error: } /* test_filtered_man_root_direct() */ /*------------------------------------------------------------------------- - * Function: test_filtered_man_root_indirect + * Function: test_filtered_man_root_indirect * - * Purpose: Test storing several objects in a 'managed heap with I/O filters + * Purpose: Test storing several objects in a 'managed heap with I/O filters * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, October 24, 2006 * *------------------------------------------------------------------------- @@ -15259,8 +15157,8 @@ test_filtered_man_root_indirect(hid_t fapl, H5HF_create_t *cparam, fheap_test_pa unsigned char obj_type; /* Type of storage for object */ fheap_heap_state_t state; /* State of fractal heap */ unsigned deflate_level; /* Deflation level */ - const char * base_desc = - "insert two 'managed' objects into heap with I/O filters, then remove %s"; /* Test description */ + /* Test description */ + const char *base_desc = "insert two 'managed' objects into heap with I/O filters, then remove %s"; /* Copy heap creation properties */ HDmemcpy(&tmp_cparam, cparam, sizeof(H5HF_create_t)); @@ -15341,7 +15239,7 @@ test_filtered_man_root_indirect(hid_t fapl, H5HF_create_t *cparam, fheap_test_pa HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id1, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Read in ('normal') object #2 */ @@ -15352,7 +15250,7 @@ test_filtered_man_root_indirect(hid_t fapl, H5HF_create_t *cparam, fheap_test_pa HDmemset(shared_robj_g, 0, obj_size); if (H5HF_read(fh, heap_id2, shared_robj_g) < 0) FAIL_STACK_ERROR - if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size)) + if (HDmemcmp(shared_wobj_g, shared_robj_g, obj_size) != 0) TEST_ERROR /* Delete individual objects, if we won't be deleting the entire heap later */ @@ -15526,10 +15424,6 @@ test_filtered_man_root_indirect(hid_t fapl, H5HF_create_t *cparam, fheap_test_pa /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "empty_size = %lu, file_size = %lu\n", (unsigned long)empty_size, - (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -15554,23 +15448,20 @@ error: H5E_END_TRY; return (1); } /* test_filtered_man_root_indirect() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_random + * Function: test_random * - * Purpose: Test inserting random sized objects into a heap, and read + * Purpose: Test inserting random sized objects into a heap, and read * them back. * * Then, go back and remove all objects * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, May 9, 2006 * *------------------------------------------------------------------------- @@ -15642,10 +15533,10 @@ test_random(hsize_t size_limit, hid_t fapl, H5HF_create_t *cparam, fheap_test_pa /* Choose random # seed */ seed = (unsigned long)HDtime(NULL); -#ifdef QAK - /* seed = (unsigned long)1156158635; */ - HDfprintf(stderr, "Random # seed was: %lu\n", seed); -#endif /* QAK */ +#if 0 +/* seed = (unsigned long)1156158635; */ +HDfprintf(stderr, "Random # seed was: %lu\n", seed); +#endif HDsrandom((unsigned)seed); /* Loop over adding objects to the heap, until the size limit is reached */ @@ -15666,10 +15557,6 @@ test_random(hsize_t size_limit, hid_t fapl, H5HF_create_t *cparam, fheap_test_pa /* Increment the amount of objects added */ total_obj_added += obj_size; } /* end while */ -#ifdef QAK - HDfprintf(stderr, "keep_ids.num_ids = %Zu, total_obj_added = %Hu, size_limit = %Hu\n", keep_ids.num_ids, - total_obj_added, size_limit); -#endif /* QAK */ /* Randomize the order of the IDs kept */ for (u = 0; u < keep_ids.num_ids; u++) { @@ -15728,9 +15615,6 @@ test_random(hsize_t size_limit, hid_t fapl, H5HF_create_t *cparam, fheap_test_pa /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -15769,19 +15653,19 @@ error: } /* test_random() */ /*------------------------------------------------------------------------- - * Function: test_random_pow2 + * Function: test_random_pow2 * - * Purpose: Test inserting random sized objects with a "power of 2 + * Purpose: Test inserting random sized objects with a "power of 2 * distribution" (which favors small objects) into a heap, * and read them back. * * Then, go back and remove all objects * - * Return: Success: 0 + * Return: Success: 0 * - * Failure: 1 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, May 15, 2006 * *------------------------------------------------------------------------- @@ -15855,10 +15739,10 @@ test_random_pow2(hsize_t size_limit, hid_t fapl, H5HF_create_t *cparam, fheap_te /* Choose random # seed */ seed = (unsigned long)HDtime(NULL); -#ifdef QAK - /* seed = (unsigned long)1155181717; */ - HDfprintf(stderr, "Random # seed was: %lu\n", seed); -#endif /* QAK */ +#if 0 +/* seed = (unsigned long)1155181717; */ +HDfprintf(stderr, "Random # seed was: %lu\n", seed); +#endif HDsrandom((unsigned)seed); /* Loop over adding objects to the heap, until the size limit is reached */ @@ -15891,10 +15775,6 @@ test_random_pow2(hsize_t size_limit, hid_t fapl, H5HF_create_t *cparam, fheap_te /* Increment the amount of objects added */ total_obj_added += obj_size; } /* end while */ -#ifdef QAK - HDfprintf(stderr, "keep_ids.num_ids = %Zu, total_obj_added = %Hu, size_limit = %Hu\n", keep_ids.num_ids, - total_obj_added, size_limit); -#endif /* QAK */ /* Randomize the order of the IDs kept */ for (u = 0; u < keep_ids.num_ids; u++) { @@ -15953,10 +15833,6 @@ test_random_pow2(hsize_t size_limit, hid_t fapl, H5HF_create_t *cparam, fheap_te /* Get the size of the file */ if ((file_size = h5_get_file_size(filename, fapl)) < 0) TEST_ERROR -#ifdef QAK - HDfprintf(stderr, "empty_size = %lu\n", (unsigned long)empty_size); - HDfprintf(stderr, "file_size = %lu\n", (unsigned long)file_size); -#endif /* QAK */ /* Verify the file is correct size */ if (file_size != empty_size) @@ -15992,19 +15868,16 @@ error: H5E_END_TRY; return (1); } /* test_random_pow2() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_write + * Function: test_write * - * Purpose: Test inserting objects, then changing the value for them. + * Purpose: Test inserting objects, then changing the value for them. * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Monday, December 18, 2006 * *------------------------------------------------------------------------- @@ -16189,7 +16062,7 @@ test_write(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tparam) FAIL_STACK_ERROR /* Compare data read in */ - if (HDmemcmp(rewrite_obj, shared_robj_g, obj_size)) + if (HDmemcmp(rewrite_obj, shared_robj_g, obj_size) != 0) TEST_ERROR /* Change size of data to write */ @@ -16238,7 +16111,7 @@ test_write(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tparam) FAIL_STACK_ERROR /* Compare data read in */ - if (HDmemcmp(rewrite_obj, shared_robj_g, obj_size)) + if (HDmemcmp(rewrite_obj, shared_robj_g, obj_size) != 0) TEST_ERROR /* Change size of data to write */ @@ -16286,21 +16159,18 @@ error: H5E_END_TRY; return (1); } /* test_write() */ -#endif /* QAK */ - -#ifndef QAK /*------------------------------------------------------------------------- - * Function: test_bug1 + * Function: test_bug1 * - * Purpose: Test inserting several objects, then deleting one and + * Purpose: Test inserting several objects, then deleting one and * re-inserting an object, along with opening and closing * the file. * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Tuesday, November 28, 2006 * *------------------------------------------------------------------------- @@ -16461,18 +16331,17 @@ error: H5E_END_TRY; return (1); } /* test_bug1() */ -#endif /* QAK */ /*------------------------------------------------------------------------- - * Function: main + * Function: main * - * Purpose: Test the fractal heap code + * Purpose: Test the fractal heap code * - * Return: Success: + * Return: Success: * - * Failure: + * Failure: * - * Programmer: Quincey Koziol + * Programmer: Quincey Koziol * Friday, February 24, 2006 * *------------------------------------------------------------------------- @@ -16501,7 +16370,7 @@ main(void) envval = "nomatch"; /* Current VFD that does not support contigous address space */ - contig_addr_vfd = (hbool_t)(HDstrcmp(envval, "split") && HDstrcmp(envval, "multi")); + contig_addr_vfd = (hbool_t)(HDstrcmp(envval, "split") != 0 && HDstrcmp(envval, "multi") != 0); /* Reset library */ h5_reset(); |