зеркало из https://github.com/mozilla/gecko-dev.git
Bug 871777 - Fold a load and a jump. r=jandem
This commit is contained in:
Родитель
5de49744cb
Коммит
67808e8d3d
|
@ -562,6 +562,9 @@ class AssemblerX86Shared
|
|||
|
||||
void jmp(const Operand &op){
|
||||
switch (op.kind()) {
|
||||
case Operand::REG_DISP:
|
||||
masm.jmp_m(op.disp(), op.base());
|
||||
break;
|
||||
case Operand::SCALE:
|
||||
masm.jmp_m(op.disp(), op.base(), op.index(), op.scale());
|
||||
break;
|
||||
|
|
|
@ -47,12 +47,8 @@ EmitEnterTypeMonitorIC(MacroAssembler &masm,
|
|||
// is properly initialized to point to the stub.
|
||||
masm.movq(Operand(BaselineStubReg, (int32_t) monitorStubOffset), BaselineStubReg);
|
||||
|
||||
// Load stubcode pointer from BaselineStubEntry into BaselineTailCallReg.
|
||||
masm.movq(Operand(BaselineStubReg, (int32_t) ICStub::offsetOfStubCode()),
|
||||
BaselineTailCallReg);
|
||||
|
||||
// Jump to the stubcode.
|
||||
masm.jmp(Operand(BaselineTailCallReg));
|
||||
masm.jmp(Operand(BaselineStubReg, (int32_t) ICStub::offsetOfStubCode()));
|
||||
}
|
||||
|
||||
inline void
|
||||
|
@ -270,12 +266,8 @@ EmitStubGuardFailure(MacroAssembler &masm)
|
|||
// Load next stub into BaselineStubReg
|
||||
masm.movq(Operand(BaselineStubReg, ICStub::offsetOfNext()), BaselineStubReg);
|
||||
|
||||
// Load stubcode pointer from BaselineStubEntry into BaselineTailCallReg
|
||||
// BaselineTailCallReg will always be unused in the contexts where IC stub guards fail
|
||||
masm.movq(Operand(BaselineStubReg, ICStub::offsetOfStubCode()), BaselineTailCallReg);
|
||||
|
||||
// Return address is already loaded, just jump to the next stubcode.
|
||||
masm.jmp(Operand(BaselineTailCallReg));
|
||||
masm.jmp(Operand(BaselineStubReg, ICStub::offsetOfStubCode()));
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -48,12 +48,8 @@ EmitEnterTypeMonitorIC(MacroAssembler &masm,
|
|||
// is properly initialized to point to the stub.
|
||||
masm.movl(Operand(BaselineStubReg, (int32_t) monitorStubOffset), BaselineStubReg);
|
||||
|
||||
// Load stubcode pointer from BaselineStubReg into BaselineTailCallReg.
|
||||
masm.movl(Operand(BaselineStubReg, (int32_t) ICStub::offsetOfStubCode()),
|
||||
BaselineTailCallReg);
|
||||
|
||||
// Jump to the stubcode.
|
||||
masm.jmp(Operand(BaselineTailCallReg));
|
||||
masm.jmp(Operand(BaselineStubReg, (int32_t) ICStub::offsetOfStubCode()));
|
||||
}
|
||||
|
||||
inline void
|
||||
|
@ -276,13 +272,8 @@ EmitStubGuardFailure(MacroAssembler &masm)
|
|||
// Load next stub into BaselineStubReg
|
||||
masm.movl(Operand(BaselineStubReg, (int32_t) ICStub::offsetOfNext()), BaselineStubReg);
|
||||
|
||||
// Load stubcode pointer from BaselineStubEntry into BaselineTailCallReg
|
||||
// BaselineTailCallReg will always be unused in the contexts where IC stub guards fail
|
||||
masm.movl(Operand(BaselineStubReg, (int32_t) ICStub::offsetOfStubCode()),
|
||||
BaselineTailCallReg);
|
||||
|
||||
// Return address is already loaded, just jump to the next stubcode.
|
||||
masm.jmp(Operand(BaselineTailCallReg));
|
||||
masm.jmp(Operand(BaselineStubReg, (int32_t) ICStub::offsetOfStubCode()));
|
||||
}
|
||||
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче