Closed
Bug 1350544
Opened 8 years ago
Closed 3 years ago
appcache does mainthread I/O
Categories
(Core :: Networking: HTTP, defect, P3)
Tracking
()
RESOLVED
INACTIVE
Performance Impact | low |
People
(Reporter: Kokujou, Unassigned)
References
Details
(Keywords: perf, Whiteboard: [necko-next])
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:55.0) Gecko/20100101 Firefox/55.0
Build ID: 20170324030205
Steps to reproduce:
i used whatsapp web to test it. Firefox nearly freezes for a few seconds, till i can finally enter something.
i tried the security mode with disabled addons,
plus i disabled every browser plugin.
just disabling e10 makes it faster again.
my computer is more than capable of e10.
Comment 1•8 years ago
|
||
Please see https://developer.mozilla.org/en-US/docs/Mozilla/Performance/Reporting_a_Performance_Problem for more information. Thanks!
Flags: needinfo?(Kokujou)
Profiler Exception: TypeError: this._profiler.getSharedLibraryInformation is not a function
Flags: needinfo?(Kokujou)
Comment 3•8 years ago
|
||
Hi Kokujou,
I tested WhatsApp.com on Windows 10 with latest nightly. But I could manage to reproduce the issue.
Could you try it again the steps mentioned in comment 1 link? Thanks
Flags: needinfo?(Kokujou)
as i said before. i got an exception when using the addon. i used it and it just crashed with the reported error.
Flags: needinfo?(Kokujou)
Comment 6•8 years ago
|
||
@Kokujou, I got the same error using that profile addon. The document (comment 1) is now updated with the latest version of the addon.
I also able to reproduce the issue, but it happens intermittently.
Here is screen capture: https://testing-1.tinytake.com/sf/MTQ2MzgxNF81MTgxMzY1
Profile: https://perfht.ml/2mSYiVE
Status: UNCONFIRMED → NEW
Component: Untriaged → DOM: Content Processes
Ever confirmed: true
Product: Firefox → Core
Comment 7•8 years ago
|
||
Whoaaaa - I think I'm seeing main thread disk IO here:
https://perf-html.io/public/d72a2bfc2505bfdf7a2619e25cac8b237fe45910/calltree/?range=129.4271_139.5150~132.7714_137.7396&thread=0
This looks like... Necko stuff? nsOfflineCacheDevice or something? And storage?
Hey jduell, know who I should point this profile at?
Flags: needinfo?(jduell.mcbugs)
Whiteboard: [qf]
Comment 8•8 years ago
|
||
This is the appcache, which we've been keeping on life-support till we can kill it. But Whatsapp and a few other major sites are still using it (including Microsoft's Office online version--see bug 1312646--and some IBM email cloud service IIRC).
Honza is the only person who knows this code and he's out till Tuesday.
It looks like we're getting OnDataAvailable on the main thread and doing at least two updates to the SQLite appcache database :(
That said I'm puzzled that turning off e10s fixes this--I suspect there's something else going on, because I assume this same main thread I/O happens in non-e10s too.
Honza, if there isn't some obvious small-ish fix to move this off-thread let's at least get some telemetry so we know how bad this winds up being on average.
Flags: needinfo?(jduell.mcbugs) → needinfo?(honzab.moz)
Updated•8 years ago
|
Summary: Firefox even slower with e10 → appcache slower with e10s on
Comment 9•8 years ago
|
||
I don't think this is e10s related. Appcache does main thread IO, always did and there is no simple fix to it. The profile shows an appcache update running which updates to the database.
We could make the output stream of an appcache entry be a pipe copying the data on a stream transport thread. but that would just make a heavy concurrent access to sqlite. not a simple fix.
Tho, we could think of speeding up the database. There could be done something like memory caching (provided by sqlite) or WAL journal mode. Get inspired with StorageDBThread::SetJournalMode and StorageDBThread::ConfigureWALBehavior
Flags: needinfo?(honzab.moz)
Updated•8 years ago
|
Whiteboard: [qf] → [qf:p3]
Updated•8 years ago
|
Component: DOM: Content Processes → Networking: HTTP
Summary: appcache slower with e10s on → appcache does mainthread I/O
Updated•8 years ago
|
Whiteboard: [qf:p3] → [qf:p3][necko-next]
Comment 10•7 years ago
|
||
Bulk change to priority: https://bugzilla.mozilla.org/show_bug.cgi?id=1399258
Priority: -- → P2
Comment 11•6 years ago
|
||
Moving to p3 because no activity for at least 1 year(s).
See https://github.com/mozilla/bug-handling/blob/master/policy/triage-bugzilla.md#how-do-you-triage for more information
Priority: P2 → P3
Updated•6 years ago
|
Updated•5 years ago
|
Updated•3 years ago
|
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → INACTIVE
Updated•3 years ago
|
Performance Impact: --- → P3
Whiteboard: [qf:p3][necko-next] → [necko-next]
You need to log in
before you can comment on or make changes to this bug.
Description
•