[Webkit-unassigned] [Bug 141378] Measure cache size more accurately
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Sun Feb 8 19:33:41 PST 2015
https://bugs.webkit.org/show_bug.cgi?id=141378
Chris Dumez <cdumez at apple.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #246253|review? |review+
Flags| |
--- Comment #3 from Chris Dumez <cdumez at apple.com> ---
Comment on attachment 246253
--> https://bugs.webkit.org/attachment.cgi?id=246253
patch
View in context: https://bugs.webkit.org/attachment.cgi?id=246253&action=review
r=me with comments
> Source/WebKit2/NetworkProcess/cache/NetworkCacheStorageCocoa.mm:458
> + m_approximateSize += bodyOffset + bodySize;
Why are we adding an offset to the size here? Maybe it is just a naming issue but it looks wrong.
> Source/WebKit2/NetworkProcess/cache/NetworkCacheStorageCocoa.mm:554
> + static const double deletionProbability { 0.25 };
Maybe a ASSERT(RunLoop::isMain()); before this?
> Source/WebKit2/NetworkProcess/cache/NetworkCacheStorageCocoa.mm:572
> + bool shouldDelete = randomNumber() < deletionProbability;
Is it safe to call randomNumber() from another thread? The implementation seems to call sharedRandomNumberGenerator() which is a singleton.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20150209/537d79e3/attachment-0002.html>
More information about the webkit-unassigned
mailing list