Closed
Bug 846895
(Contacts-Startup)
Opened 12 years ago
Closed 11 years ago
Long initial startup time for Contacts app
Categories
(Firefox OS Graveyard :: Gaia::Contacts, defect, P1)
Tracking
(blocking-b2g:-, b2g18 affected, b2g18-v1.0.0 wontfix, b2g18-v1.0.1 affected)
RESOLVED
FIXED
blocking-b2g | - |
People
(Reporter: godavari, Unassigned)
References
Details
(Whiteboard: ux-tracking)
Attachments
(1 obsolete file)
Contacts launch needs to be further optimized. We observed that the sorting for 500 contacts is taking around 500ms. Is there any way that we can do it asynchronously in the background while launch in parallel.
Currently sorting seems to be completely blocking all other operations and we donot see CPU spending on any operations.
Is there any we can hash it in DB instead of sorting during every launch?
Updated•12 years ago
|
Whiteboard: [caf-v1.0.1]
Reporter | ||
Comment 1•12 years ago
|
||
Current time seems to be approximately secs to launch with 200 secs. It takes 1.5 secs to launch the same Android. It would be good to see Contacts launching in 1.5 to <2 secs with 500 contacts in FFOS.
Reporter | ||
Comment 2•12 years ago
|
||
Current time seems to be approximately 3 secs to launch with 200 secs. It takes 1.5 secs to launch the same Android. It would be good to see Contacts launching in 1.5 to <2 secs with 500 contacts in FFOS.
Updated•12 years ago
|
Group: qualcomm-confidential
blocking-b2g: --- → tef+
Whiteboard: [caf-v1.0.1]
Comment 3•12 years ago
|
||
(In reply to godavari@codeaurora.org from comment #0)
> Contacts launch needs to be further optimized. We observed that the sorting
> for 500 contacts is taking around 500ms. Is there any way that we can do it
> asynchronously in the background while launch in parallel.
> Currently sorting seems to be completely blocking all other operations and
> we donot see CPU spending on any operations.
>
> Is there any we can hash it in DB instead of sorting during every launch?
We already do this with bug 836519. I think we only need to use it from gaia now.
Comment 4•12 years ago
|
||
(In reply to Gregor Wagner [:gwagner] from comment #3)
> We already do this with bug 836519. I think we only need to use it from gaia
> now.
Good point Gregor, our problem is that bug 836519 is a leo bug, not a tef+, which means it wasn't uplifted, and as far as I know this was decided cause time concerns.
If we want to use this fix we will need to rethink the risks of adding bug 836519 and any gaia modifications for v1.0.1
Cheers!
F.
Comment 5•12 years ago
|
||
(In reply to Francisco Jordano [:arcturus] from comment #4)>
> If we want to use this fix we will need to rethink the risks of adding bug
> 836519 and any gaia modifications for v1.0.1
>
Right. Who makes this call? mvines decided this is tef+.
Updated•12 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Comment 6•12 years ago
|
||
Ok just checked with gal. We should uplift the required patches.
Lets get a list of all required patches first.
Reuben, can you link to the required gecko patches?
Francisco, do we have a gaia patch that's ready?
Comment 7•12 years ago
|
||
So far :albertopq was trying the patch but as long as this wasn't going to be ready for 1.0.1 we didn't go forward.
We will take a look and will bring those changes back.
Cheers!
Comment 8•12 years ago
|
||
(In reply to Gregor Wagner [:gwagner] from comment #6)
> Reuben, can you link to the required gecko patches?
Bug 836513, bug 837917 and bug 836519. I advise uplifting bug 844274 as well, since it simplifies the code and fixes an intermittent orange, reducing the risk.
Bug 844558 has further optimizations, but hasn't even landed on m-c so I don't think we can take it.
Comment 9•12 years ago
|
||
I've been playing around with the new api and we will need to do some changes on the frontend.
Right now the first contact returns pretty quick (nice job folks!), but we will need to recode the way we render contacts, as waiting for all the contacts to come from the cursor is slower than asking for all of them without the cursor.
With that said we will need to start appending contacts to the list earlier.
Another interesting thing is that we need 1.3 seconds to load the config.json or either a 1 second when reading from indexeddb to check what's the order we are going to ask for.
We can try to do a an early read of this value, as early as possible, in order to not to wait that time since we start asking for contacts.
Cheers!
Comment 10•12 years ago
|
||
(In reply to Francisco Jordano [:arcturus] from comment #9)
> I've been playing around with the new api and we will need to do some
> changes on the frontend.
>
> Right now the first contact returns pretty quick (nice job folks!), but we
> will need to recode the way we render contacts, as waiting for all the
> contacts to come from the cursor is slower than asking for all of them
> without the cursor.
We should do that anyway, but getting all contacts shouldn't be slower with cursors. See the timings in bug 844274 comment 6.
Comment 11•12 years ago
|
||
(In reply to Reuben Morais [:reuben] from comment #10)
> We should do that anyway, but getting all contacts shouldn't be slower with
> cursors. See the timings in bug 844274 comment 6.
Nevermind, I was confused, I only just now landed that bug in b2g18, so if you update to grab that change, getting all contacts should be as fast or faster than find().
Definitely don't wait until you have all contacts. At the very least start rendering contacts once you have enough to fill the screen. The goal should be to make things fast, not just faster than what we have now.
(In reply to Francisco Jordano [:arcturus] from comment #9)
> Another interesting thing is that we need 1.3 seconds to load the
> config.json or either a 1 second when reading from indexeddb to check what's
> the order we are going to ask for.
I don't really follow this comment. What's in config.json or indexedDB that you need to load? Is it the user settings which control which order to render things?
Comment 13•12 years ago
|
||
> (In reply to Francisco Jordano [:arcturus] from comment #9)
>
> I don't really follow this comment. What's in config.json or indexedDB that
> you need to load? Is it the user settings which control which order to
> render things?
Exactly, we need to wait till we know the order for the contacts (this is a user setting) to ask for the correct order to be returned by the api.
Cheers.
Comment 14•12 years ago
|
||
We have to uplift the blocking patches. Ryan can you take care of it?
Whiteboard: checkin-needed
Comment 15•12 years ago
|
||
This meta bug is marked tef+ by partners, so we'll make a valid assumption that blocking bugs are tef+ as well.
Updated•12 years ago
|
Whiteboard: checkin-needed
Updated•12 years ago
|
Blocks: 1.0.1-perf
Updated•12 years ago
|
Assignee: nobody → alberto.pastor
Comment 16•12 years ago
|
||
For this to be a blocking bug we need some specific success criteria (i.e. startup time target and methodology). It cannot be resolved FIXED without a goal being met.
Comment 18•12 years ago
|
||
For Contacts app launch latency, the target is 1.5sec.
The latest measured value is 2.2sec.
Method of measurement.
- High speed camera is used to capture the frames at 240fps. The latency is measured as the time duration between the highlight of icon to Contacts App completely rendered the frame.
Flags: needinfo?(suryanar)
Comment 19•12 years ago
|
||
Thanks for the update. These numbers are for 1.0.1? How well do they correlate to the startup times as currently reported by the device (i.e. time to load under developer info)?
Comment 20•12 years ago
|
||
Yes, 1.0.1
Updated•12 years ago
|
Whiteboard: u=user c=contacts s=ux-most-wanted
Updated•12 years ago
|
Alias: Contacts-Startup
Comment 21•12 years ago
|
||
Is this really blocking given https://bugzilla.mozilla.org/show_bug.cgi?id=851126#c1? :)
blocking-b2g: tef+ → tef?
Comment 22•12 years ago
|
||
Yeah, still blocking as we're looking to achieve ~1.5ms app start time with 500 contacts, as comment 1 describes.
blocking-b2g: tef? → tef+
Comment 23•12 years ago
|
||
https://datazilla.allizom.org/b2g says we are under 1 sec. How are you measuring it?
Comment 25•12 years ago
|
||
Pinged via email for response.
Reporter | ||
Comment 26•12 years ago
|
||
As mentioned in comment 18
Method of measurement.
- High speed camera is used to capture the frames at 240fps. The latency is measured as the time duration between the highlight of icon to Contacts App completely rendered the frame.
Our test team uses email configured (with upto 100 mails in inbox). I think datazilla numbers number are without email configuration. Someone needs to confirm.
We use the same methodology (configured email from icon highlight to screen update with email entries) to measure latencies in other OSs like Android aswell.
Flags: needinfo?(godavari)
Comment 27•12 years ago
|
||
How are we going to reconcile the differences between what datazilla is showing and what's being measured in comment 26?
Comment 28•12 years ago
|
||
Datazilla is actually correct.
In datazilla, you essentially need to add the "startup_load_time" and the "above-the-fold-ready" (which is only available for the contacts app, and is not very reliable yet). When you add both, you get the delay until Contacts actually displays the first contacts.
We may change the "above-the-fold-ready" measurement at one point to be more reliable and to include the time since the startup.
Comment 29•12 years ago
|
||
(In reply to Julien Wajsberg [:julienw] from comment #28)
> Datazilla is actually correct.
>
> In datazilla, you essentially need to add the "startup_load_time" and the
> "above-the-fold-ready" (which is only available for the contacts app, and is
> not very reliable yet). When you add both, you get the delay until Contacts
> actually displays the first contacts.
>
> We may change the "above-the-fold-ready" measurement at one point to be more
> reliable and to include the time since the startup.
Have we hit our goal then? Surya - please file a new bug with how much we're off by in your most recent v1.0.1 tests.
blocking-b2g: tef+ → -
Flags: needinfo?(suryanar)
Comment 30•12 years ago
|
||
I think we're not there yet but I know some work is ongoing on this topic.
Comment 31•12 years ago
|
||
Pointer to Github pull-request
Comment 32•12 years ago
|
||
Comment on attachment 735720 [details]
Pointer to Github pull request: https://github.com/mozilla-b2g/gaia/pull/9088
See performance testing at
https://gist.github.com/albertopq/5354452
Attachment #735720 -
Flags: review?(francisco.jordano)
Comment 33•12 years ago
|
||
Comment on attachment 735720 [details]
Pointer to Github pull request: https://github.com/mozilla-b2g/gaia/pull/9088
Incredible boost to the performance.
Great job!
Attachment #735720 -
Flags: review?(francisco.jordano) → review+
Comment 34•12 years ago
|
||
Alberto could you post some numbers in terms of performance to have some data to ask for tef+?
Thanks!
blocking-b2g: - → tef?
status-b2g18:
--- → affected
status-b2g18-v1.0.0:
--- → wontfix
status-b2g18-v1.0.1:
--- → affected
Comment 35•12 years ago
|
||
Dough!, numbers already in comment 32
So worthy to uplift :)
Comment 36•12 years ago
|
||
Updated•12 years ago
|
blocking-b2g: tef? → tef+
Comment 37•12 years ago
|
||
blocking-b2g: tef+ → -
Comment 38•12 years ago
|
||
bug 848188 is nearly ready to land, mvines, can you please test performance with that bug (even if it has not landed yet) and let us know if that would be OK to meet our performance targets and if it is not OK, how far are we from them?
Flags: needinfo?(mvines)
Comment 39•12 years ago
|
||
Lets get the bug 848188 landed asap and we'll test then.
Flags: needinfo?(mvines)
Comment 40•12 years ago
|
||
Hi Michael, this is a improvement that can be test without bug 848188, anyway, this already landed yesterday.
So we have both improvements on master.
Cheers,
F.
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Comment 41•12 years ago
|
||
Comment on attachment 735720 [details]
Pointer to Github pull request: https://github.com/mozilla-b2g/gaia/pull/9088
Removing patch from metabug
Attachment #735720 -
Attachment is obsolete: true
Comment 42•12 years ago
|
||
Sorry guys, reopening as this is a meta bug.
Anyway as I commented bug 846895 already landed on master. We can try there.
Cheers!
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Updated•12 years ago
|
Whiteboard: u=user c=contacts s=ux-most-wanted → ux-tracking
Updated•11 years ago
|
Assignee: alberto.pastor → nobody
New bug for same issue: https://bugzilla.mozilla.org/show_bug.cgi?id=871823
Flags: needinfo?(suryanar)
Comment 44•11 years ago
|
||
Should we close this one then ?
Comment 45•11 years ago
|
||
+1 to closing it :)
Comment 46•11 years ago
|
||
All the interesting information happens on Bug 871823 now.
Putting back resolved/fixed.
Status: REOPENED → RESOLVED
Closed: 12 years ago → 11 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•