[Debugify] Export per-pass debug info loss statistics
authorVedant Kumar <vsk@apple.com>
Tue, 24 Jul 2018 00:41:29 +0000 (00:41 +0000)
committerVedant Kumar <vsk@apple.com>
Tue, 24 Jul 2018 00:41:29 +0000 (00:41 +0000)
commitd6ff43cc71acde958d3927952a049f72e88fd79f
treeb7b43eb3873f317e98dca3c12ad4a0c6c5e60a60
parentca407c43364e4315f8ae32bd0c0e70c5aafb7962
[Debugify] Export per-pass debug info loss statistics

Add a -debugify-export option to opt. This exports per-pass `debugify`
loss statistics to a file in CSV format.

For some interesting numbers on debug value loss during an -O2 build
of the sqlite3 amalgamation, see the review thread.

Differential Revision: https://reviews.llvm.org/D49003

llvm-svn: 337787
llvm/test/DebugInfo/debugify-export.ll [new file with mode: 0644]
llvm/tools/opt/Debugify.cpp
llvm/tools/opt/Debugify.h
llvm/tools/opt/opt.cpp