Skip to content

Commit

Permalink
Merge pull request #19297 from gita-omr/method_stats
Browse files Browse the repository at this point in the history
Print footprint statistics using verbose #METHOD STATS
  • Loading branch information
dsouzai authored Apr 16, 2024
2 parents c474be8 + 193f211 commit f1565c1
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 @@ -11081,6 +11081,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 f1565c1

Please sign in to comment.