mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 04:45:45 +00:00
Ensure that we are using the same IonCompartment throughout the lifetime of an AFC(bug 792873, r=jandem)
This commit is contained in:
parent
c9aa5ed197
commit
6f4c5d25ef
@ -1701,9 +1701,9 @@ ion::InvalidateAll(FreeOp *fop, JSCompartment *c)
|
||||
CancelOffThreadIonCompile(c, NULL);
|
||||
|
||||
FinishAllOffThreadCompilations(c->ionCompartment());
|
||||
|
||||
for (IonActivationIterator iter(fop->runtime()); iter.more(); ++iter) {
|
||||
if (iter.activation()->compartment() == c) {
|
||||
IonContext ictx(NULL, c, NULL);
|
||||
AutoFlushCache afc ("InvalidateAll", c->ionCompartment());
|
||||
IonSpew(IonSpew_Invalidate, "Invalidating all frames for GC");
|
||||
InvalidateActivation(fop, iter.top(), true);
|
||||
@ -1875,10 +1875,8 @@ AutoFlushCache::AutoFlushCache(const char *nonce, IonCompartment *comp)
|
||||
name_(nonce),
|
||||
used_(false)
|
||||
{
|
||||
if (comp == NULL) {
|
||||
if (CurrentIonContext() != NULL)
|
||||
comp = GetIonContext()->compartment->ionCompartment();
|
||||
}
|
||||
if (CurrentIonContext() != NULL)
|
||||
comp = GetIonContext()->compartment->ionCompartment();
|
||||
// If a compartment isn't available, then be a nop, nobody will ever see this flusher
|
||||
if (comp) {
|
||||
if (comp->flusher())
|
||||
|
@ -230,6 +230,8 @@ ion::CheckLogging()
|
||||
EnableChannel(IonSpew_Safepoints);
|
||||
if (ContainsFlag(env, "pools"))
|
||||
EnableChannel(IonSpew_Pools);
|
||||
if (ContainsFlag(env, "cacheflush"))
|
||||
EnableChannel(IonSpew_CacheFlush);
|
||||
if (ContainsFlag(env, "logs"))
|
||||
EnableIonDebugLogging();
|
||||
if (ContainsFlag(env, "all"))
|
||||
|
@ -72,7 +72,6 @@ struct EnterJITStack
|
||||
IonCode *
|
||||
IonCompartment::generateEnterJIT(JSContext *cx)
|
||||
{
|
||||
AutoFlushCache afc("GenerateEnterJIT", cx->compartment->ionCompartment());
|
||||
|
||||
const Register reg_code = r0;
|
||||
const Register reg_argc = r1;
|
||||
@ -85,6 +84,7 @@ IonCompartment::generateEnterJIT(JSContext *cx)
|
||||
JS_ASSERT(OsrFrameReg == reg_frame);
|
||||
|
||||
MacroAssembler masm(cx);
|
||||
AutoFlushCache afc("GenerateEnterJIT", cx->compartment->ionCompartment());
|
||||
Assembler *aasm = &masm;
|
||||
|
||||
// Save non-volatile registers. These must be saved by the trampoline,
|
||||
|
Loading…
Reference in New Issue
Block a user