aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lj_trace.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lj_trace.c b/src/lj_trace.c
index b2b35373..d1883ad2 100644
--- a/src/lj_trace.c
+++ b/src/lj_trace.c
@@ -551,8 +551,9 @@ static void trace_new(jit_State *J)
551void LJ_FASTCALL lj_trace_hot(jit_State *J, const BCIns *pc) 551void LJ_FASTCALL lj_trace_hot(jit_State *J, const BCIns *pc)
552{ 552{
553 hotcount_set(J2GG(J), pc, J->param[JIT_P_hotloop]+1); /* Reset hotcount. */ 553 hotcount_set(J2GG(J), pc, J->param[JIT_P_hotloop]+1); /* Reset hotcount. */
554 /* Only start a new trace if not inside __gc call or vmevent. */ 554 /* Only start a new trace if not recording or inside __gc call or vmevent. */
555 if (!(J2G(J)->hookmask & (HOOK_GC|HOOK_VMEVENT))) { 555 if (J->state == LJ_TRACE_IDLE &&
556 !(J2G(J)->hookmask & (HOOK_GC|HOOK_VMEVENT))) {
556 lua_State *L = J->L; 557 lua_State *L = J->L;
557 L->top = curr_topL(L); /* Only called from Lua and NRESULTS is not used. */ 558 L->top = curr_topL(L); /* Only called from Lua and NRESULTS is not used. */
558 J->parent = 0; /* Root trace. */ 559 J->parent = 0; /* Root trace. */