Sketchfab frame rate is too slow in FxR on Oculus Go
Categories
(Core :: JavaScript: GC, defect, P2)
Tracking
()
| Performance Impact | low |
People
(Reporter: cpeterson, Unassigned)
References
()
Details
(Whiteboard: [geckoview:fxr:p1][webvr])
| Reporter | ||
Comment 1•7 years ago
|
||
| Reporter | ||
Comment 2•7 years ago
|
||
| Reporter | ||
Comment 3•7 years ago
|
||
| Reporter | ||
Comment 4•7 years ago
|
||
Updated•7 years ago
|
Comment 5•7 years ago
|
||
Updated•7 years ago
|
Comment 6•7 years ago
|
||
Updated•7 years ago
|
Comment 7•7 years ago
|
||
Comment 8•7 years ago
|
||
Comment 9•7 years ago
|
||
Comment 10•7 years ago
|
||
Comment 11•7 years ago
|
||
| Reporter | ||
Comment 12•7 years ago
|
||
Updated•7 years ago
|
Comment 13•7 years ago
|
||
Comment 14•7 years ago
|
||
Comment 15•7 years ago
|
||
Comment 16•7 years ago
|
||
Comment 17•7 years ago
|
||
Updated•7 years ago
|
Updated•7 years ago
|
Comment 18•7 years ago
|
||
Comment 19•7 years ago
|
||
Comment 20•7 years ago
|
||
Comment 21•7 years ago
|
||
(In reply to Paul Bone [:pbone] from comment #20)
In the profile in comment 13 we've got an incremental GC that lasts for 25 seconds. That's way too long and we need to look at ways to mitigate this, for example to increasing slice budget if the GC runs for too long (see bug 1434542). However most GC slices were reasonable and within budget with the exception of the first GC slice. This one spends a lot of time freeing memory in minor GC. We can probably do that off-thread (bug 1518193), although that may lead to lock contention on allocation.
Also the profile seems to suggest that nsJSContext::GarbageCollectNow is calling arena_t::Purge, but I can't find any evidence of that in the code. This is called from MozJemalloc::jemalloc_free_dirty_pages which is run on memory pressure events. If we're in a low memory situation then we can expect degraded performance.
take a look at https://perfht.ml/2SFNZQD
35% of this is in arena_t::Purge again.
8% of this is in gray marking which is now incremental, so the situation may be slightly better now. 10% is in marking weak references which Steve is working on making incremental (bug 1167452). ~8% is discarding JIT code and there's a bug for throwing less of that away (bug 1514281).
(In reply to Kannan Vijayan [:djvj] from comment #19)
Also, I don't know what those periodic grey regions in the profile are - there is no stack information available there at all - what are we doing?
Kannan, I'm not sure what you're referring to here.
Comment 22•7 years ago
|
||
(In reply to Jon Coppeard (:jonco) from comment #21)
Also the profile seems to suggest that nsJSContext::GarbageCollectNow is calling arena_t::Purge, but I can't find any evidence of that in the code. This is called from MozJemalloc::jemalloc_free_dirty_pages
Oh, this is also called when deallocating memory. I'm still not sure why the stack looks like it does, but it turns out that any free can cause jemalloc to decide it needs to decommit unused memory which can take a long time. It would be great if this could happen on another thread, or incrementally, or without holding a lock the entire time.
Updated•7 years ago
|
Comment 23•7 years ago
|
||
Already highlighted in email, but this is a critical issue to resolve for Firefox Reality and we would very much like this to be a P1 if at all possible. Andreas Bovens is aware of the discussions around this topic as well.
Comment 24•7 years ago
|
||
Let me look into this.
Comment 25•6 years ago
|
||
I just tested sketchfab with latest FxR and performance has actually become worse. Gecko still become completely unresponsive where it is unable to load a new page, or even go back.
Comment 26•6 years ago
|
||
Randall, Do you have a profile for today's test. It would be good to see if it's the same problems as before or new problems.
Especially since some things have changed in the GC to make it more incremental.
Thanks.
Comment 27•6 years ago
|
||
I haven't been able to get a profile. Since Gecko becomes unresponsive for so long the remote profiler loses connection and doesn't capture anything.
Comment 28•6 years ago
|
||
Oh damn, sorry I should have realised that.
Updated•4 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•1 year ago
|
Description
•