[regression] UI blocks for >3 seconds in PlacesUtils.getMostRecentBookmarkForURI

VERIFIED FIXED

Status

Firefox for Android Graveyard
General
--
major
VERIFIED FIXED
8 years ago
5 years ago

People

(Reporter: mbrubeck, Assigned: mbrubeck)

Tracking

({main-thread-io, perf, regression})

Trunk
ARM
Android
main-thread-io, perf, regression

Details

Attachments

(1 attachment)

(Assignee)

Description

8 years ago
Using recent Fennec nightlies on Android (for at least the past week), the UI freezes and becomes completely unresponsive for several hundred milliseconds during each page load.
(Assignee)

Updated

8 years ago
tracking-fennec: --- → ?
Each pageload does trigger some Places code, both internally and in our front end. For example, we check to see if the page is bookmarked and if so, we toggle the "star".
(Assignee)

Comment 2

8 years ago
I verified that the updateStar function frequently takes 3-5 seconds (!) to return on my Galaxy Tab with a large profile, and this seems to correspond with the page loads where the UI is unresponsive.
Summary: [regression] Fennec UI is unresponsive for around .5 to 1 second during page load → [regression] UI blocks for >3 seconds in PlacesUtils.getMostRecentBookmarkForURI
(Assignee)

Comment 3

8 years ago
It looks like Minefield recently fixed this in bug 613477; we can the same PlacesUtils code to fix it in Fennec.
Assignee: nobody → mbrubeck
Severity: normal → major
Depends on: 613477
Using PlaceUtils.asyncGetBookmarkIds  ?
(Assignee)

Comment 5

8 years ago
Created attachment 500247 [details] [diff] [review]
patch

Use async bookmark lookup during page load.  This fixes the problem for me on desktop and device.  Bookmark tests still pass with this patch (on desktop).
Attachment #500247 - Flags: review?(mark.finkle)
Attachment #500247 - Flags: review?(mark.finkle) → review+
(Assignee)

Comment 6

8 years ago
http://hg.mozilla.org/mobile-browser/rev/5efd73e3566d
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → FIXED
I, for one, love our new async overlords.
*and* this appears to have gotten us a Ts win (at last on Tracemonkey), which is expected since you aren't doing synchronous I/O on the GUI thread during startup anymore!

Fennec may even want to whitelist the default home page so that no lookup is done (we whitelisted about:blank in PlacesUtils code).
The browser certainly doesn't hang for >3 seconds, but there's a very noticeable hang for ~1 sec once the title and favicon are updated for the page and content is loading onto the window. 

The pages I tried and found this issue on are:

www.espn.com
www.facebook.com
bugzilla.mozilla.org

The pages I tried and did NOT find this issue on are:

addons.mozilla.org
about:firefox

Also, there's a noticeable hang when going to the controls panel as well which I think it related to this. Should I file another bug here?
Status: RESOLVED → VERIFIED
Keywords: regressionwindow-wanted
tracking-fennec: ? → ---
You need to log in before you can comment on or make changes to this bug.