Parallel marking performs worse on some non-parallelizable workloads
Categories
(Core :: JavaScript: GC, task, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox111 | --- | fixed |
People
(Reporter: jonco, Assigned: jonco)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
When running microbenchmarks I've found that parallel marking performs worse than single threaded marking for some non-parallelisable workloads, and the performance gets even worse when more than two threads are used.
For example, marking a single array of 2000000 strings takes ~15% longer with two threads and ~80% longer with four threads.
Such cases are unlikely to dominate marking time in the browser but are still a concern.
Assignee | ||
Updated•1 year ago
|
Assignee | ||
Comment 1•1 year ago
|
||
Currently non-parallelizable workloads can perform worse with parallel marking
enabled, particularly with more than two threads. This is because we end up
stealing very frequently when there is no advantage to doing so and this
interrupts marking progress.
I tested several approaches to fixing this but the one that worked best was
simply to disallow stealing from very small stacks.
Depends on D167783
Pushed by jcoppeard@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e4ed68012454 Don't allow parallel marking to steal from very small stacks r=sfink
Comment 3•1 year ago
|
||
bugherder |
Description
•