Bug 469927 - TM: much slower than interpreter with short loop with |let| (r=mrbkap).

This commit is contained in:
Brendan Eich 2008-12-17 12:34:06 -08:00
parent c67f58e20d
commit bbd3fdab2a

View File

@ -8266,13 +8266,21 @@ TraceRecorder::record_JSOP_TYPEOFEXPR()
JS_REQUIRES_STACK bool
TraceRecorder::record_JSOP_ENTERBLOCK()
{
return false;
JSScript* script = cx->fp->script;
JSFrameRegs& regs = *cx->fp->regs;
JSObject* obj;
JS_GET_SCRIPT_OBJECT(script, GET_FULL_INDEX(0), obj);
LIns* void_ins = INS_CONST(JSVAL_TO_BOOLEAN(JSVAL_VOID));
for (int i = 0, n = OBJ_BLOCK_COUNT(cx, obj); i < n; i++)
stack(i, void_ins);
return true;
}
JS_REQUIRES_STACK bool
TraceRecorder::record_JSOP_LEAVEBLOCK()
{
return false;
return true;
}
JS_REQUIRES_STACK bool
@ -8325,7 +8333,10 @@ TraceRecorder::record_JSOP_ENUMCONSTELEM()
JS_REQUIRES_STACK bool
TraceRecorder::record_JSOP_LEAVEBLOCKEXPR()
{
return false;
LIns* v_ins = stack(-1);
int n = -1 - GET_UINT16(cx->fp->regs->pc);
stack(n, v_ins);
return true;
}
JS_REQUIRES_STACK bool