/* ========================================================================== */ VOID ILDJIT_startSimulation(THREADID tid, ADDRINT ip) { CODECACHE_FlushCache(); lk_lock(&ildjit_lock, 1); /* We are stopping thread creation here, beacuse we can capture the real * thread creation in Pin only on starting the thread (first insn), which * happens after the actual syscalls. * XXX: This way we can capture the creation of some compiler threads, * but this is generally fine, since they won't get executed */ ILDJIT_executorCreation = false; ILDJIT_executionStarted = true; ILDJIT_executorTID = tid; cerr << "Starting execution, TID: " << tid << endl; lk_unlock(&ildjit_lock); if (reached_warm_invocation) { cerr << "Do Early!" << endl; doLateILDJITInstrumentation(); cerr << "Done Early!" << endl; } }
void fork_func(THREADID threadid, const CONTEXT * ctxt, VOID * v) { /* * The function: "CODECACHE_FlushCache()" requires from the calling thread to hold the VM lock. */ CODECACHE_FlushCache(); }
static VOID OnDoFlush() { FlushHappened = FALSE; CODECACHE_FlushCache(); }
static ADDRINT IfFunc () { CODECACHE_FlushCache(); return 1; }