Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Speed up @cachedList (#13591)
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
erikjohnston committed Aug 23, 2022
1 parent 05c9c73 commit f7ddfe1
Show file tree
Hide file tree
Showing 4 changed files with 298 additions and 141 deletions.
1 change: 1 addition & 0 deletions changelog.d/13591.misc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Improve performance of `@cachedList`.
Loading

0 comments on commit f7ddfe1

Please sign in to comment.