diff options
author | Dana Robinson <derobins@hdfgroup.org> | 2017-04-19 22:28:21 (GMT) |
---|---|---|
committer | Dana Robinson <derobins@hdfgroup.org> | 2017-04-19 22:28:21 (GMT) |
commit | d594cb2cc6d73ef2dd7ddfee689cdda23827e03e (patch) | |
tree | ae2b91ccecc0e69cfdbdb25d566dc9f9f8b8be9b /src | |
parent | 8f34c3cfd46054f6478b34df6af324c353e44d62 (diff) | |
download | hdf5-d594cb2cc6d73ef2dd7ddfee689cdda23827e03e.zip hdf5-d594cb2cc6d73ef2dd7ddfee689cdda23827e03e.tar.gz hdf5-d594cb2cc6d73ef2dd7ddfee689cdda23827e03e.tar.bz2 |
Added code to disable the evict-on-close feature in
the parallel library.
Diffstat (limited to 'src')
-rw-r--r-- | src/H5Pfapl.c | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/src/H5Pfapl.c b/src/H5Pfapl.c index 7865fdf..8bd53a9 100644 --- a/src/H5Pfapl.c +++ b/src/H5Pfapl.c @@ -4381,7 +4381,19 @@ H5P_facc_mdc_log_location_close(const char H5_ATTR_UNUSED *name, size_t H5_ATTR_ *------------------------------------------------------------------------- */ herr_t -H5Pset_evict_on_close(hid_t fapl_id, hbool_t evict_on_close) +H5Pset_evict_on_close( +#if defined(H5_HAVE_PARALLEL) && !defined(H5_DEBUG_BUILD) + hid_t H5_ATTR_UNUSED fapl_id, +#else + hid_t fapl_id, +#endif /* H5_HAVE_PARALLEL and !H5_DEBUG_BUILD */ + +#ifdef H5_HAVE_PARALLEL + hbool_t H5_ATTR_UNUSED evict_on_close +#else + hbool_t evict_on_close +#endif /* H5_HAVE_PARALLEL */ +) { H5P_genplist_t *plist; /* property list pointer */ herr_t ret_value = SUCCEED; /* return value */ @@ -4389,6 +4401,7 @@ H5Pset_evict_on_close(hid_t fapl_id, hbool_t evict_on_close) FUNC_ENTER_API(FAIL) H5TRACE2("e", "ib", fapl_id, evict_on_close); + /* Compare the property list's class against the other class */ if(TRUE != H5P_isa_class(fapl_id, H5P_FILE_ACCESS)) HGOTO_ERROR(H5E_PLIST, H5E_CANTREGISTER, FAIL, "property list is not a file access plist") @@ -4397,9 +4410,13 @@ H5Pset_evict_on_close(hid_t fapl_id, hbool_t evict_on_close) if(NULL == (plist = (H5P_genplist_t *)H5I_object(fapl_id))) HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "can't find object for ID") - /* Set values */ +#ifndef H5_HAVE_PARALLEL + /* Set value */ if(H5P_set(plist, H5F_ACS_EVICT_ON_CLOSE_FLAG_NAME, &evict_on_close) < 0) HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set evict on close property") +#else + HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "evict on close is currently not supported in parallel HDF5") +#endif /* H5_HAVE_PARALLEL */ done: FUNC_LEAVE_API(ret_value) |