зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1304672: Undo the renaming of debuggerObservesAsmJS => Wasm; r=luke
MozReview-Commit-ID: 1vxk30n72Zf --HG-- extra : rebase_source : a0c10b97e85866da3cbf97470949e053dc22c44b extra : amend_source : 547f9565c5faf34bbb85562d2d0cb797890befa4
This commit is contained in:
Родитель
7b122bb90d
Коммит
741775d8f1
|
@ -3893,7 +3893,7 @@ JS::CompileOptions::CompileOptions(JSContext* cx, JSVersion version)
|
|||
werrorOption = cx->options().werror();
|
||||
if (!cx->options().asmJS())
|
||||
asmJSOption = AsmJSOption::Disabled;
|
||||
else if (cx->compartment()->debuggerObservesWasm())
|
||||
else if (cx->compartment()->debuggerObservesAsmJS())
|
||||
asmJSOption = AsmJSOption::DisabledByDebugger;
|
||||
else
|
||||
asmJSOption = AsmJSOption::Enabled;
|
||||
|
|
|
@ -1088,7 +1088,7 @@ JSCompartment::updateDebuggerObservesFlag(unsigned flag)
|
|||
MOZ_ASSERT(isDebuggee());
|
||||
MOZ_ASSERT(flag == DebuggerObservesAllExecution ||
|
||||
flag == DebuggerObservesCoverage ||
|
||||
flag == DebuggerObservesWasm);
|
||||
flag == DebuggerObservesAsmJS);
|
||||
|
||||
GlobalObject* global = zone()->runtimeFromMainThread()->gc.isForegroundSweeping()
|
||||
? unsafeUnbarrieredMaybeGlobal()
|
||||
|
|
|
@ -556,7 +556,7 @@ struct JSCompartment
|
|||
enum {
|
||||
IsDebuggee = 1 << 0,
|
||||
DebuggerObservesAllExecution = 1 << 1,
|
||||
DebuggerObservesWasm = 1 << 2,
|
||||
DebuggerObservesAsmJS = 1 << 2,
|
||||
DebuggerObservesCoverage = 1 << 3,
|
||||
DebuggerNeedsDelazification = 1 << 4
|
||||
};
|
||||
|
@ -567,7 +567,7 @@ struct JSCompartment
|
|||
static const unsigned DebuggerObservesMask = IsDebuggee |
|
||||
DebuggerObservesAllExecution |
|
||||
DebuggerObservesCoverage |
|
||||
DebuggerObservesWasm;
|
||||
DebuggerObservesAsmJS;
|
||||
|
||||
void updateDebuggerObservesFlag(unsigned flag);
|
||||
|
||||
|
@ -709,7 +709,7 @@ struct JSCompartment
|
|||
// parsing are disabled.
|
||||
//
|
||||
// Whether AOT wasm is disabled is togglable by the Debugger API. By
|
||||
// default it is disabled. See debuggerObservesWasm below.
|
||||
// default it is disabled. See debuggerObservesAsmJS below.
|
||||
//
|
||||
// 2. When a compartment's debuggerObservesAllExecution() == true, all of
|
||||
// the compartment's scripts are considered debuggee scripts.
|
||||
|
@ -758,12 +758,12 @@ struct JSCompartment
|
|||
// Note that since AOT wasm functions cannot bail out, this flag really
|
||||
// means "observe wasm from this point forward". We cannot make
|
||||
// already-compiled wasm code observable to Debugger.
|
||||
bool debuggerObservesWasm() const {
|
||||
static const unsigned Mask = IsDebuggee | DebuggerObservesWasm;
|
||||
bool debuggerObservesAsmJS() const {
|
||||
static const unsigned Mask = IsDebuggee | DebuggerObservesAsmJS;
|
||||
return (debugModeBits & Mask) == Mask;
|
||||
}
|
||||
void updateDebuggerObservesWasm() {
|
||||
updateDebuggerObservesFlag(DebuggerObservesWasm);
|
||||
void updateDebuggerObservesAsmJS() {
|
||||
updateDebuggerObservesFlag(DebuggerObservesAsmJS);
|
||||
}
|
||||
|
||||
// True if this compartment's global is a debuggee of some Debugger object
|
||||
|
|
|
@ -2782,10 +2782,10 @@ Debugger::updateObservesAsmJSOnDebuggees(IsObserving observing)
|
|||
GlobalObject* global = r.front();
|
||||
JSCompartment* comp = global->compartment();
|
||||
|
||||
if (comp->debuggerObservesWasm() == observing)
|
||||
if (comp->debuggerObservesAsmJS() == observing)
|
||||
continue;
|
||||
|
||||
comp->updateDebuggerObservesWasm();
|
||||
comp->updateDebuggerObservesAsmJS();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3478,7 +3478,7 @@ Debugger::setAllowUnobservedAsmJS(JSContext* cx, unsigned argc, Value* vp)
|
|||
for (WeakGlobalObjectSet::Range r = dbg->debuggees.all(); !r.empty(); r.popFront()) {
|
||||
GlobalObject* global = r.front();
|
||||
JSCompartment* comp = global->compartment();
|
||||
comp->updateDebuggerObservesWasm();
|
||||
comp->updateDebuggerObservesAsmJS();
|
||||
}
|
||||
|
||||
args.rval().setUndefined();
|
||||
|
@ -3930,7 +3930,7 @@ Debugger::addDebuggeeGlobal(JSContext* cx, Handle<GlobalObject*> global)
|
|||
// (6)
|
||||
AutoRestoreCompartmentDebugMode debugModeGuard(debuggeeCompartment);
|
||||
debuggeeCompartment->setIsDebuggee();
|
||||
debuggeeCompartment->updateDebuggerObservesWasm();
|
||||
debuggeeCompartment->updateDebuggerObservesAsmJS();
|
||||
debuggeeCompartment->updateDebuggerObservesCoverage();
|
||||
if (observesAllExecution() && !ensureExecutionObservabilityOfCompartment(cx, debuggeeCompartment))
|
||||
return false;
|
||||
|
@ -4046,7 +4046,7 @@ Debugger::removeDebuggeeGlobal(FreeOp* fop, GlobalObject* global,
|
|||
global->compartment()->unsetIsDebuggee();
|
||||
} else {
|
||||
global->compartment()->updateDebuggerObservesAllExecution();
|
||||
global->compartment()->updateDebuggerObservesWasm();
|
||||
global->compartment()->updateDebuggerObservesAsmJS();
|
||||
global->compartment()->updateDebuggerObservesCoverage();
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче