Bug 910796 - SpiderMonkey: Micro-optimize ICCompare_Int32::Compiler::generateStubCode on x64. r=evilpies

This commit is contained in:
Dan Gohman 2013-08-31 07:29:41 -07:00
parent a9ea5e8f44
commit 6eb1edd83c

View File

@ -28,9 +28,9 @@ ICCompare_Int32::Compiler::generateStubCode(MacroAssembler &masm)
// Directly compare the int32 payload of R0 and R1.
Assembler::Condition cond = JSOpToCondition(op, /* signed = */true);
masm.xorl(ScratchReg, ScratchReg);
masm.cmpl(R0.valueReg(), R1.valueReg());
masm.setCC(cond, ScratchReg);
masm.movzxbl(ScratchReg, ScratchReg);
// Box the result and return
masm.boxValue(JSVAL_TYPE_BOOLEAN, ScratchReg, R0.valueReg());