Closed
Bug 1222652
Opened 10 years ago
Closed 5 years ago
Investigate scheduling delays causing low frame rate in open/close tabs tray animation
Categories
(Firefox for Android Graveyard :: General, defect)
Tracking
(Not tracked)
RESOLVED
INCOMPLETE
People
(Reporter: mcomella, Unassigned)
References
Details
Attachments
(1 file)
|
3.99 MB,
text/html
|
Details |
I ran a systrace for the tabs tray on my GS4 and the frames are not being scheduled at 60 FPS. When I checked one set of frames, they were scheduled 31ms apart (as opposed to 16ms, which is 60 FPS). W There is an alert in systrace which reads:
Work to produce this frame was descheduled for several milliseconds, contributing to jank. Ensure that code on the UI thread doesn't block on work being done on other threads, and that background threads (doing e.g. network or bitmap loading) are running at android.os.Process#THREAD_PRIORITY_BACKGROUND or lower so they are less likely to interrupt the UI thread. These background threads should show up with a priority number of 130 or higher in the scheduling section under the Kernel process.
---
In looks like the `performTraversals` call may be taking too long and throwing off the frame timing.
| Reporter | ||
Comment 1•10 years ago
|
||
(In reply to Michael Comella (:mcomella) from comment #0)
> In looks like the `performTraversals` call may be taking too long and
> throwing off the frame timing.
The tool highlights the time from the `performTraversals` call to its completion, even if its not actively being run on the thread.
It looks like the `performTraversals` call is initially interrupted before it can draw by a `wmLayout` call from another process and each is labeled, "Binder_X" where X is 1-9 or A-F.
| Reporter | ||
Comment 2•10 years ago
|
||
I took another trace and now the UIThread priority is the same (it was lower before) as several other calls: Binder_*, Compiler, BgHangManager, adbd, mmcqd/0, etc. Unclear if this is related.
I started digging into the `performTransversals` method via Traceview and found that BinderProxy.transact is called 71 times, uses 0.111ms of CPU time but 1.865ms of wall time – that's 124ms of sleep time, which is enough to throw off a few frames. I also see the following in the logcat when opening the tabs tray:
11-06 20:16:52.050 E/DatabaseUtils( 3035): java.lang.SecurityException: Permission Denial: get/set setting for user asks to run as user -2 but is calling from user 0; this requires android.permission.INTERACT_ACROSS_USERS_FULL
11-06 20:16:52.050 E/DatabaseUtils( 3035): at com.android.server.am.ActivityManagerService.handleIncomingUser(ActivityManagerService.java:14673)
11-06 20:16:52.050 E/DatabaseUtils( 3035): at android.app.ActivityManager.handleIncomingUser(ActivityManager.java:2473)
11-06 20:16:52.050 E/DatabaseUtils( 3035): at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:688)
11-06 20:16:52.050 E/DatabaseUtils( 3035): at android.content.ContentProvider$Transport.call(ContentProvider.java:325)
11-06 20:16:52.050 E/DatabaseUtils( 3035): at android.content.ContentProviderNative.onTransact(ContentProviderNative.java:275)
11-06 20:16:52.050 E/DatabaseUtils( 3035): at android.os.Binder.execTransact(Binder.java:404)
11-06 20:16:52.050 E/DatabaseUtils( 3035): at dalvik.system.NativeStart.run(Native Method)
| Reporter | ||
Comment 3•10 years ago
|
||
An alternative route to investigate: disable/remove/hide the LayerView so it won't affect the animation and see if the animation is smooth.
Snorp, is this possible? If so, how might I do it?
Flags: needinfo?(snorp)
| Reporter | ||
Comment 4•10 years ago
|
||
Also, if you know any reason why a Binder (which looks like its running `wmLayout` might be taking over our UIThread, suspending our `performTraversals` call from executing, please let me know!
Comment 5•10 years ago
|
||
Yeah, the wmLayout stuff is from positioning the SurfaceView (which is in the LayerView). You can try hiding the LayerView, should help.
Flags: needinfo?(snorp)
Comment 6•5 years ago
|
||
We have completed our launch of our new Firefox on Android. The development of the new versions use GitHub for issue tracking. If the bug report still reproduces in a current version of [Firefox on Android nightly](https://play.google.com/store/apps/details?id=org.mozilla.fenix) an issue can be reported at the [Fenix GitHub project](https://github.com/mozilla-mobile/fenix/). If you want to discuss your report please use [Mozilla's chat](https://wiki.mozilla.org/Matrix#Connect_to_Matrix) server https://chat.mozilla.org and join the [#fenix](https://chat.mozilla.org/#/room/#fenix:mozilla.org) channel.
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → INCOMPLETE
| Assignee | ||
Updated•5 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•