We need to call `processAssertions` before we append `moduleRequests_` because
the append will invoke the `StencilModuleRequest` copy constructor.
Differential Revision: https://phabricator.services.mozilla.com/D167489
This caches weather suggestion l10n strings by adding `cacheable: true` to the
view update object returned by the provider. Doing so hooks into UrlbarView's
dynamic result type functionality [here](https://searchfox.org/mozilla-central/rev/738b761bb2847f609f9cacc550680071cdc53637/browser/components/urlbar/UrlbarView.sys.mjs#1737-1739).
w/r/t l10n strings and caching, weather suggestions are a bit of a new case
because most of these strings take arguments that can't be known in advance and
that will change over time. For a string with arguments, L10nCache creates a
cache key by concating the string's ID and the values of its arguments. That
makes sense for strings whose values are things like search engine names, where
the set of possible argument values is small and where we may need to show
different translated strings when for example the search engine changes. For
those strings, we want to cache the translated strings separately using
different keys.
Weather suggestion strings like "20°C" are a different story. The ideal UX for
these strings is: While the UI is waiting for the string to be re-localized with
new argument values, it should show the previous localized string with the old
argument values. If the argument values have changed, there will still be some
flicker as the old values are replaced with the new ones, but it's the best we
can do, and at least there won't be empty space in the UI.
This isn't possible with L10nCache right now due to how it creates cache keys,
as mentioned earlier. So I added a new option that tells it to cache strings by
ID only, excluding argument values. That way only one translated string is
cached regardless of whatever argument values it was cached with.
Differential Revision: https://phabricator.services.mozilla.com/D167318
I'm about to extend them for bug 1811486, where I want to force in some
cases the rolled up popups to hide synchronously. These APIs use a ton
of boolean arguments that make them error prone, so refactor them a bit
to use strongly typed enums and flags.
Differential Revision: https://phabricator.services.mozilla.com/D167381
For how much it may sound strange, sometimes all the reads just happen before
the write, so they won't see the table.
Also fixes a wrong check on previousException.
Differential Revision: https://phabricator.services.mozilla.com/D167478
These addons either no longer work with our custom element wrapper, or never really worked:
* backgrounds - isn't super useful because it doesn't follow theme and now doesn't have any visible effect
* mesaure - this one breaks when you click on it, it seems to be looking for a specific root element
* outline - this stil works on the docs page but isn't really useful on the main story page anymore
Differential Revision: https://phabricator.services.mozilla.com/D167295
The wasm baseline compiler slows down significantly when compiling code that
has extensive need of stack maps, for example the Dart-Barista benchmark.
This is because StackMapGenerator::createStackMap spends a lot of time
iterating over a vector of booleans, one element at a time, to identify
reftyped stack slots.
This patch gives `class MachineStackTracker` its own iterator class `Iter` to
hide the details. This provides fast(er) iteration by scanning backwards
through the vector of booleans until the scan-index becomes 8-aligned. After
that, it jumps backwards in steps of 8 elements to the extent possible.
For a --no-threads --wasm-compiler=baseline compilation only of Barista 3,
this reduces compilation time from 0.110 to 0.082 user seconds (Intel Core i5
1135G7).
Differential Revision: https://phabricator.services.mozilla.com/D167288
The crash was caused by us loading `http://a.b.c.XN--pokxncvks/`
Because we searched for xn-- case sensitively, the first time around
the URL would parse, and would be lowercased, but when deserializing
the nsIPrincipal we would then fail to parse it.
Differential Revision: https://phabricator.services.mozilla.com/D166649
I'm about to extend them for bug 1811486, where I want to force in some
cases the rolled up popups to hide synchronously. These APIs use a ton
of boolean arguments that make them error prone, so refactor them a bit
to use strongly typed enums and flags.
Differential Revision: https://phabricator.services.mozilla.com/D167381