[NEWS] Objects Cache

This forum is dedicated to feedback, discussions about ongoing or future developments, ideas and suggestions regarding the ChibiOS projects are welcome. This forum is NOT for support.
User avatar
Site Admin
Posts: 13531
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 862 times
Been thanked: 743 times

[NEWS] Objects Cache

Postby Giovanni » Wed Aug 28, 2019 10:30 am


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.


Return to “Development and Feedback”

Who is online

Users browsing this forum: Google Adsense [Bot] and 8 guests