[PVFS2-developers] patch: acache prototype
Phil Carns
pcarns at wastedcycles.org
Thu Oct 27 18:05:47 EDT 2005
Here is an early draft of some attribute cache updates for PVFS2. It
seems to work Ok, but has not been thoroughly tested yet. I am just
providing it to share what we have so far. It doesn't have any major
conceptual changes from the old acache.[ch]. It still caches the same
information and is purely timeout based.
what's included:
------------------------------
- adds a generic caching component (called the tcache) that could be
shared between the attribute cache and name cache, maybe others?
- simplified acache API
- doxygen comments of acache and tcache
- no more "pinodes"
- no reference counts exposed outside of acache API
- a little bit more methodical thread safety
- LRU list in tcache to speed up reclaim time
- seperate hard limits and soft limits, hard limit now enforced
- updates to when and where acache is used
- see doxygen comments in acache.h for lists of operations that
interact with the cache.
- biggest change is that more operations invalidate cache on failure
just as a safety precaution
things that are still missing:
------------------------------
- thorough testing
- more exposed hooks to change caching parameters
- performance counters
We haven't looked at any new data structures; the tcache still uses an
open hash table as its primary mechansim to lookup cached objects.
There isn't any particular reason it couldn't be done with another data
structure underneath the tcache API (either the AVL tree implementation
currently in the code if it were moved to a common location, or a
red-black tree as proposed by Julian).
-Phil
-------------- next part --------------
A non-text attachment was scrubbed...
Name: acache.patch
Type: text/x-patch
Size: 112701 bytes
Desc: not available
Url : http://www.beowulf-underground.org/pipermail/pvfs2-developers/attachments/20051027/cf3f7c05/acache-0001.bin
More information about the PVFS2-developers
mailing list