Skip to content

Commit

Permalink
Print footprint statistics using verbose #METHOD STATS
Browse files Browse the repository at this point in the history
  • Loading branch information
gita-omr committed Apr 12, 2024
1 parent 87d6563 commit 193f211
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions runtime/compiler/control/CompilationThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11422,6 +11422,28 @@ void TR::CompilationInfoPerThreadBase::logCompilationSuccess(
TR_VerboseLog::write(" queueTime=%zuus", currentTime - _methodBeingCompiled->_entryTime);

TR_VerboseLog::writeLine("");

if (TR::Options::getVerboseOption(TR_VerboseJitMemory))
{
OMR::CodeGenerator::MethodStats methodStats;
compiler->cg()->getMethodStats(methodStats);

TR_VerboseLog::writeLineLocked(TR_Vlog_METHOD_STATS, "%s j9m=%p "
"codeSize=%iB warmBlocks=%iB coldBlocks=%iB "
"prologue=%iB snippets=%iB outOfLine=%iB "
"unaccounted=%iB blocksInColdCache=%iB "
"overestimateInColdCache=%iB",
compiler->signature(), method,
methodStats.codeSize,
methodStats.warmBlocks,
methodStats.coldBlocks,
methodStats.prologue,
methodStats.snippets,
methodStats.outOfLine,
methodStats.unaccounted,
methodStats.blocksInColdCache,
methodStats.overestimateInColdCache);
}
}

char compilationAttributes[40] = { 0 };
Expand Down

0 comments on commit 193f211

Please sign in to comment.