summaryrefslogtreecommitdiffstats
path: root/src/H5Cprivate.h
diff options
context:
space:
mode:
authorJohn Mainzer <mainzer@hdfgroup.org>2006-05-24 07:36:28 (GMT)
committerJohn Mainzer <mainzer@hdfgroup.org>2006-05-24 07:36:28 (GMT)
commita415cc6b17269c893704b3410a764b1c5d3d812e (patch)
tree36c29aba9c7b776bec0a65999d796d389bec9090 /src/H5Cprivate.h
parent5f4234fabfe2ee0c07d74776d36352a8daf49e31 (diff)
downloadhdf5-a415cc6b17269c893704b3410a764b1c5d3d812e.zip
hdf5-a415cc6b17269c893704b3410a764b1c5d3d812e.tar.gz
hdf5-a415cc6b17269c893704b3410a764b1c5d3d812e.tar.bz2
[svn-r12374] Purpose:
1) Check in potential fix to unreproduceable bug in t_cache observed on Cobalt 2) Check in code supporting added pinned entry features in the metadata cache. Description: 1) Elena encountered a bug in t_cache when running on Cobalt. On investigation I found a potential race condition in t_cache that could explain her observation. 2) Quincey requested additions to the metadata cache allowing renaming of pinned entryies, and marking of pinned or protected entries as dirty. Solution: 1) Modified t_cache.c to prevent the potential race condition. Elena was unable to reproduce the bug on Cobalt, so we don't know if my fix actually addressed the problem. 2) Added code supporting the requested functions. The changes were relatively trivial, but required substantial new test code. Platforms tested: h5committest, serial test on heping, parallel test on phoenix. Misc. update:
Diffstat (limited to 'src/H5Cprivate.h')
-rw-r--r--src/H5Cprivate.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/H5Cprivate.h b/src/H5Cprivate.h
index 43a93b3..bdcf501 100644
--- a/src/H5Cprivate.h
+++ b/src/H5Cprivate.h
@@ -234,6 +234,21 @@ typedef herr_t (*H5C_log_flush_func_t)(H5C_t * cache_ptr,
* modules using the cache. These still clear the
* is_dirty field as before. -- JRM 7/5/05
*
+ * dirtied: Boolean flag used to indicate that the entry has been
+ * dirtied while protected.
+ *
+ * This field is set to FALSE in the protect call, and may
+ * be set to TRUE by the
+ * H5C_mark_pinned_or_protected_entry_dirty()
+ * call at an time prior to the unprotect call.
+ *
+ * The H5C_mark_pinned_or_protected_entry_dirty() call exists
+ * as a convenience function for the fractal heap code which
+ * may not know if an entry is protected or pinned, but knows
+ * that is either protected or pinned. The dirtied field was
+ * added as in the parallel case, it is necessary to know
+ * whether a protected entry was dirty prior to the protect call.
+ *
* is_protected: Boolean flag indicating whether this entry is protected
* (or locked, to use more conventional terms). When it is
* protected, the entry cannot be flushed or accessed until
@@ -401,6 +416,7 @@ typedef struct H5C_cache_entry_t
size_t size;
const H5C_class_t * type;
hbool_t is_dirty;
+ hbool_t dirtied;
hbool_t is_protected;
hbool_t is_pinned;
hbool_t in_slist;
@@ -835,6 +851,9 @@ H5_DLL herr_t H5C_mark_pinned_entry_dirty(H5C_t * cache_ptr,
hbool_t size_changed,
size_t new_size);
+H5_DLL herr_t H5C_mark_pinned_or_protected_entry_dirty(H5C_t * cache_ptr,
+ void * thing);
+
H5_DLL herr_t H5C_rename_entry(H5C_t * cache_ptr,
const H5C_class_t * type,
haddr_t old_addr,