Investigate nursery performance in the ARES-6 benchmark
Categories
(Core :: JavaScript: GC, task)
Tracking
()
People
(Reporter: jonco, Assigned: jonco)
References
()
Details
(Keywords: perf-alert)
Attachments
(5 files)
Following bug 1637896 I took a profile of the first few seconds of the benchmark:
This shows a period with extremely frequent minor GCs. It's likely we could improve our score on this benchmark by doing some tuning here.
Assignee | ||
Comment 1•5 years ago
|
||
When running benchmarks the nursery size changes frequently, often at every collection.
This patch uses a moving average of the calculated growth factor. This takes into account information from previous collections as well when calculating the nursery size and producees much more stable results.
Updated•5 years ago
|
Assignee | ||
Comment 2•5 years ago
|
||
This adds a goal of using less then 1% of total time collecthing the nursery, which has the effect of increasing the nursery size where a lot of nursery garbage is created but little is tenured.
In local testing this is a win on ARES6 and octane, but perfherder paints a more ambiguous picture. I'd like to land this anyway and we can back it out if it causes problems.
Depends on D80002
Assignee | ||
Comment 3•5 years ago
|
||
I'll land the patches separately so we can see the cause of any regressions.
Comment 5•5 years ago
|
||
bugherder |
![]() |
||
Comment 7•5 years ago
|
||
Backout merged: https://hg.mozilla.org/mozilla-central/rev/c269b2b6cdd2
Updated•5 years ago
|
Assignee | ||
Comment 8•5 years ago
|
||
This only uses the smoothed growth factor if it contains data from previous collections.
This should fix the awsy regressions from when this landed before. Fast ramp up is important in startup to avoid growing the tenured heap which can lead to larger overall memory usage.
Depends on D80002
Updated•5 years ago
|
Assignee | ||
Comment 9•5 years ago
|
||
I think I've fixed the memory regression so I'll try relanding this.
Comment 10•5 years ago
|
||
Comment 11•5 years ago
|
||
bugherder |
Assignee | ||
Comment 12•5 years ago
|
||
Runtimes that are not currently running any JS may tie up signficant memory in their nurseries. This patch shrinks 'idle' nurseries to their minimum size (default 256KB). Idleness is determined by no cells being allocated in them for 2 seconds (I'm open to discussions about the exact limit). This means that even if more nursery memory is used temporarily, we release it again in a timely manner.
Assignee | ||
Comment 13•5 years ago
|
||
It only makes sense to use the smoothing if the nursery has been collected recently. If not it's unlikely to correlate with recent usage. This change makes us ramp up more quickly after a period of inactivity, as we did before the earlier patches in this series landed.
Depends on D82969
Updated•5 years ago
|
Updated•5 years ago
|
Updated•5 years ago
|
Comment 14•5 years ago
|
||
Comment 15•5 years ago
|
||
bugherder |
Comment 16•5 years ago
|
||
Comment 17•5 years ago
|
||
bugherder |
Comment 18•5 years ago
|
||
== Change summary for alert #26525 (as of Thu, 16 Jul 2020 07:20:26 GMT) ==
Improvements:
5% JS windows7-32-shippable opt tp6 154,233,295.40 -> 146,304,383.68
4% JS linux1804-64-shippable-qr opt tp6 197,936,476.58 -> 189,533,440.23
4% JS windows7-32-shippable opt tp6 153,609,995.70 -> 147,327,726.87
4% JS windows10-64-shippable opt tp6 196,955,925.59 -> 189,425,260.74
4% JS macosx1014-64-shippable opt tp6 198,991,964.39 -> 191,527,408.73
4% JS windows10-64-shippable-qr opt tp6 198,916,803.67 -> 191,566,881.77
4% JS windows10-64-shippable-qr opt 106,325,912.80 -> 102,603,602.22
3% JS linux1804-64-shippable opt 103,653,366.40 -> 100,151,233.52
3% JS linux1804-64-shippable-qr opt 103,000,295.89 -> 99,934,971.58
3% JS macosx1014-64-shippable opt 104,240,325.02 -> 101,140,014.01
3% JS windows7-32-shippable opt 75,643,511.28 -> 73,676,777.48
For up to date results, see: https://treeherder.mozilla.org/perf.html#/alerts?id=26525
Assignee | ||
Comment 19•5 years ago
|
||
This didn't have exactly the outcome I expected but I'm not planning on making any more changes in this bug.
Updated•5 years ago
|
Description
•