Low-overhead profiler, part 4: JIT compiler support.

This commit is contained in:
Mike Pall
2013-09-08 02:53:23 +02:00
parent d3d30d389b
commit d1194a82eb
12 changed files with 151 additions and 12 deletions

View File

@@ -2285,6 +2285,17 @@ LJFOLDF(barrier_tnew_tdup)
return DROPFOLD;
}
/* -- Profiling ----------------------------------------------------------- */
LJFOLD(PROF any any)
LJFOLDF(prof)
{
IRRef ref = J->chain[IR_PROF];
if (ref+1 == J->cur.nins) /* Drop neighbouring IR_PROF. */
return ref;
return EMITFOLD;
}
/* -- Stores and allocations ---------------------------------------------- */
/* Stores and allocations cannot be folded or passed on to CSE in general.