-
- Downloads
Speed up `@cachedList` (#13591)
This speeds things up by ~2x. The vast majority of the time is now spent in `LruCache` moving things around the linked lists. We do this via two things: 1. Don't create a deferred per-key during bulk set operations in `DeferredCache`. Instead, only create them if a subsequent caller asks for the key. 2. Add a bulk lookup API to `DeferredCache` rather than use a loop.
Showing
- changelog.d/13591.misc 1 addition, 0 deletionschangelog.d/13591.misc
- synapse/util/caches/deferred_cache.py 255 additions, 91 deletionssynapse/util/caches/deferred_cache.py
- synapse/util/caches/descriptors.py 39 additions, 50 deletionssynapse/util/caches/descriptors.py
- synapse/util/caches/treecache.py 3 additions, 0 deletionssynapse/util/caches/treecache.py
Loading
Please register or sign in to comment