зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1188620 - Use PersistentRooted for asyncActivation roots; r=fitzgen
--HG-- extra : rebase_source : 9b568b6b35b9090efaf1f10ba473cfee2db298ab
This commit is contained in:
Родитель
bdba9805ec
Коммит
cc3fc648da
|
@ -320,12 +320,6 @@ js::gc::GCRuntime::markRuntime(JSTracer* trc, TraceOrMarkRuntime traceOrMark)
|
|||
MarkPersistentRootedChains(trc);
|
||||
}
|
||||
|
||||
if (rt->asyncStackForNewActivations)
|
||||
TraceRoot(trc, &rt->asyncStackForNewActivations, "asyncStackForNewActivations");
|
||||
|
||||
if (rt->asyncCauseForNewActivations)
|
||||
TraceRoot(trc, &rt->asyncCauseForNewActivations, "asyncCauseForNewActivations");
|
||||
|
||||
if (rt->scriptAndCountsVector) {
|
||||
ScriptAndCountsVector& vec = *rt->scriptAndCountsVector;
|
||||
for (size_t i = 0; i < vec.length(); i++)
|
||||
|
|
|
@ -135,8 +135,8 @@ JSRuntime::JSRuntime(JSRuntime* parentRuntime)
|
|||
profilerSampleBufferGen_(0),
|
||||
profilerSampleBufferLapCount_(1),
|
||||
asmJSActivationStack_(nullptr),
|
||||
asyncStackForNewActivations(nullptr),
|
||||
asyncCauseForNewActivations(nullptr),
|
||||
asyncStackForNewActivations(this),
|
||||
asyncCauseForNewActivations(this),
|
||||
asyncCallIsExplicit(false),
|
||||
entryMonitor(nullptr),
|
||||
parentRuntime(parentRuntime),
|
||||
|
|
|
@ -691,12 +691,12 @@ struct JSRuntime : public JS::shadow::Runtime,
|
|||
* New activations will reset this to nullptr on construction after getting
|
||||
* the current value, and will restore the previous value on destruction.
|
||||
*/
|
||||
js::SavedFrame* asyncStackForNewActivations;
|
||||
JS::PersistentRooted<js::SavedFrame*> asyncStackForNewActivations;
|
||||
|
||||
/*
|
||||
* Value of asyncCause to be attached to asyncStackForNewActivations.
|
||||
*/
|
||||
JSString* asyncCauseForNewActivations;
|
||||
JS::PersistentRooted<JSString*> asyncCauseForNewActivations;
|
||||
|
||||
/*
|
||||
* True if the async call was explicitly requested, e.g. via
|
||||
|
|
Загрузка…
Ссылка в новой задаче