зеркало из https://github.com/mozilla/gecko-dev.git
Bug 881536 - Part 2: Refactor initializeAddCacheState into DispatchIonCache. (r=nbp)
This commit is contained in:
Родитель
79233fc7a6
Коммит
38614b2ab9
|
@ -462,6 +462,7 @@ class DispatchIonCache : public IonCache
|
|||
}
|
||||
|
||||
virtual void reset();
|
||||
virtual void initializeAddCacheState(LInstruction *ins, AddCacheState *addState);
|
||||
|
||||
void emitInitialJump(MacroAssembler &masm, AddCacheState &addState);
|
||||
void bindInitialJump(MacroAssembler &masm, AddCacheState &addState);
|
||||
|
@ -907,7 +908,11 @@ class ParallelGetPropertyIC : public ParallelIonCache
|
|||
|
||||
CACHE_HEADER(ParallelGetProperty)
|
||||
|
||||
#ifdef JS_CPU_X86
|
||||
// x86 lacks a general purpose scratch register for dispatch caches and
|
||||
// must be given one manually.
|
||||
void initializeAddCacheState(LInstruction *ins, AddCacheState *addState);
|
||||
#endif
|
||||
|
||||
Register object() const {
|
||||
return object_;
|
||||
|
|
|
@ -1674,10 +1674,9 @@ CodeGeneratorARM::generateInvalidateEpilogue()
|
|||
}
|
||||
|
||||
void
|
||||
ParallelGetPropertyIC::initializeAddCacheState(LInstruction *ins, AddCacheState *addState)
|
||||
DispatchIonCache::initializeAddCacheState(LInstruction *ins, AddCacheState *addState)
|
||||
{
|
||||
// Can always use the scratch register on ARM.
|
||||
JS_ASSERT(ins->isGetPropertyCacheV() || ins->isGetPropertyCacheT());
|
||||
addState->dispatchScratch = ScratchRegister;
|
||||
}
|
||||
|
||||
|
|
|
@ -527,10 +527,9 @@ CodeGeneratorX64::visitAsmJSLoadFFIFunc(LAsmJSLoadFFIFunc *ins)
|
|||
}
|
||||
|
||||
void
|
||||
ParallelGetPropertyIC::initializeAddCacheState(LInstruction *ins, AddCacheState *addState)
|
||||
DispatchIonCache::initializeAddCacheState(LInstruction *ins, AddCacheState *addState)
|
||||
{
|
||||
// Can always use the scratch register on x64.
|
||||
JS_ASSERT(ins->isGetPropertyCacheV() || ins->isGetPropertyCacheT());
|
||||
addState->dispatchScratch = ScratchReg;
|
||||
}
|
||||
|
||||
|
|
|
@ -654,6 +654,14 @@ CodeGeneratorX86::postAsmJSCall(LAsmJSCall *lir)
|
|||
masm.freeStack(sizeof(double));
|
||||
}
|
||||
|
||||
void
|
||||
DispatchIonCache::initializeAddCacheState(LInstruction *ins, AddCacheState *addState)
|
||||
{
|
||||
// On x86, where there is no general purpose scratch register available,
|
||||
// child cache classes must manually specify a dispatch scratch register.
|
||||
MOZ_ASSUME_UNREACHABLE("x86 needs manual assignment of dispatchScratch");
|
||||
}
|
||||
|
||||
void
|
||||
ParallelGetPropertyIC::initializeAddCacheState(LInstruction *ins, AddCacheState *addState)
|
||||
{
|
||||
|
|
Загрузка…
Ссылка в новой задаче