[PATCH] D50031: Add pass to print out DebugCounter info

Zhizhou Yang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 30 17:48:32 PDT 2018


zhizhouy created this revision.
zhizhouy added reviewers: george.burgess.iv, davide.
Herald added subscribers: mgrang, mgorny.

This patch added a pass to print out {Counter, Skip, StopAfter} info of all passes which have DebugCounter set.

It can be used to monitor how many times does certain transformation happen in a pass, and also help check if -debug-counter option is set correctly.

Please refer to this thread <http://lists.llvm.org/pipermail/llvm-dev/2018-July/124722.html> for motivation.


Repository:
  rL LLVM

https://reviews.llvm.org/D50031

Files:
  include/llvm/IR/DebugCounterPrinter.h
  include/llvm/InitializePasses.h
  lib/IR/CMakeLists.txt
  lib/IR/Core.cpp
  lib/IR/DebugCounterPrinter.cpp
  lib/Passes/PassBuilder.cpp
  lib/Passes/PassRegistry.def
  lib/Support/DebugCounter.cpp
  test/Other/debug-counter-printer.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D50031.158142.patch
Type: text/x-patch
Size: 7816 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180731/47b36463/attachment.bin>


More information about the llvm-commits mailing list