mirror of
https://github.com/intel/llvm.git
synced 2026-01-16 05:32:28 +08:00
[BOLT] Options to facilitate debugging
Summary:
Some helpful options:
-print-dyno-stats-only
while printing functions output dyno-stats and skip instructions
-report-stale
print a list of functions with a stale profile
(cherry picked from FBD6505141)
This commit is contained in:
@@ -124,6 +124,13 @@ PrintDynoStats("dyno-stats",
|
||||
cl::desc("print execution info based on profile"),
|
||||
cl::cat(BoltCategory));
|
||||
|
||||
static cl::opt<bool>
|
||||
PrintDynoStatsOnly("print-dyno-stats-only",
|
||||
cl::desc("while printing functions output dyno-stats and skip instructions"),
|
||||
cl::init(false),
|
||||
cl::Hidden,
|
||||
cl::cat(BoltCategory));
|
||||
|
||||
static cl::opt<bool>
|
||||
PrintJumpTables("print-jump-tables",
|
||||
cl::desc("print jump tables"),
|
||||
@@ -441,7 +448,7 @@ void BinaryFunction::print(raw_ostream &OS, std::string Annotation,
|
||||
|
||||
OS << "\n}\n";
|
||||
|
||||
if (!PrintInstructions || !BC.InstPrinter)
|
||||
if (opts::PrintDynoStatsOnly || !PrintInstructions || !BC.InstPrinter)
|
||||
return;
|
||||
|
||||
// Offset of the instruction in function.
|
||||
|
||||
Reference in New Issue
Block a user