- Un-lazify the startup promises in ext-toolkit.js since the
manifest background property is handled asynchronously, so it
races with startup and can miss the relevant events if it
loses the race.
- Ensure that persistent events don't cause breakage when the
background-delayed-startup preference is set to false.
- Add a wakeup() method to the fire object provided to primed
listeners. This method returns a Promise that resolves when
the extension background page has started. Events that need to
do some work in the context of the extension can wait on the
result of wakeup(), then continue processing after the background
page is started, using fire.[a?]sync as normal.
MozReview-Commit-ID: HiYOguVdEQK
--HG--
extra : rebase_source : 249235553d591fec2110c213ab8b4637fe1aaf08
This consistently shows up in profiles as taking about 6-10ms during startup.
Part of the problem is that it loads TelemetrySession.jsm, which we can't fix.
Part of the problem is that the escaping and string manipulation it does is fairly expensive. We can cache the escaped values in addonStartup.jsm to avoid that.
A lot of the problem is that we call it every time we load a bootstrap scope, even though we already set the correct value before we start loading any bootstrapped scopes, and it doesn't change after that. We can avoid this by skipping the redundant calls during startup.
MozReview-Commit-ID: 68EWdnJdPvk
--HG--
extra : rebase_source : a2ad982214634304be5adc17661c9997fc94a708
extra : amend_source : aa2038ff9d655e8d5628c70615c04f7a5101fe28
Factored out common code between JSHistogram_Add and JSKeyedHistogram_Add
to get values from array, and handle case of single accumulation.
Uses type checking utility function introduced in bug 1428893.
--HG--
extra : rebase_source : 9a8cf6f192d457dae89142a8365a6c5fed7d2f96
This code is large and complex, and can only be called when we have an
AddonInternal object from XPIDatabase.jsm. It should live with that code.
MozReview-Commit-ID: 3ssV5aH9NUJ
--HG--
extra : rebase_source : d54474f67213420678706f04291b246ceee154de
extra : histedit_source : d1a3ca6fd05856a6675380717351e2e1d1568cf1
AddonInternal objects are only ever created after the database is loaded, so
there's no reason to load that code beforehand. More importantly, creating
the AddonWrapper class is expecially expensive, since most of their properties
are created dynamically. We should avoid doing that at startup when at all
possible.
MozReview-Commit-ID: AaRVN12e1qM
--HG--
extra : rebase_source : d5f9da1f8a54cdeecc45aa9857c6a6329821bb34
extra : histedit_source : 73c67373ad04a397bf9b2c2174c637f8ba645a95
The TelemetryEnvironment initialization process currently forces a load and
initialization of the blocklist service only to check its isLoaded flag. This
adds measurable overhead to startup, and without those checks, the service
would not be initialized until after first paint.
We should defer even checking whether the blocklist is loaded until after
startup has finished.
MozReview-Commit-ID: 73c4o5oVqze
--HG--
extra : rebase_source : f97ad4e9f2c96668b4418a1c7fb47a07bc798da7
extra : amend_source : 874240858529280e88f960e40920f009ccccfcbc
Don't free memory in exception handling context to avoid deadlocks
and process state corruption. Replace old_handler_.reset() with
old_handler_.release() to intentionally leak the sigaction struct instead.
MozReview-Commit-ID: lUNygOJCUL
--HG--
extra : rebase_source : 1f50b7d22cc2fa32d3e31125e563df6203a48612
proxyConfig set urls onto the pref rather than host names. This adds a round-trip test
with a test that uses the proxy after setting the config. Also fixes setting prefs
when httpProxyAll is true.
MozReview-Commit-ID: FpXKjnOXEkl
--HG--
extra : rebase_source : 885f43e6cc5b1d22081875eb8e5f7a0523ecf3d1
The about:memory page specified some colours using constants and others
using variables whose values can change. If those variables changed, for
example due to the desktop toolkit using a dark theme, then it could create
poor contrast with the constants in these CSS files (desktop & mobile).
This change ensures that only the Mozilla system colour extensions and
Mozilla colour preference extensions colours are used. Creating
fore/back-ground combinations that hopefully contrast well regardless of the
desktop theme.
--HG--
extra : rebase_source : f916aac0bb07c3a75ab45ece3fd58d1cdcf8bf46
extra : source : a78bc7ff3de5a0ea4aea060731253fed63a59d00