This preference was requested by driver developers, simplifying
debugging processes. It is especially useful on Linux, but may
be handy on other platforms as well.
As a side effect it also ensures the two places with fallback paths
behave the same again on Android.
Depends on D128411
Differential Revision: https://phabricator.services.mozilla.com/D128592
The toolbar pref change triggers eventually a look-and-feel-changed
notification, so no need to observe that directly.
Depends on D128674
Differential Revision: https://phabricator.services.mozilla.com/D128675
Both `initFromTemplateObject()` methods are always returning `true`, so we might
as well change the return type to `void`.
Depends on D128765
Differential Revision: https://phabricator.services.mozilla.com/D128766
The other caller to `visitObjectGuard()` was removed when unboxed objects were
removed, so we can move the function back into `visitGuardShape()`.
Depends on D128764
Differential Revision: https://phabricator.services.mozilla.com/D128765
`ArgumentsReplacer::run()` ignores any resume points, so we can directly use
`MDefinitionIterator` to iterate over all definitions.
Differential Revision: https://phabricator.services.mozilla.com/D128764
`MLoadElementHole::needsHoleCheck` is never set to `false`.
Drive-by change:
- Remove two method declarations without definitions.
Differential Revision: https://phabricator.services.mozilla.com/D128762
We added a speculation barrier after calls into C++ from ICs (bug 1444473).
In hindsight, it seems we were overly cautious with the calls for megamorhic property
gets because the slot number comes from the shape's property map. This makes it very
different from the typical Spectre v1 attack with a user-controlled index into a
(typed) array, where the bounds check then gets delayed/speculated.
Furthermore, this happens in C++ code that's not user-controlled and it'd need a
large speculation window that includes the return to JIT code. There we have
additional mitigations when unboxing the returned Value.
This barrier has a large impact on performance: on a simple micro-benchmark it
increases our numbers from 75 ms to 170 ms on Linux x64, more than a 2x slowdown
for one of our hottest code paths. This makes it hard to justify keeping it.
Differential Revision: https://phabricator.services.mozilla.com/D128744
Document::GetBrowsingContext uses a WeakPtr<nsIDocShell> so we can't do
that. But we have all the other media emulation data and so on in the
pres context which we can access off the main thread for style, so move the
override code there.
Differential Revision: https://phabricator.services.mozilla.com/D128673
Most of the time we only sweep things in zones that are being swept, but there
are a couple of places where this isn't true. This fixes the sweeping tracer to
take account of that.
Differential Revision: https://phabricator.services.mozilla.com/D128758
On mips64, when 64-bit GPRs carrying 32-bit values, the upper bits are the sign extension
of the lower bits, and 32-bit instructions will check this invariant.
But on x64 and arm64, the upper bits are zero, and 32-bit instructions don't care about
the upper 32 bits of the inputs.
So when some 32-bit operations like mul32 are used, we should keep the inputs sign-extended.
And if we want a zero-extended 32-bit value, like for some bitwise operations, an explicit
zero-extension is needed.
Differential Revision: https://phabricator.services.mozilla.com/D128564
We used to use the ThirdPartyUtil::IsThirdPartyWindow() to check third
party if the document or the channel is not available. However, this
could be incorrect in the case where the channel is not available
because the WindowContext is not ready yet. To address this issue, we
use the browingContext of the document to check third party.
Differential Revision: https://phabricator.services.mozilla.com/D128601
Given that we use the partitioned Principal in the third-party context
and the loading principal won't have it, we should ignore the
partitionKey when doing the verfication.
Differential Revision: https://phabricator.services.mozilla.com/D127841
Currently, we use the script principal to verify the client to prevent
the principal forgery. After we moving to use foreign partitioned
principal for the Client, this no longer works. Instead, we can directly
use the client's principal to verify client.
Also, the patch rename StoragePrincipalHelper::VerifyValidStoragePrincipalInfoForPrincipalInfo() to
StoragePrincipalHelper::VerifyValidPartitionedPrincipalInfoForPrincipalInfo()
and fix a problem in the function that it should ignore the PartitionKey
instead of the FirstPartyDomain.
Differential Revision: https://phabricator.services.mozilla.com/D127840
Currently, the ServiceWorkerManager creates a content prinipcal based
on the regular originAttributes when dispatch the fetch event. This
patch changes to use the foreign partitioned originAttributs.
Note that we don't add tests for this because the change doesn't change
the behavior. And we don't enable partitioned third-party Service Worker.
So, the existing test cases is enough for this.
Differential Revision: https://phabricator.services.mozilla.com/D127632
To support foreign partitioned prinicpal for Client, we use
StoragePrincipalHelper::GetPrincipal() to get the foreign partitioned
principal from the channel in the ClientChannelHelper. And use it to
create client.
Differential Revision: https://phabricator.services.mozilla.com/D127631
Currently, we use the node principal to create clientSource in
nsGloblaWindowInner. This patch change this to use foreign partitioned
principal.
Differential Revision: https://phabricator.services.mozilla.com/D127630
Currently, we are using the regular principal and inherited regular
principal to create clientSource in nsDocShell. This patch makes the
nsDocshell to use the partitioned principal if needed.
Differential Revision: https://phabricator.services.mozilla.com/D127629
We implement
StoragePrincipalHelper::ShouldUsePartitionPrincipalForServiceWorker() to
help with deciding the principal needed to be used when creating a
initial clientSource in docShell.
Differential Revision: https://phabricator.services.mozilla.com/D127628
1. Don't return an error from IAccessible2::states. Otherwise, NVDA assumes the Accessible is defunct.
2. Return STATE_SYSTEM_READONLY for all documents in IAccessible::get_accState. Otherwise, NVDA doesn't treat the document as browseable.
Differential Revision: https://phabricator.services.mozilla.com/D128556