[clang] [llvm] [PGO]Add `-fdiagnostics-show-profile-count` option to show real loop count from instr-profile (PR #75021)

Elvis Wang via cfe-commits cfe-commits at lists.llvm.org
Thu Dec 21 18:52:55 PST 2023


================
@@ -2091,6 +2091,12 @@ bool CompilerInvocation::ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args,
   bool UsingProfile =
       UsingSampleProfile || !Opts.ProfileInstrumentUsePath.empty();
 
+  if (Args.hasArg(options::OPT_fdiagnostics_show_profile_count) &&
----------------
ElvisWang123 wrote:

This option `options::OPT_fdiagnostics_show_profile_count` also appears in the `clang/lib/Driver/Toochains/clang.cpp` to enable the profile metadata appending to IR.

https://github.com/llvm/llvm-project/pull/75021


More information about the cfe-commits mailing list