[PATCH] D104161: [NFC] [DwarfEHPrepare] Add additional stats for EH
Wenlei He via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 11 20:37:48 PDT 2021
wenlei added inline comments.
================
Comment at: llvm/lib/CodeGen/DwarfEHPrepare.cpp:45
STATISTIC(NumResumesLowered, "Number of resume calls lowered");
+STATISTIC(NumFunctionsProcessed, "Number of functions processed");
+STATISTIC(NumCleanupLandingPads, "Number of cleanup landing pads in program");
----------------
The path leading to `InsertUnwindResumeCalls` is unconditional for all functions. So this is essentially a total function count. All stats have flat structure, so, 1) we don't add a total function count stats for each pass; 2) The description of each stats need to be informative about what a particular pass did, "Number of functions processed" is too general. If you want to compare against `NumNoUnwind`, perhaps you could add `NunUnwind`.
================
Comment at: llvm/lib/CodeGen/DwarfEHPrepare.cpp:46
+STATISTIC(NumFunctionsProcessed, "Number of functions processed");
+STATISTIC(NumCleanupLandingPads, "Number of cleanup landing pads in program");
+STATISTIC(NumCleanupLandingPadsUnreachable,
----------------
- " in program" is implicit for all stats.
- This seems to be the count before pruning unreachable LP, but it's unclear from the name. Suggest name the two counter as something like "Number of cleanup landing pads removed", "Number of cleanup landing pads remained".
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D104161/new/
https://reviews.llvm.org/D104161
More information about the llvm-commits
mailing list