[webkit-reviews] review granted: [Bug 237117] Small optimizations to TinyLRUCache : [Attachment 453035] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Feb 23 17:48:15 PST 2022
Darin Adler <darin at apple.com> has granted Chris Dumez <cdumez at apple.com>'s
request for review:
Bug 237117: Small optimizations to TinyLRUCache
https://bugs.webkit.org/show_bug.cgi?id=237117
Attachment 453035: Patch
https://bugs.webkit.org/attachment.cgi?id=453035&action=review
--- Comment #2 from Darin Adler <darin at apple.com> ---
Comment on attachment 453035
--> https://bugs.webkit.org/attachment.cgi?id=453035
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=453035&action=review
> Source/WTF/ChangeLog:14
> + - Use Vector::uncheckedAppend() instead of Vector::append() to
bypass capacity
> + checks given that the vector has an inline capacity that is the
size of the
> + cache (vector capacity never grows or shrinks).
Maybe we should us FixedVector instead?
> Source/WTF/wtf/TinyLRUCache.h:56
> + Entry entry = WTFMove(m_cache[index]);
I’d use auto here.
More information about the webkit-reviews
mailing list