Closed Bug 1214133 Opened 9 years ago Closed 9 years ago

Preload ExtensionContent.jsm

Categories

(Firefox OS Graveyard :: Runtime, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(firefox44 fixed)

RESOLVED FIXED
FxOS-S9 (16Oct)
Tracking Status
firefox44 --- fixed

People

(Reporter: ting, Unassigned)

References

Details

(Keywords: perf)

Attachments

(1 file)

In the profile at bug 1210860 comment 9, before loading app content it spends ~120ms on Flame to load frame script extensions.js, most of time spend on importing ExtensionContent.jsm. Preload it to get some improvements.

Note ExtensionContent.init() sends async message through PBrowser to chrome process.
Attached patch patch v1Splinter Review
Comment on attachment 8672998 [details] [diff] [review]
patch v1

With this patch, it now takes ~10ms on Flame for RecvLoadRemoteScript() to run extensions.js.

Since PBrowserChild hasn't been constructed when preload, leave ExtensionContent.init() in the frame script (extensions.js), otherwise sending async message will cause abort.
Attachment #8672998 - Flags: review?(fabrice)
Attachment #8672998 - Flags: review?(fabrice) → review+
https://hg.mozilla.org/mozilla-central/rev/9b32f246edaf
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → FxOS-S9 (16Oct)
Keywords: perf
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: