Rather than having AutoRunParallelTask call a function that mostly has to interact with GCRuntime, it's more sensible to make this call a GCRuntime method via member function pointer. The syntax is a little gross but this means we can get rid of a few friend declarations that were only necessary to allow these functions access to GCRuntime again.
Differential Revision: https://phabricator.services.mozilla.com/D64147
--HG--
extra : moz-landing-system : lando
This was previously turned from a virtual method into a function pointer because of threading concerns (destroying an instance of a class with virtual methods will write to the vtable before calling superclass destructors which may cause race conditions). However this concern is moot since we made runTask() virtual so that it could be used by XPCOM thread pools. The concern about race conditions is handled by an assertion in the GCParallelTask destructor.
Differential Revision: https://phabricator.services.mozilla.com/D64146
--HG--
extra : moz-landing-system : lando
Once we use BaseScript as the root type, we can combine the ScriptQuery
result vectors which will be concatenated anyways.
Depends on D64124
Differential Revision: https://phabricator.services.mozilla.com/D64125
--HG--
extra : moz-landing-system : lando
This can be combined with the Debugger::scripts map since keys will not
conflict. This is now all possible since we use js::BaseScript as the root
type.
Depends on D64123
Differential Revision: https://phabricator.services.mozilla.com/D64124
--HG--
extra : moz-landing-system : lando
Replace with calls to wrapScript instead. Within wrapScript we now check if
script is lazy or not. This paves way to removing LazyScript* from the
DebuggerReferentVariant.
Depends on D64122
Differential Revision: https://phabricator.services.mozilla.com/D64123
--HG--
extra : moz-landing-system : lando
This lets us eventually combine the lazy and non-lazy lists. To make this
work, we need to explicitly pass the expected type of variant element instead
of deducing it from the map.
Differential Revision: https://phabricator.services.mozilla.com/D64122
--HG--
extra : moz-landing-system : lando
- Simplify js::CheckDebugeeThing
- Simplify DelazifyScript
- Inline js::EnsureFunctionHasScript into callers and avoid using
JSFunction::nonLazyScript() method.
Depends on D64119
Differential Revision: https://phabricator.services.mozilla.com/D64120
--HG--
extra : moz-landing-system : lando
In Bug 1512509 we simplified BaseScript::sourceObject() to never use
cross-compartment edges. As a result we can simplify the debugger access of
sourceObject within this patch.
Differential Revision: https://phabricator.services.mozilla.com/D64119
--HG--
extra : moz-landing-system : lando
This makes sure we will detect use of the contents of moved GC things during the update phase of the GC, not just when we return to the mutator as previously. Annoyingly we need to preserve contents for native objects with fixed elements because the elements flags are stored there and these may be accessed from other objects if they are COW elements.
This caught a use of unforwarded scripts during invalidation caused by OOM during sweeping type information.
Differential Revision: https://phabricator.services.mozilla.com/D63872
--HG--
extra : moz-landing-system : lando
This has just enough code to be able to compile a "return 0;" function,
including off-thread MIR building.
The new builder consists of two parts:
* WarpOracle: runs on the main thread, produces a WarpSnapshot.
* WarpBuilder: can run off-thread, uses the WarpSnapshot to generate MIR.
WarpOracle will make a lot of the optimization decisions (which scripts can be
compiled, which ICs are copied, which functions we want to inline). WarpBuilder
will do 'just' MIR building.
This is an early prototype; the code is expected to change significantly the
coming weeks/months.
Differential Revision: https://phabricator.services.mozilla.com/D64013
--HG--
extra : moz-landing-system : lando
There is a possible race condition between CacheFile::OnFileOpened() called on the cache I/O thread as a result of calling CacheFileIOManager::OpenFile() and CacheFile::EntryWouldExceedLimit() and CacheFile::SetMemoryOnly(), both called on main thread from CacheEntry::OpenOutputStream(). Both methods now grab the CacheFile's lock to synchronize the access.
Differential Revision: https://phabricator.services.mozilla.com/D63826
--HG--
extra : moz-landing-system : lando
This makes sure we will detect use of the contents of moved GC things during the update phase of the GC, not just when we return to the mutator as previously. Annoyingly we need to preserve contents for native objects with fixed elements because the elements flags are stored there and these may be accessed from other objects if they are COW elements.
This caught a use of unforwarded scripts during invalidation caused by OOM during sweeping type information.
Differential Revision: https://phabricator.services.mozilla.com/D63872
--HG--
extra : moz-landing-system : lando
Uses a reinterpret_cast so we don't need to include `JSFunction.h` in this
header.
Differential Revision: https://phabricator.services.mozilla.com/D64034
--HG--
extra : moz-landing-system : lando
If we try to wrap an inner whose outer has navigated out of process,
then we'll get a remote window proxy, not a window proxy.
This was happening during the JS devtools test
browser_webconsole_block_mixedcontent_securityerrors.js
Differential Revision: https://phabricator.services.mozilla.com/D64217
--HG--
extra : moz-landing-system : lando