RESOLVED FIXED 143783
Network Cache: Inline small body data to record file
https://bugs.webkit.org/show_bug.cgi?id=143783
Summary Network Cache: Inline small body data to record file
Antti Koivisto
Reported 2015-04-15 10:27:01 PDT
We currently save all body data as separate files. We can improve space efficiency and do less reads by inlining smaller resources.
Attachments
patch (16.96 KB, patch)
2015-04-15 10:58 PDT, Antti Koivisto
cdumez: review+
Antti Koivisto
Comment 1 2015-04-15 10:58:48 PDT
WebKit Commit Bot
Comment 2 2015-04-15 11:00:13 PDT
Attachment 250824 [details] did not pass style-queue: ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannel.h:47: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannel.h:48: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannel.h:49: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannelCocoa.mm:82: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannelCocoa.mm:99: Extra space before ( in function call [whitespace/parens] [4] ERROR: Source/WebKit2/NetworkProcess/cache/NetworkCacheIOChannelCocoa.mm:109: Extra space before ( in function call [whitespace/parens] [4] Total errors found: 6 in 5 files If any of these errors are false positives, please file a bug against check-webkit-style.
Pratik Solanki
Comment 3 2015-04-15 11:04:23 PDT
Comment on attachment 250824 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=250824&action=review > Source/WebKit2/NetworkProcess/cache/NetworkCacheStorage.cpp:497 > + const size_t maximumInlineBodySize = 16 << 10; Not sure what the preferred style is but writing this as 16 * 1024 would be clearer to me than the bitshift.
Chris Dumez
Comment 4 2015-04-15 12:29:14 PDT
Comment on attachment 250824 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=250824&action=review r=me > Source/WebKit2/NetworkProcess/cache/NetworkCacheStorage.cpp:349 > + return { }; Slight preference for "return Nullopt;" >> Source/WebKit2/NetworkProcess/cache/NetworkCacheStorage.cpp:497 >> + const size_t maximumInlineBodySize = 16 << 10; > > Not sure what the preferred style is but writing this as 16 * 1024 would be clearer to me than the bitshift. I agree with Pratik here. > Source/WebKit2/NetworkProcess/cache/NetworkCacheStorage.cpp:516 > + bool storeAsBlob = shouldStoreBodyAsBlob(write.record.body); shouldStoreAsBlob as per our boolean variable naming coding style?
Antti Koivisto
Comment 5 2015-04-15 12:56:39 PDT
David Kilzer (:ddkilzer)
Comment 6 2015-04-18 07:20:50 PDT
Note You need to log in before you can comment on or make changes to this bug.