Hi,
I just added to OSLIB in trunk a new class "Objects Cache", it implements a cache of arbitrary objects or buffers that are read/written from/to an arbitrary media.
The class implements a LRU list with most recently used objects/buffers, an hash table is used for fast objects/buffers retrieval. Some features:
- Fully static.
- Synchronous or asynchronous read and write operations.
- Read ahead.
- Immediate or lazy write operations.
- Mutual exclusion implemented at object/buffer level (multiple threads can ask for the same object and are serialized if required).
The test suite is not complete but it APPEARS to work, the most immediate use case is to add it to the FatFS bindings in order to increase I/O performance. Ideally it will be used by a native FS able to leverage the advanced features like lazy writing which FatFS could not support as-is.
Giovanni
[NEWS] Objects Cache
- Giovanni
- Site Admin
- Posts: 14444
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1074 times
- Been thanked: 921 times
- Contact:
Return to “Development and Feedback”
Who is online
Users browsing this forum: No registered users and 17 guests