diff options
author | Adrian Prantl <aprantl@apple.com> | 2016-04-08 22:43:03 +0000 |
---|---|---|
committer | Adrian Prantl <aprantl@apple.com> | 2016-04-08 22:43:03 +0000 |
commit | 5992a72b4d21f3ea15a0ecbb593d92c9bc4fe1a0 (patch) | |
tree | e369ac2ee392142837ebf0b460286e0fe2bdda0a /llvm/tools | |
parent | b24f4fb6171eaf2caa8f3cf6adcf11821ec1d27c (diff) | |
download | bcm5719-llvm-5992a72b4d21f3ea15a0ecbb593d92c9bc4fe1a0.tar.gz bcm5719-llvm-5992a72b4d21f3ea15a0ecbb593d92c9bc4fe1a0.zip |
Support the Nodebug emission kind for DICompileUnits.
Sample-based profiling and optimization remarks currently remove
DICompileUnits from llvm.dbg.cu to suppress the emission of debug info
from them. This is somewhat of a hack and only borderline legal IR.
This patch uses the recently introduced NoDebug emission kind in
DICompileUnit to achieve the same result without breaking the Verifier.
A nice side-effect of this change is that it is now possible to combine
NoDebug and regular compile units under LTO.
http://reviews.llvm.org/D18808
<rdar://problem/25427165>
llvm-svn: 265861
Diffstat (limited to 'llvm/tools')
-rw-r--r-- | llvm/tools/opt/BreakpointPrinter.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/llvm/tools/opt/BreakpointPrinter.cpp b/llvm/tools/opt/BreakpointPrinter.cpp index 363a7cd8007..f76ad79fbe7 100644 --- a/llvm/tools/opt/BreakpointPrinter.cpp +++ b/llvm/tools/opt/BreakpointPrinter.cpp @@ -45,9 +45,7 @@ struct BreakpointPrinter : public ModulePass { bool runOnModule(Module &M) override { TypeIdentifierMap.clear(); - NamedMDNode *CU_Nodes = M.getNamedMetadata("llvm.dbg.cu"); - if (CU_Nodes) - TypeIdentifierMap = generateDITypeIdentifierMap(CU_Nodes); + TypeIdentifierMap = generateDITypeIdentifierMap(M); StringSet<> Processed; if (NamedMDNode *NMD = M.getNamedMetadata("llvm.dbg.sp")) |