Prefer recording loops over calls.
Hotcounts are decremented by 2 for loops and by 1 for calls.
This commit is contained in:
@@ -50,7 +50,8 @@ void lj_dispatch_init(GG_State *GG)
|
||||
/* Initialize hotcount table. */
|
||||
void lj_dispatch_init_hotcount(global_State *g)
|
||||
{
|
||||
HotCount start = (HotCount)G2J(g)->param[JIT_P_hotloop];
|
||||
int32_t hotloop = G2J(g)->param[JIT_P_hotloop];
|
||||
HotCount start = (HotCount)(hotloop*HOTCOUNT_LOOP - 1);
|
||||
HotCount *hotcount = G2GG(g)->hotcount;
|
||||
uint32_t i;
|
||||
for (i = 0; i < HOTCOUNT_SIZE; i++)
|
||||
|
||||
Reference in New Issue
Block a user