RESOLVED INVALID 180338
Speedometer grows the heap linearly and leaves ~200MB of unreclaimed memory when it finishes
https://bugs.webkit.org/show_bug.cgi?id=180338
Summary Speedometer grows the heap linearly and leaves ~200MB of unreclaimed memory w...
Filip Pizlo
Reported 2017-12-03 14:47:25 PST
It's runs/sec also degrade as we proceed through the iterations, presumably because GCs start to take a really long time. Hilariously, if you "test again", we will keep growing the heap. Dunno if it's a leak in Speedometer or in our engine. Making it a JSC bug for now.
Attachments
Ryosuke Niwa
Comment 1 2017-12-03 21:05:59 PST
Hm... we should probably check the leak in other engines like Chrome to see if this is a benchmark issue vs engine issue.
Radar WebKit Bug Importer
Comment 2 2017-12-12 15:53:09 PST
Ryosuke Niwa
Comment 3 2017-12-15 13:49:46 PST
I've measured this in Chrome using heap snapshots. Their memory usage starts off at ~4MB then goes up to ~24MB but stabilizes around that range at the end. I've also monitored the process's memory usage, and they do go up to ~200MB but stays there the whole time, and re-running the test doesn't increased the memory usage.
Ryosuke Niwa
Comment 4 2017-12-15 14:00:12 PST
I've also measured this in Firefox. Their memory usages starts off around 500MB and goes up to ~580MB. In the second run, however, it can go up to ~680MB despite of the fact their usage temporarily dropped to ~510MB at the beginning of the test. The leak memory usage in the third run is stays around ~720MB but then drops to 520MB if I wait ~5s after the test had finished running. So I suspect this isn't the same leak we're seeing but more about their memory getting fragmented over time, or that their GC/malloc holding onto more pages in later runs.
Ryosuke Niwa
Comment 5 2017-12-20 19:41:08 PST
As far as I can tell, we're leaking every window object in both Speedometer 1 & Speedometer 2.
Ryosuke Niwa
Comment 6 2018-01-10 17:21:39 PST
Saam and I looked into this, and we can no longer reproduce it. It looks like this reproduces when Inspector is open so it's possible we both had Web Inspector open when we did the measurement? Regardless, there isn't anything actionable here.
Joseph Pecoraro
Comment 7 2018-01-10 19:06:03 PST
If this is Web Inspector only, does the memory at least get reclaimed when Web Inspector closes?
Saam Barati
Comment 8 2018-01-10 19:07:34 PST
(In reply to Joseph Pecoraro from comment #7) > If this is Web Inspector only, does the memory at least get reclaimed when > Web Inspector closes? Yes, we think it's inspector only. The memory does get reclaimed after a few seconds when inspector closes.
Note You need to log in before you can comment on or make changes to this bug.