The results in https://datazilla.mozilla.org/b2g shows the time until apploadtime event fires for apps cold start. In my test, the apploadtime event often fire twice when we cold start an app. If this is a bug, we probably need to fix this or we cannot rely on it to record the cold start time.
Hi all, This is because sometimes we may receive 'mozbrowserloadend' event twice in window_manager.js Here is a simple path (test code) that will remove the event handler after it receive the 'mozbrowserloadend' event to measure the app loading time. https://github.com/RudyLu/gaia/commit/89f9eeca99d4f61634143a4c4fd13a77102b7ff9 However, we might need to dig into the root cause of why this event would be triggered twice. Hi Vivien, Do you think this patch is reasonable or who should we ping to get the real fix if you don't think this is the right way to do?
I feel like this happens because we preload a process in Gecko and during this phase we're loading about:blank. I wonder if this about:blank is what you see as the first loadend event. If I'm right you should not be able to see the first loadend event if you wait five seconds between each runs.
Dominic, is this still a problem or should we close this bug?
Whiteboard: [c= ]
Mike, I think we should close this one because the performance matic in https://datazilla.mozilla.org/b2g seems normal for all the apps, I filed this one was because the results will be very different if we launch and kill apps repeatedly, and looks like some patch has fixed it so we can close it.
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.