Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(99)

Issue 2364243002: Serialize Histograms more efficiently. (Closed)

Created:
4 years, 2 months ago by benjhayden
Modified:
4 years, 2 months ago
Reviewers:
eakuefner, nednguyen
CC:
catapult-reviews_chromium.org, tracing-review_chromium.org
Target Ref:
refs/heads/master
Project:
catapult
Visibility:
Public.

Description

Serialize Histograms more efficiently. In a results2.html that Juan emailed recently, 16700 Histograms took 95646761 bytes, for an average of 5727 bytes per Histogram. The only Diagnostics were IterationInfo. This CL reduces the average size of each Histogram in the memory.top_10_mobile benchmark to 843 bytes, an improvement of 86%. Avoid serializing unnecessary information. Serialize sparse centralBins arrays as dictionaries. Serialize HistogramBinBoundaries builder recipes instead of the boundaries themselves. Add tests to monitor serialization sizes. Trimming floats is left for another CL. BUG=catapult:#2794 Committed: https://chromium.googlesource.com/external/github.com/catapult-project/catapult/+/03fbd54d8fdb0defa1a677b71d67a9f46544fa86

Patch Set 1 #

Patch Set 2 : . #

Patch Set 3 : make HistogramBin.asDict() even more efficient #

Patch Set 4 : HistogramBinBoundaries builder recipes #

Patch Set 5 : back out DICT_TAGS #

Total comments: 8

Patch Set 6 : binBoundariesBuilderDict_ #

Patch Set 7 : *binRanges(), cache HistogramBinBoundaries #

Patch Set 8 : RunningStatistics.asDict undefined #

Total comments: 22

Patch Set 9 : uniformlySampleArray #

Patch Set 10 : . #

Patch Set 11 : . #

Unified diffs Side-by-side diffs Delta from patch set Stats (+472 lines, -151 lines) Patch
M tracing/tracing/base/running_statistics.html View 1 2 3 4 5 6 7 8 9 1 chunk +28 lines, -17 lines 0 comments Download
M tracing/tracing/base/running_statistics_test.html View 1 2 3 4 5 6 7 1 chunk +6 lines, -1 line 0 comments Download
M tracing/tracing/base/statistics.html View 1 2 3 4 5 6 7 8 1 chunk +17 lines, -0 lines 0 comments Download
M tracing/tracing/base/statistics_test.html View 1 2 3 4 5 6 7 8 2 chunks +8 lines, -1 line 0 comments Download
M tracing/tracing/value/histogram.html View 1 2 3 4 5 6 7 8 9 10 15 chunks +355 lines, -127 lines 0 comments Download
M tracing/tracing/value/histogram_test.html View 1 2 3 4 5 6 7 8 9 3 chunks +57 lines, -2 lines 0 comments Download
M tracing/tracing/value/ui/value_set_table.html View 1 2 3 1 chunk +1 line, -3 lines 0 comments Download

Messages

Total messages: 44 (16 generated)
benjhayden
PTAL :-)
4 years, 2 months ago (2016-09-23 23:09:14 UTC) #3
nednguyen
On 2016/09/23 23:09:14, benjhayden wrote: > PTAL :-) Can you run Juan's benchmark to see ...
4 years, 2 months ago (2016-09-23 23:11:09 UTC) #5
benjhayden
On 2016/09/23 at 23:11:09, nednguyen wrote: > On 2016/09/23 23:09:14, benjhayden wrote: > > PTAL ...
4 years, 2 months ago (2016-09-26 05:30:38 UTC) #9
nednguyen
On 2016/09/26 05:30:38, benjhayden wrote: > On 2016/09/23 at 23:11:09, nednguyen wrote: > > On ...
4 years, 2 months ago (2016-09-26 17:38:27 UTC) #11
nednguyen
The optimization of serializing sparse centralBins arrays as dictionaries makes a lot of sense to ...
4 years, 2 months ago (2016-09-26 18:45:57 UTC) #12
benjhayden
On 2016/09/26 at 18:45:57, nednguyen wrote: > The optimization of serializing sparse centralBins arrays as ...
4 years, 2 months ago (2016-09-26 19:41:00 UTC) #16
benjhayden
On 2016/09/26 at 19:41:00, benjhayden wrote: > On 2016/09/26 at 18:45:57, nednguyen wrote: > > ...
4 years, 2 months ago (2016-09-26 20:39:56 UTC) #17
benjhayden
On 2016/09/26 at 20:39:56, benjhayden wrote: > On 2016/09/26 at 19:41:00, benjhayden wrote: > > ...
4 years, 2 months ago (2016-09-26 21:01:30 UTC) #18
benjhayden
Serializing bin boundaries builder recipes does seem to fix the mysterious boundary deletions. :-)
4 years, 2 months ago (2016-09-26 22:40:28 UTC) #21
nednguyen
https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/base/running_statistics.html File tracing/tracing/base/running_statistics.html (right): https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/base/running_statistics.html#newcode143 tracing/tracing/base/running_statistics.html:143: return 0; nits: can you change to return "null"? ...
4 years, 2 months ago (2016-09-27 15:04:49 UTC) #22
nednguyen
On 2016/09/27 15:04:49, nednguyen wrote: > https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/base/running_statistics.html > File tracing/tracing/base/running_statistics.html (right): > > https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/base/running_statistics.html#newcode143 > ...
4 years, 2 months ago (2016-09-27 15:07:52 UTC) #23
benjhayden
On 2016/09/27 at 15:07:52, nednguyen wrote: > On 2016/09/27 15:04:49, nednguyen wrote: > > https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/base/running_statistics.html ...
4 years, 2 months ago (2016-09-27 16:02:54 UTC) #24
nednguyen
On 2016/09/27 16:02:54, benjhayden wrote: > On 2016/09/27 at 15:07:52, nednguyen wrote: > > On ...
4 years, 2 months ago (2016-09-27 16:22:17 UTC) #25
benjhayden
On 2016/09/27 at 16:22:17, nednguyen wrote: > On 2016/09/27 16:02:54, benjhayden wrote: > > On ...
4 years, 2 months ago (2016-09-27 16:43:00 UTC) #26
benjhayden
I'm still occasionally seeing (unmergeable) in results2.html with memory.top_10_mobile. I found one histogram that was ...
4 years, 2 months ago (2016-09-27 18:46:35 UTC) #28
nednguyen
https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/base/running_statistics.html File tracing/tracing/base/running_statistics.html (right): https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/base/running_statistics.html#newcode142 tracing/tracing/base/running_statistics.html:142: return undefined; JSON.stringify(undefined) --> undefined, so I think it's ...
4 years, 2 months ago (2016-09-27 18:48:54 UTC) #29
nednguyen
https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/value/histogram.html File tracing/tracing/value/histogram.html (right): https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/value/histogram.html#newcode72 tracing/tracing/value/histogram.html:72: return this.count; On 2016/09/27 18:46:34, benjhayden wrote: > On ...
4 years, 2 months ago (2016-09-27 19:02:58 UTC) #30
nednguyen
On 2016/09/27 19:02:58, nednguyen wrote: > https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/value/histogram.html > File tracing/tracing/value/histogram.html (right): > > https://codereview.chromium.org/2364243002/diff/80001/tracing/tracing/value/histogram.html#newcode72 > ...
4 years, 2 months ago (2016-09-27 19:03:58 UTC) #31
benjhayden
https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/value/histogram.html File tracing/tracing/value/histogram.html (right): https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/value/histogram.html#newcode72 tracing/tracing/value/histogram.html:72: return this.count; On 2016/09/27 at 18:48:54, nednguyen wrote: > ...
4 years, 2 months ago (2016-09-27 21:05:17 UTC) #32
nednguyen
Thanks for your patience lgtm https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/value/histogram.html File tracing/tracing/value/histogram.html (right): https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/value/histogram.html#newcode599 tracing/tracing/value/histogram.html:599: var centralBinsArrayOverhead = 0; ...
4 years, 2 months ago (2016-09-27 21:46:29 UTC) #33
benjhayden
https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/base/running_statistics.html File tracing/tracing/base/running_statistics.html (right): https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/base/running_statistics.html#newcode142 tracing/tracing/base/running_statistics.html:142: return undefined; On 2016/09/27 at 18:48:53, nednguyen wrote: > ...
4 years, 2 months ago (2016-09-27 21:50:11 UTC) #34
nednguyen
On 2016/09/27 21:50:11, benjhayden wrote: > https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/base/running_statistics.html > File tracing/tracing/base/running_statistics.html (right): > > https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/base/running_statistics.html#newcode142 > ...
4 years, 2 months ago (2016-09-27 21:52:12 UTC) #35
benjhayden
https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/value/histogram.html File tracing/tracing/value/histogram.html (right): https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/value/histogram.html#newcode599 tracing/tracing/value/histogram.html:599: var centralBinsArrayOverhead = 0; On 2016/09/27 at 21:46:29, nednguyen ...
4 years, 2 months ago (2016-09-27 22:47:50 UTC) #36
nednguyen
On 2016/09/27 22:47:50, benjhayden wrote: > https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/value/histogram.html > File tracing/tracing/value/histogram.html (right): > > https://codereview.chromium.org/2364243002/diff/140001/tracing/tracing/value/histogram.html#newcode599 > ...
4 years, 2 months ago (2016-09-27 22:50:48 UTC) #37
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2364243002/200001
4 years, 2 months ago (2016-09-28 04:27:23 UTC) #40
benjhayden
Thanks for the great review! Sorry there turned out to be more design decisions than ...
4 years, 2 months ago (2016-09-28 04:28:35 UTC) #41
commit-bot: I haz the power
Committed patchset #11 (id:200001) as https://chromium.googlesource.com/external/github.com/catapult-project/catapult/+/03fbd54d8fdb0defa1a677b71d67a9f46544fa86
4 years, 2 months ago (2016-09-28 04:50:04 UTC) #43
nednguyen
4 years, 2 months ago (2016-09-28 13:07:00 UTC) #44
Message was sent while issue was closed.
On 2016/09/28 04:28:35, benjhayden wrote:
> Thanks for the great review!
> Sorry there turned out to be more design decisions than I'd thought. I should
> have started with a doc.

No problem, another thing that would help is divide this patch to multiple one,
each focuses on a single optimization.

Powered by Google App Engine
This is Rietveld 408576698