Aligns emitOptionalElemExpression() with emitOptionalDotExpression(), so it's
easier to compare both methods against each other.
Differential Revision: https://phabricator.services.mozilla.com/D61155
--HG--
extra : moz-landing-system : lando
The previous list contained some invalid entries (`await` and comma-expression)
and was missing some possible parse node kinds.
Differential Revision: https://phabricator.services.mozilla.com/D61154
--HG--
extra : moz-landing-system : lando
The child node of a DeleteOptionalChainExpr node can't be a super-property
accessor, so we can remove this code.
Drive-by: Reindent some stack comments.
Differential Revision: https://phabricator.services.mozilla.com/D61152
--HG--
extra : moz-landing-system : lando
Moves the `isSuper()` method from the base class to the (non-optional) derived
classes, because `super?.x` isn't valid syntax, so it's confusing to be able to
ask if an optional property access is applied on `super`.
The next part will further simplify `BytecodeEmitter::emitDelete{Element,Property}InOptChain()`.
Differential Revision: https://phabricator.services.mozilla.com/D61151
--HG--
extra : moz-landing-system : lando
We already assert that this case isn't allowed in the bytecode emitter. Also
report a syntax error to match normal property access.
Differential Revision: https://phabricator.services.mozilla.com/D61146
--HG--
extra : moz-landing-system : lando
Restricted to Nightly so we can enable it by default in tandem with enabling
the same option in NumberFormat and DateTimeFormat.
Differential Revision: https://phabricator.services.mozilla.com/D60959
--HG--
extra : moz-landing-system : lando
This patch mainly enables the pref for SharedArrayBuffer on early Beta. (We have
already enabled that on Nightly by default)
This change causes some tests to fail. This patch handles the failures for
a mochitest and web-platform-tests.
Differential Revision: https://phabricator.services.mozilla.com/D60965
--HG--
extra : moz-landing-system : lando
The proposal specifies class fields as follows:
FieldDefinition[Yield, Await]:
ClassElementName[?Yield, ?Await] Initializer[In, ~Yield, ~Await]opt
This means that await shouldn't be parsed according to the context
where the class is defined: it should always be parsed as an
identifier inside initializers.
Differential Revision: https://phabricator.services.mozilla.com/D58721
--HG--
extra : moz-landing-system : lando
Related to bug 1608121.
When we use Ion and WebAssembly, we might get multiple return values
from function calls. This patch refactors the direct JS-to-Wasm-via-Ion
call path to better support multiple values.
The patch adds a safepoint at the call, as appears to be necessary in
general, and also when results are captured as MIR values. There is a
slight optimization in that void-returning Wasm functions just get a
MConstant result that's visible to the optimizer.
Differential Revision: https://phabricator.services.mozilla.com/D60228
--HG--
extra : moz-landing-system : lando
This adds a JS API to set a performance hint which tells the engine whether a global is in pageload or not. The engine keeps a count so it knows whether any global for that runtime is in pageload, and adjusts GC thresholds appropriately. Currently this strongly discourages atoms GC by doubleing the trigger threshold. This does not disallow it entirely, but with this change it should almost never happen.
This is meant to be a temporary fix. When the stencil project lands we will not have this annoying dependency between parsing and atoms zone GC and can remove this change.
Differential Revision: https://phabricator.services.mozilla.com/D60972
--HG--
extra : moz-landing-system : lando
This makes it easier to update test262, because it's no longer required to
manually mark each WeakRef test in js/src/tests/jstests.list.
Differential Revision: https://phabricator.services.mozilla.com/D60512
--HG--
extra : moz-landing-system : lando
Update test262 to pick up the changed `eval` in parameter expressions tests.
Differential Revision: https://phabricator.services.mozilla.com/D60510
--HG--
extra : moz-landing-system : lando
Removes the direct eval calls, because they're now leading to SyntaxErrors when
attempting to redeclare existing parameters.
Differential Revision: https://phabricator.services.mozilla.com/D60509
--HG--
extra : moz-landing-system : lando
The specification installs the implicit "arguments" binding in the same
lexical environment as the other parameters, but our implementation requires an
extra check to report this redeclaration SyntaxError.
Differential Revision: https://phabricator.services.mozilla.com/D60508
--HG--
extra : moz-landing-system : lando
BytecodeEmitter.cpp:
The normal `DestructuringFlavor::Declaration` can now be used for destructuring
parameter declarations.
Scope.cpp:
The function scope now always acts as a variable scope, even when parameter
expression are present, so we need to set the `QUALIFIED_VAROBJ` flag
unconditionally.
Differential Revision: https://phabricator.services.mozilla.com/D60500
--HG--
extra : moz-landing-system : lando
Related to bug 1608121.
When we use Ion and WebAssembly, we might get multiple return values
from function calls. This patch refactors the direct JS-to-Wasm-via-Ion
call path to better support multiple values.
The patch adds a safepoint at the call, as appears to be necessary in
general, and also when results are captured as MIR values. There is a
slight optimization in that void-returning Wasm functions just get a
MConstant result that's visible to the optimizer.
Differential Revision: https://phabricator.services.mozilla.com/D60228
--HG--
extra : moz-landing-system : lando
Cranelift fails this assertion and it's not clear to me that there is any restriction inside
Cranelift that would limit the set of registers we'd need to check here.
Differential Revision: https://phabricator.services.mozilla.com/D58887
--HG--
extra : moz-landing-system : lando
This commit adds support for receiving stackmaps from Cranelift
and converting to wasm::Stackmaps. [1] will change the stackmap
representation in Cranelift to be the same as in Spidermonkey.
The stack overflow/interrupt trap handler stackmap is implemented by
sharing code with Ion.
[1] https://github.com/bytecodealliance/cranelift/pull/1317
Differential Revision: https://phabricator.services.mozilla.com/D58886
--HG--
extra : moz-landing-system : lando
cranelift-wasm cannot express arbitrary control flow inside of
'global.get/set' easily. This makes it difficult to implement the pre/post write
barriers inline like the baseline compiler does.
[1] has a discussion about the ideal solution to problem, which involves a new IR
concept called templates. We will want to use that when it is ready.
In the short-term, this commit implements pre/post write barriers using slow OOL
functions and implements Wasm globals.
[1] https://github.com/bytecodealliance/cranelift/issues/1176
Differential Revision: https://phabricator.services.mozilla.com/D58885
--HG--
extra : moz-landing-system : lando
This commit translates the basic parts of reference types that does not
require any barriers. AnyRef,FuncRef,NullRef are translated to R32/R64. The
existing bulk-memory instructions are extended to operate on multiple tables,
and the new reference type instructions are implemented with instance calls.
Differential Revision: https://phabricator.services.mozilla.com/D58884
--HG--
extra : moz-landing-system : lando
This commit changes the wasm compiler feature detection bits to report that
cranelift supports reference types.
Differential Revision: https://phabricator.services.mozilla.com/D58883
--HG--
extra : moz-landing-system : lando
It used to be that some XPIDL interfaces were allowed to be non-nsISupports,
and were only used to hold a bunch of constants. It appears that we've now
had enough de-COM work happen that there are no longer any, so we can remove
support for this.
Differential Revision: https://phabricator.services.mozilla.com/D61008
--HG--
extra : moz-landing-system : lando
For builtinclass interfaces, or ones not declared in IDL, we don't call out
into scripted QueryInterface anyway, so we can return earlier, before we ever
set up the AutoEntryScript.
Differential Revision: https://phabricator.services.mozilla.com/D61005
--HG--
extra : moz-landing-system : lando
Cranelift fails this assertion and it's not clear to me that there is any restriction inside
Cranelift that would limit the set of registers we'd need to check here.
Differential Revision: https://phabricator.services.mozilla.com/D58887
--HG--
extra : moz-landing-system : lando
This commit adds support for receiving stackmaps from Cranelift
and converting to wasm::Stackmaps. [1] will change the stackmap
representation in Cranelift to be the same as in Spidermonkey.
The stack overflow/interrupt trap handler stackmap is implemented by
sharing code with Ion.
[1] https://github.com/bytecodealliance/cranelift/pull/1317
Differential Revision: https://phabricator.services.mozilla.com/D58886
--HG--
extra : moz-landing-system : lando
cranelift-wasm cannot express arbitrary control flow inside of
'global.get/set' easily. This makes it difficult to implement the pre/post write
barriers inline like the baseline compiler does.
[1] has a discussion about the ideal solution to problem, which involves a new IR
concept called templates. We will want to use that when it is ready.
In the short-term, this commit implements pre/post write barriers using slow OOL
functions and implements Wasm globals.
[1] https://github.com/bytecodealliance/cranelift/issues/1176
Differential Revision: https://phabricator.services.mozilla.com/D58885
--HG--
extra : moz-landing-system : lando
This commit translates the basic parts of reference types that does not
require any barriers. AnyRef,FuncRef,NullRef are translated to R32/R64. The
existing bulk-memory instructions are extended to operate on multiple tables,
and the new reference type instructions are implemented with instance calls.
Differential Revision: https://phabricator.services.mozilla.com/D58884
--HG--
extra : moz-landing-system : lando
This commit changes the wasm compiler feature detection bits to report that
cranelift supports reference types.
Differential Revision: https://phabricator.services.mozilla.com/D58883
--HG--
extra : moz-landing-system : lando