[PATCH] D125495: [Inline][Remark] Annotate inline pass name with link phase information for analysis.

David Li via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 12 14:34:22 PDT 2022


davidxl added a comment.

It might be worth annotating the early inliner for PGO as well.



================
Comment at: llvm/lib/Analysis/InlineAdvisor.cpp:60
+static cl::opt<bool>
+    AnnotateInlineLTOPhase("annotate-inline-lto-phase", cl::Hidden,
+                           cl::init(false),
----------------
document possible inline pass names here.


================
Comment at: llvm/lib/Analysis/InlineAdvisor.cpp:109
+  case llvm::ThinOrFullLTOPhase::ThinLTOPreLink:
+    return "thin-lto-prelink-default-inline";
+  case llvm::ThinOrFullLTOPhase::FullLTOPreLink:
----------------
why adding 'default' in the name?


================
Comment at: llvm/lib/Transforms/IPO/SampleProfile.cpp:600
+
+  switch (phase) {
+  case llvm::ThinOrFullLTOPhase::ThinLTOPreLink:
----------------
I think it is better to also add 'sample-loader' into the pass string as well.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D125495/new/

https://reviews.llvm.org/D125495



More information about the llvm-commits mailing list