Commit Graph

72160 Commits

Author SHA1 Message Date
Benjamin Bouvier
7f699ce0f7 Bug 1569137: Use the baldrdash calling convention for libcall expansion; r=jseward
Differential Revision: https://phabricator.services.mozilla.com/D40610

--HG--
extra : moz-landing-system : lando
2019-08-13 17:05:48 +00:00
Csoregi Natalia
1ee00996bb Backed out changeset 14a3fb05168b (bug 1568397) for JS raptor crashes. CLOSED TREE 2019-08-13 18:55:37 +03:00
Benjamin Bouvier
295364cd6e Bug 1573409: Use Strings for Cranelift unsupported error messages; r=lth
Differential Revision: https://phabricator.services.mozilla.com/D41722

--HG--
extra : moz-landing-system : lando
2019-08-13 11:56:15 +00:00
Benjamin Bouvier
94d74e6608 Bug 1573409: Bump Cranelift to b2c69b1d032626c67f685080dbf6971d3b9ffa43; r=lth
Differential Revision: https://phabricator.services.mozilla.com/D41721

--HG--
extra : moz-landing-system : lando
2019-08-13 11:55:37 +00:00
Ryan Hunt
67ed68f992 Bug 1546138 - Wasm: Implement 'ref.func'. r=bbouvier
This commit implements the 'ref.func' instruction by emitting an instance call
to WasmInstanceObject::getExportedFunction.

The referenced function must be used in an element segment to validate.
See [1] for more details.

[1] https://github.com/WebAssembly/reference-types/issues/31

Differential Revision: https://phabricator.services.mozilla.com/D40586

--HG--
extra : moz-landing-system : lando
2019-08-13 13:29:21 +00:00
Ryan Hunt
5ad66b00c3 Bug 1546138 - Wasm: Print assertion message when wasm-testharness assertion fails. r=bbouvier
Differential Revision: https://phabricator.services.mozilla.com/D41655

--HG--
extra : moz-landing-system : lando
2019-08-13 13:26:24 +00:00
André Bargull
5fd7bafba0 Bug 1573152: Use NewbornArrayPush to append values to new arrays. r=jwalden
Differential Revision: https://phabricator.services.mozilla.com/D41544

--HG--
extra : moz-landing-system : lando
2019-08-13 11:37:49 +00:00
Ryan Hunt
c92a5dc91d Bug 1573434 - Wasm: Add missing reference types test guard to 'declared-segs.js'. r=bbouvier
Differential Revision: https://phabricator.services.mozilla.com/D41753

--HG--
extra : moz-landing-system : lando
2019-08-13 13:20:24 +00:00
André Bargull
ae4d1be023 Bug 1573112: Add accessors for private slot values to remaining Intl objects. r=khyperia
And use [gs]etFixedSlot instead of [gs]etReservedSlot per review comment in D27083.

Differential Revision: https://phabricator.services.mozilla.com/D41520

--HG--
extra : moz-landing-system : lando
2019-08-12 20:21:01 +00:00
Jan de Mooij
f4903d08bd Bug 1568397 part 1 - Fix definite properties analysis to use the correct group for constraints. r=iain,tcampbell
We now add information about the constraints to a new class (DPAConstraintInfo)
so we can then finish all constraints at the end. This is also nice to avoid
adding unnecessary constraints when the analysis fails.

Differential Revision: https://phabricator.services.mozilla.com/D40444

--HG--
extra : moz-landing-system : lando
2019-08-13 10:04:55 +00:00
Jan de Mooij
ecf39cceb8 Bug 1572385 - Check raw flags_ field offset in JSString::staticAsserts to fix 64-bit big-endian platforms. r=tcampbell
The length_ and flags_ fields are private so I added a protected offsetOf* accessor.

Differential Revision: https://phabricator.services.mozilla.com/D41353

--HG--
extra : moz-landing-system : lando
2019-08-12 12:33:48 +00:00
Benjamin Bouvier
f035c1f50a Bug 1571230: Allow inf in wasmTextToBinary without a sign prefix; r=jseward
Differential Revision: https://phabricator.services.mozilla.com/D41517

--HG--
extra : moz-landing-system : lando
2019-08-13 09:16:12 +00:00
Jon Coppeard
f0e2079090 Bug 1573125 - Make JS_MaybeGC consider all zones r=sfink?
Depends on D41606

Differential Revision: https://phabricator.services.mozilla.com/D41607

--HG--
extra : moz-landing-system : lando
2019-08-13 05:03:25 +00:00
Jon Coppeard
992d6b6ce5 Bug 1570905 - Rework the GC triggers to make the incremental trigger the default and the non-incremental trigger some factor of this r=sfink?
Differential Revision: https://phabricator.services.mozilla.com/D41606

--HG--
extra : moz-landing-system : lando
2019-08-13 08:40:36 +00:00
Jon Coppeard
8b73371be0 Bug 1407593 - Report embedding leaks of JS GC things r=sfink,sfink?
Patch to report JS GC things that are live at shutdown as leaks by calling MOZ_LOG_CTOR for them. The JS engine now clears any remaining roots to prevent dangling pointers to freed memory after shutdown. I made XPCJSRuntime::Shutdown keep the weak pointer update callbacks as sometimes these tables have entries remaining at shutdown (if there are leaks) and we need the callbacks to update them.

This is looking more green on try now.

Differential Revision: https://phabricator.services.mozilla.com/D40449

--HG--
extra : moz-landing-system : lando
2019-08-13 08:31:49 +00:00
Ryan Hunt
772a0b5c03 Bug 1559963 - Wasm: Add basic tests for declared element segments. r=bbouvier
Testing declared segments is a bit tricky until we support
'ref.func'. For now, I've written some basic tests.

Differential Revision: https://phabricator.services.mozilla.com/D40585

--HG--
extra : moz-landing-system : lando
2019-08-12 22:27:49 +00:00
Ryan Hunt
79bfc8c3be Bug 1559963 - Wasm: Update spec tests for bulk-memory#98. r=bbouvier
As the following commit explained, this change isn't backwards compatible with
the existing implementation and the spec tests needed to be modified.

I've written a stub commit to the spec interpreter to encode/decode element
segments well enough to pass the current spec tests, and did another
import of the tests. The commit can be found here [1] [2].

[1] https://github.com/eqrion/spec/tree/spidermonkey-tree-tests
[2] d81e3cfe6e

Differential Revision: https://phabricator.services.mozilla.com/D40584

--HG--
extra : moz-landing-system : lando
2019-08-12 22:30:15 +00:00
Ryan Hunt
563bbf7b09 Bug 1559963 - Wasm: Update in-tree tests for bulk-memory#98. r=bbouvier
The element segment changes are backwards compatible with the MVP, but not the
existing implementation. Some tests needed to update their expectations or
binary encoding.

Differential Revision: https://phabricator.services.mozilla.com/D40583

--HG--
extra : moz-landing-system : lando
2019-08-12 22:21:21 +00:00
Ryan Hunt
f6fe16593e Bug 1559963 - Wasm: Update wasmTextToBinary for bulk-memory#98. r=bbouvier
Issue: https://github.com/WebAssembly/bulk-memory-operations/issues/98

This commit updates the encoding of element segments to the latest bulk-memory
proposal. This is backwards compatible with the MVP, but a breaking change from
the previously implemented bulk-memory spec.

The following semantic differences are made with the new encoding.
  1. The introduction of 'Declared' segments
    * Declared segments allow a Wasm module to forward declare which
      functions are aliasable by ref.func. See reference-types#31 for more
      information.
  2. Whether an element expression or function indices are encoded now depends
     on an independent flag from the 'kind' of an element segment.
  3. The definition kind or element expression type is now explicitly encoded
     in the element segment.

Differential Revision: https://phabricator.services.mozilla.com/D40582

--HG--
extra : moz-landing-system : lando
2019-08-12 22:31:17 +00:00
Ryan Hunt
da9af79283 Bug 1559963 - Wasm: Update decoding of element segments for bulk-memory#98. r=bbouvier
Issue: https://github.com/WebAssembly/bulk-memory-operations/issues/98

This commit updates the decoding of element segments to the latest bulk-memory
proposal. This is backwards compatible with the MVP, but a breaking change from
the previously implemented bulk-memory spec.

The following semantic differences are made with the new encoding.
  1. The introduction of 'Declared' segments
    * Declared segments allow a Wasm module to forward declare which
      functions are aliasable by ref.func. See reference-types#31 for more
      information.
  2. Whether an element expression or function indices are encoded now depends
     on an independent flag from the 'kind' of an element segment.
  3. The definition kind or element expression type is now explicitly encoded
     in the element segment.

A following commit will update the in-tree wat2wasm encoder.

Differential Revision: https://phabricator.services.mozilla.com/D40581

--HG--
extra : moz-landing-system : lando
2019-08-12 22:37:15 +00:00
Steve Fink
e1bc970332 Bug 1572065 - Avoid assertion when OOMing with test mark queue, r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D41460

--HG--
extra : moz-landing-system : lando
2019-08-10 07:44:04 +00:00
Steve Fink
a1032d4fd8 Bug 1570161 - do not attempt to mark things gray if they cannot be marked gray r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D41468

--HG--
extra : moz-landing-system : lando
2019-08-10 07:48:51 +00:00
André Bargull
268981bb20 Bug 1539780: Remove "--with-intl-api=build" build config option. r=jwalden
There are about the same number of occurrences of "ENABLE_INTL_API" and "EXPOSE_INTL_API"
in the tree, so preferring one over the other doesn't lead to fewer changes. Therefore
I went with "ENABLE_INTL_API", because "ENABLE_" (resp. "MOZ_ENABLE") is already used as
the prefix for other preprocessor ifdef's.

Differential Revision: https://phabricator.services.mozilla.com/D41188

--HG--
extra : moz-landing-system : lando
2019-08-09 19:43:19 +00:00
Andy Wingo
706d0e26b7 Bug 1572714 - Fix TypedObject/bigint test when TypedObject unavailable r=jandem
Differential Revision: https://phabricator.services.mozilla.com/D41569

--HG--
extra : moz-landing-system : lando
2019-08-12 15:31:42 +00:00
Benjamin Bouvier
344a794265 Bug 1571464: Only display the function's IR in info level when Cranelift fails; r=jseward
The gczeal test change was added because to make it more deterministic, after
it started failing in automation following this change.

Differential Revision: https://phabricator.services.mozilla.com/D40650

--HG--
extra : moz-landing-system : lando
2019-08-12 15:47:53 +00:00
Jon Coppeard
d21beb7f9e Bug 1572782 - Remove unused js::FreeOp alias and remaining references r=tcampbell?
Differential Revision: https://phabricator.services.mozilla.com/D41413

--HG--
extra : moz-landing-system : lando
2019-08-12 12:35:11 +00:00
Jon Coppeard
6c416aec4d Bug 1572782 - Replace internal use of js::FreeOp with JSFreeOp r=tcampbell?
Sorry for the huge patch.  This is pretty much a search and replace of all uses of js::FreeOp.

Differential Revision: https://phabricator.services.mozilla.com/D41412

--HG--
extra : moz-landing-system : lando
2019-08-12 10:43:51 +00:00
Jon Coppeard
4f45eff7cc Bug 1572782 - Remove external references to js::FreeOp r=mccr8?
Replace external use of js::FreeOp with JSFreeOp.

Differential Revision: https://phabricator.services.mozilla.com/D41411

--HG--
extra : moz-landing-system : lando
2019-08-12 10:43:32 +00:00
Jon Coppeard
a00726d223 Bug 1572782 - Remove js::FreeOp and make JSFreeOp opaque in public API r=tcampbell?
Merge js::FreeOp and JSFreeOp, but alias the former to the latter while we fix uses.

Differential Revision: https://phabricator.services.mozilla.com/D41410

--HG--
extra : moz-landing-system : lando
2019-08-12 10:43:32 +00:00
Oana Pop Rus
44aafcc0d0 Backed out 4 changesets (bug 1572782) for build bustages at build/src/obj-firefox/dist/include/nsIXPCScriptable.h on a CLOSED TREE
Backed out changeset ec9d15c69bc8 (bug 1572782)
Backed out changeset 8239e4baa0f4 (bug 1572782)
Backed out changeset 9fd7bea2b512 (bug 1572782)
Backed out changeset 11d750555fe1 (bug 1572782)
2019-08-12 13:37:03 +03:00
Jon Coppeard
fa84e34044 Bug 1572782 - Remove unused js::FreeOp alias r=tcampbell?
Differential Revision: https://phabricator.services.mozilla.com/D41413

--HG--
extra : moz-landing-system : lando
2019-08-12 10:16:04 +00:00
Jon Coppeard
8186c345e2 Bug 1572782 - Replace internal use of js::FreeOp with JSFreeOp r=tcampbell?
Sorry for the huge patch.  This is pretty much a search and replace of all uses of js::FreeOp.

Differential Revision: https://phabricator.services.mozilla.com/D41412

--HG--
extra : moz-landing-system : lando
2019-08-12 10:16:02 +00:00
Jon Coppeard
68fef4ffb0 Bug 1572782 - Remove external references to js::FreeOp r=mccr8?
Replace external use of js::FreeOp with JSFreeOp.

Differential Revision: https://phabricator.services.mozilla.com/D41411

--HG--
extra : moz-landing-system : lando
2019-08-12 10:16:00 +00:00
Jon Coppeard
9d51a35e93 Bug 1572782 - Remove js::FreeOp and make JSFreeOp opaque in public API r=tcampbell?
Merge js::FreeOp and JSFreeOp, but alias the former to the latter while we fix uses.

Differential Revision: https://phabricator.services.mozilla.com/D41410

--HG--
extra : moz-landing-system : lando
2019-08-12 10:15:57 +00:00
Henri Sivonen
ed1e9fd632 Bug 1572364 - Make jsrust_shared a non-optional dependency of gkrust-shared. r=bbouvier
Differential Revision: https://phabricator.services.mozilla.com/D41163

--HG--
extra : moz-landing-system : lando
2019-08-09 17:32:29 +00:00
Paul Bone
b7a967139e Bug 1569924 - Run ./mach clang-format -p js/src r=sfink
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D39987

--HG--
extra : moz-landing-system : lando
2019-08-12 03:27:23 +00:00
Jan de Mooij
4d5c0d5eb6 Bug 1570259 part 5 - Remove AutoSetHelperThreadContext from off-thread Ion and Wasm tasks. r=tcampbell,luke
Off-thread tasks now use a pool of JSContexts (for compatibility with the XPCOM thread pool).
Tasks that don't need a JSContext can run without one (nullptr TlsContext). We can now do this
for Ion and Wasm tasks too.

Depends on D41380

Differential Revision: https://phabricator.services.mozilla.com/D41381

--HG--
extra : moz-landing-system : lando
2019-08-09 15:27:10 +00:00
Jan de Mooij
23cbbf5845 Bug 1570259 part 4 - Make AutoUnsafeCallWithABI work without a TlsContext. r=tcampbell
Some functions that are called from the Ion backend use AutoUnsafeCallWithABI.

Initially I wanted to fix this by splitting these functions in two separate
functions, but this doesn't work well for all the Math builtins that are called
by GVN.

Depends on D41379

Differential Revision: https://phabricator.services.mozilla.com/D41380

--HG--
extra : moz-landing-system : lando
2019-08-09 14:41:27 +00:00
Jan de Mooij
3fd18f4434 Bug 1570259 part 3 - Move some fields from JSContext to JitContext. r=tcampbell
This will allow us to run off-thread Ion tasks without a JSContext.

I renamed IonCompiling and IonCompilation to IonBackend to make it
clearer that this doesn't include IonBuilder time.

Differential Revision: https://phabricator.services.mozilla.com/D41379

--HG--
extra : moz-landing-system : lando
2019-08-11 09:05:23 +00:00
Jan de Mooij
93adc5cc85 Bug 1570259 part 2 - Group JitContext fields and use new initializer syntax. r=luke
Depends on D41377

Differential Revision: https://phabricator.services.mozilla.com/D41378

--HG--
extra : moz-landing-system : lando
2019-08-09 15:26:35 +00:00
Jan de Mooij
883264b018 Bug 1570259 part 1 - Document and clean up JitContext constructors. r=luke
The next patch will simplify the constructor code a bit more.

Differential Revision: https://phabricator.services.mozilla.com/D41377

--HG--
extra : moz-landing-system : lando
2019-08-09 15:26:03 +00:00
Jan de Mooij
541cfda7f5 Bug 1552154 part 6 - Remove BaselineScript's pc-to-native map. r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D40949

--HG--
extra : moz-landing-system : lando
2019-08-10 10:21:34 +00:00
Jan de Mooij
85db9b40c2 Bug 1552154 part 5 - Stop using pc-to-native map for BaselineScript::toggleDebugTraps. r=tcampbell
Because DebugTrapEntries are only present if the script has debugger instrumentation
it should be fine to store this as a simple list of entries.

Differential Revision: https://phabricator.services.mozilla.com/D40948

--HG--
extra : moz-landing-system : lando
2019-08-10 10:21:20 +00:00
Jan de Mooij
e6fbf15029 Bug 1552154 part 4 - Stop using pc-to-native map for BaselineScript::approximatePcForNativeAddress. r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D40947

--HG--
extra : moz-landing-system : lando
2019-08-10 10:21:00 +00:00
Jan de Mooij
99451ccd92 Bug 1552154 part 3 - Stop using pc-to-native map for BaselineScript::computeResumeNativeOffsets. r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D40946

--HG--
extra : moz-landing-system : lando
2019-08-10 10:20:41 +00:00
Jan de Mooij
d69bf865df Bug 1552154 part 2 - Stop using pc-to-native map for OSR into Baseline JIT. r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D40945

--HG--
extra : moz-landing-system : lando
2019-08-10 10:20:27 +00:00
Jan de Mooij
d870ef9328 Bug 1552154 part 1 - Use mozilla::Span<> in BaselineScript, clean up RetAddrEntry code a bit. r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D40944

--HG--
extra : moz-landing-system : lando
2019-08-10 10:20:08 +00:00
Steve Fink
e79384d24c Bug 1572207 - Update AutoStableStringChars comment, r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D41421

--HG--
extra : moz-landing-system : lando
2019-08-09 20:41:12 +00:00
Andrew McCreight
9550144327 Bug 1572781 - Stop doing cross-origin navigation in XPConnect browser tests. r=kmag
These tests both load a page, create some chrome reference to it, then
navigate to another page to cause a window close on the original page,
then check to make sure the references to the original page have gone
away.

With Fission, if the navigation is cross-process, then the message
manager gets torn down in the original process where the browser test
is running, and the sendAsyncMessage call in content-task.js fails
with the cryptic error NS_ERROR_ILLEGAL_VALUE.

This can be fixed by making the navigation not be cross-origin. The
test only wants the original pages to be torn down. The origin of the
new page doesn't matter.

Differential Revision: https://phabricator.services.mozilla.com/D41408

--HG--
extra : moz-landing-system : lando
2019-08-09 20:08:08 +00:00
Jim Blandy
715bf97a70 Bug 1569080: Correct #includes in js/src/debugger. r=jorendorff
These changes were produced using the Include What You Use tool, which uses the
Clang front end to figure out which headers actually declare the identifiers
you're using.

These changes aren't exactly the ones IWYU suggests. The tool has some odd false
positives, even when you use its 'pragmas' to tell it about headers like
jsapi.h, which is supposed to gather up other headers for you. And there are
some cases where I could get away with a forward declaration (say, for Maybe),
but I really just want to #include the full header because it seems better. But
overall this patch has only minor deviations from IWYU's suggestions.

No intended change in execution or visible behavior.

Differential Revision: https://phabricator.services.mozilla.com/D39446

--HG--
extra : moz-landing-system : lando
2019-08-08 23:20:21 +00:00