summaryrefslogtreecommitdiff
path: root/tools/opt/opt.cpp
diff options
context:
space:
mode:
authorDaniel Malea <daniel.malea@intel.com>2013-05-08 20:44:14 +0000
committerDaniel Malea <daniel.malea@intel.com>2013-05-08 20:44:14 +0000
commit13ace6664fad8b4d0277d16690674f4e1f176642 (patch)
tree07e183914fcea6659f8e2d4fa527d109a2e703cb /tools/opt/opt.cpp
parentd0fef32e5f3700c7de6dfc50a1a3815659b7d19e (diff)
downloadllvm-13ace6664fad8b4d0277d16690674f4e1f176642.tar.gz
llvm-13ace6664fad8b4d0277d16690674f4e1f176642.tar.bz2
llvm-13ace6664fad8b4d0277d16690674f4e1f176642.tar.xz
Add DebugIR pass -- emits IR file and replace source lines with IR lines in MD
- requires existing debug information to be present - fixes up file name and line number information in metadata - emits a "<orig_filename>-debug.ll" succinct IR file (without !dbg metadata or debug intrinsics) that can be read by a debugger - initialize pass in opt tool to enable the "-debug-ir" flag - lit tests to follow git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@181467 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/opt/opt.cpp')
-rw-r--r--tools/opt/opt.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/opt/opt.cpp b/tools/opt/opt.cpp
index e385d7f577..57b03b4c48 100644
--- a/tools/opt/opt.cpp
+++ b/tools/opt/opt.cpp
@@ -567,6 +567,7 @@ int main(int argc, char **argv) {
// Initialize passes
PassRegistry &Registry = *PassRegistry::getPassRegistry();
initializeCore(Registry);
+ initializeDebugIRPass(Registry);
initializeScalarOpts(Registry);
initializeObjCARCOpts(Registry);
initializeVectorization(Registry);