diff options
author | Vailin Choi <vchoi@jam.ad.hdfgroup.org> | 2018-12-02 06:17:15 (GMT) |
---|---|---|
committer | Vailin Choi <vchoi@jam.ad.hdfgroup.org> | 2018-12-02 06:17:15 (GMT) |
commit | 49f45640f6b1a3f162027f22a0f00b6eb7f3f433 (patch) | |
tree | efd0f1ec87de84e17969c0d079d1ffa32aab3a8c /src | |
parent | ce2748f0114cb1eae00799f8349a5451152c7fa3 (diff) | |
download | hdf5-49f45640f6b1a3f162027f22a0f00b6eb7f3f433.zip hdf5-49f45640f6b1a3f162027f22a0f00b6eb7f3f433.tar.gz hdf5-49f45640f6b1a3f162027f22a0f00b6eb7f3f433.tar.bz2 |
(1) Fix for accumulator issue #1 as described in John's previous checkin
(2) Test files for encoding/decoding property lists
(3) Fix test failures for PB statistics in test/page_buffer.c
(Will double check with John later about PB statistics collection)
Diffstat (limited to 'src')
-rw-r--r-- | src/H5PB.c | 19 | ||||
-rw-r--r-- | src/H5Pfapl.c | 3 |
2 files changed, 16 insertions, 6 deletions
@@ -57,7 +57,7 @@ * The following #define controls this. Set VFD_IO to FALSE to reproduce * the bug. */ -#define VFD_IO TRUE +#define VFD_IO FALSE /******************/ @@ -1951,8 +1951,7 @@ H5PB__load_page(H5F_t *f, H5PB_t *pb_ptr, haddr_t addr, H5FD_mem_t type, * written. Skip the read if addr > EOF. In this case, tell * H5PB__create_new_page() to zero the page image. */ - skip_read = (addr >= eof); - + /* Remove "skip_read = (addr >= eof);" when accumulator is used */ /* make space in the page buffer if necessary */ if ( ( pb_ptr->curr_pages >= pb_ptr->max_pages ) && @@ -2533,7 +2532,7 @@ H5PB__read_meta(H5F_t *f, H5FD_mem_t type, haddr_t addr, size_t size, if ( entry_ptr == NULL ) { /* case 7 */ /* update hit rate stats */ - H5PB__UPDATE_PB_HIT_RATE_STATS(pb_ptr, FALSE, TRUE, TRUE) + H5PB__UPDATE_PB_HIT_RATE_STATS(pb_ptr, FALSE, TRUE, size > pb_ptr->page_size) /* If the read is for metadata, is page aligned, is larger * than one page, and there is no entry in the page buffer, @@ -2547,6 +2546,8 @@ H5PB__read_meta(H5F_t *f, H5FD_mem_t type, haddr_t addr, size_t size, HGOTO_ERROR(H5E_PAGEBUF, H5E_READERROR, FAIL, \ "driver read request failed (1)") + + H5PB__UPDATE_STATS_FOR_BYPASS(pb_ptr, type, size); } else { HDassert( entry_ptr ); @@ -2590,6 +2591,8 @@ H5PB__read_meta(H5F_t *f, H5FD_mem_t type, haddr_t addr, size_t size, HGOTO_ERROR(H5E_PAGEBUF, H5E_READERROR, FAIL, \ "driver read request failed (2)") + + H5PB__UPDATE_STATS_FOR_BYPASS(pb_ptr, type, size); } else { HDassert( entry_ptr->image_ptr ); @@ -2609,7 +2612,7 @@ H5PB__read_meta(H5F_t *f, H5FD_mem_t type, haddr_t addr, size_t size, } /* update hit rate stats */ - H5PB__UPDATE_PB_HIT_RATE_STATS(pb_ptr, TRUE, TRUE, TRUE) + H5PB__UPDATE_PB_HIT_RATE_STATS(pb_ptr, TRUE, TRUE, FALSE) } } else { /* case 9 */ @@ -2814,6 +2817,9 @@ H5PB__read_raw(H5F_t *f, H5FD_mem_t type, haddr_t addr, size_t size, "read through metadata accumulator failed") + H5PB__UPDATE_STATS_FOR_BYPASS(pb_ptr, type, size); + + /* For each page that intersects with the above read, check to see * if it exists in the page buffer, and if so, if it is dirty. * @@ -3346,6 +3352,9 @@ H5PB__write_raw(H5F_t *f, H5FD_mem_t type, haddr_t addr, size_t size, HGOTO_ERROR(H5E_PAGEBUF, H5E_WRITEERROR, FAIL, \ "write through metadata accumulator failed") + + H5PB__UPDATE_STATS_FOR_BYPASS(pb_ptr, type, size); + /* For each page that intersects with the above write, check to see * if it exists in the page buffer. * diff --git a/src/H5Pfapl.c b/src/H5Pfapl.c index fbac84d..71ab475 100644 --- a/src/H5Pfapl.c +++ b/src/H5Pfapl.c @@ -3985,7 +3985,8 @@ H5P__facc_vfd_swmr_config_enc(const void *value, void **_pp, size_t *size) } /* end if */ /* Compute encoded size */ - *size += ( (4 * sizeof(int32_t)) + sizeof(unsigned) + + *size += ( (4 * sizeof(int32_t)) + + (2 * sizeof(unsigned)) + (2 * (H5F__MAX_VFD_SWMR_FILE_NAME_LEN + 1)) ); FUNC_LEAVE_NOAPI(SUCCEED) |