[PATCH] D110209: [CSSPGO] Set PseudoProbeInserter as a default pass.

Hongtao Yu via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 21 17:17:09 PDT 2021


hoy created this revision.
Herald added subscribers: ormris, modimo, wenlei, dang, pengfei, steven_wu, hiraditya, arichardson, emaste.
Herald added a reviewer: MaskRay.
hoy requested review of this revision.
Herald added projects: clang, LLVM.
Herald added subscribers: llvm-commits, cfe-commits.

Currenlty PseudoProbeInserter is a pass conditioned on a target switch. It works well with a single clang invocation. It doesn't work so well when the backend is called separately (i.e, through the linker or llc), where user has always to pass -pseudo-probe-for-profiling explictly. I'm making the pass a default pass that requires no command line arg to trigger, but will be actually run depending on whether the CU comes with `llvm.pseudo_probe_desc` metadata.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D110209

Files:
  clang/lib/CodeGen/BackendUtil.cpp
  lld/ELF/Config.h
  lld/ELF/Driver.cpp
  lld/ELF/LTO.cpp
  lld/ELF/Options.td
  llvm/include/llvm/CodeGen/CommandFlags.h
  llvm/include/llvm/Target/TargetOptions.h
  llvm/lib/CodeGen/CommandFlags.cpp
  llvm/lib/CodeGen/PseudoProbeInserter.cpp
  llvm/lib/CodeGen/TargetPassConfig.cpp
  llvm/test/CodeGen/X86/O0-pipeline.ll
  llvm/test/CodeGen/X86/opt-pipeline.ll
  llvm/test/Transforms/SampleProfile/pseudo-probe-dangle.ll
  llvm/test/Transforms/SampleProfile/pseudo-probe-emit-inline.ll
  llvm/test/Transforms/SampleProfile/pseudo-probe-emit.ll
  llvm/test/Transforms/SampleProfile/pseudo-probe-instsched.ll
  llvm/test/tools/llvm-profgen/truncated-pseudoprobe.test

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D110209.374075.patch
Type: text/x-patch
Size: 12976 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210922/3f3fdff6/attachment-0001.bin>


More information about the llvm-commits mailing list