summaryrefslogtreecommitdiffstats
path: root/test/vfd_swmr_dsetops_writer.c
diff options
context:
space:
mode:
authorvchoi <vchoi@jelly.ad.hdfgroup.org>2021-07-13 22:36:48 (GMT)
committervchoi <vchoi@jelly.ad.hdfgroup.org>2021-07-13 22:36:48 (GMT)
commit3d5c597c49a69af72bb8c58e0f4cc0636a8e1ece (patch)
treebc5bbfe1a7cc3ec609661ca616ed0cafad68ddd2 /test/vfd_swmr_dsetops_writer.c
parentfd014862f795dfdf5b50e4f63d34929625536cfe (diff)
downloadhdf5-3d5c597c49a69af72bb8c58e0f4cc0636a8e1ece.zip
hdf5-3d5c597c49a69af72bb8c58e0f4cc0636a8e1ece.tar.gz
hdf5-3d5c597c49a69af72bb8c58e0f4cc0636a8e1ece.tar.bz2
Modifications to common routines used by VFD SWMR tests:
(1) Add a parameter page_buf_size to the common routine vfd_swmr_create_fapl(). (2) Add a new common routine vfd_swmr_create_fcpl() to set the file space strategy and file space page size. VFD SWMR tests are modified accordingly to call the above routines.
Diffstat (limited to 'test/vfd_swmr_dsetops_writer.c')
-rw-r--r--test/vfd_swmr_dsetops_writer.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/test/vfd_swmr_dsetops_writer.c b/test/vfd_swmr_dsetops_writer.c
index 66d0410..26f8977 100644
--- a/test/vfd_swmr_dsetops_writer.c
+++ b/test/vfd_swmr_dsetops_writer.c
@@ -1676,19 +1676,15 @@ main(int argc, char **argv)
/* config, tick_len, max_lag, writer, flush_raw_data, md_pages_reserved, md_file_path */
init_vfd_swmr_config(&config, 4, 7, writer, FALSE, 128, "./dsetops-shadow");
- /* use_latest_format, use_vfd_swmr, only_meta_page, config */
- if ((fapl = vfd_swmr_create_fapl(true, s.use_vfd_swmr, true, &config)) < 0) {
+ /* use_latest_format, use_vfd_swmr, only_meta_page, page_buf_size, config */
+ if ((fapl = vfd_swmr_create_fapl(true, s.use_vfd_swmr, true, 4096, &config)) < 0) {
HDprintf("vfd_swmr_create_fapl() failed\n");
TEST_ERROR;
}
- if ((fcpl = H5Pcreate(H5P_FILE_CREATE)) < 0) {
- HDprintf("H5Pcreate failed\n");
- TEST_ERROR;
- }
-
- if (H5Pset_file_space_strategy(fcpl, H5F_FSPACE_STRATEGY_PAGE, false, 1) < 0) {
- HDprintf("H5Pset_file_space_strategy failed\n");
+ /* Set fs_strategy (file space strategy) and fs_page_size (file space page size) */
+ if ((fcpl = vfd_swmr_create_fcpl(H5F_FSPACE_STRATEGY_PAGE, 4096)) < 0) {
+ HDprintf("vfd_swmr_create_fcpl() failed");
TEST_ERROR;
}