summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorManman Ren <manman.ren@gmail.com>2013-07-23 00:22:51 +0000
committerManman Ren <manman.ren@gmail.com>2013-07-23 00:22:51 +0000
commit0e29eeec278d80048de6cf6605e004bbdefaf38c (patch)
treee75b7471e00d617b8ab62811a5341594e65df088 /include
parentaf1d08782b0f9c60c2504e39dda160a784d1ed1e (diff)
downloadllvm-0e29eeec278d80048de6cf6605e004bbdefaf38c.tar.gz
llvm-0e29eeec278d80048de6cf6605e004bbdefaf38c.tar.bz2
llvm-0e29eeec278d80048de6cf6605e004bbdefaf38c.tar.xz
Debug Info Finder: use processDeclare and processValue to list debug info
MDNodes used by DbgDeclareInst and DbgValueInst. Another 16 testing cases failed and they are disabled with -disable-debug-info-verifier. A total of 34 cases are disabled with -disable-debug-info-verifier and will be corrected. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186902 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/llvm/DebugInfo.h15
1 files changed, 12 insertions, 3 deletions
diff --git a/include/llvm/DebugInfo.h b/include/llvm/DebugInfo.h
index d05b328744..53b1bdd560 100644
--- a/include/llvm/DebugInfo.h
+++ b/include/llvm/DebugInfo.h
@@ -31,6 +31,7 @@ namespace llvm {
class Type;
class Value;
class DbgDeclareInst;
+ class DbgValueInst;
class Instruction;
class MDNode;
class NamedMDNode;
@@ -734,12 +735,23 @@ namespace llvm {
/// cleanseInlinedVariable - Remove inlined scope from the variable.
DIVariable cleanseInlinedVariable(MDNode *DV, LLVMContext &VMContext);
+ /// DebugInfoFinder tries to list all debug info MDNodes in a module. To
+ /// list debug info MDNodes used by an instruction, DebugInfoFinder uses
+ /// processDeclare and processValue. processModule will go through
+ /// all DICompileUnits and list debug info MDNodes used by the CUs.
class DebugInfoFinder {
public:
/// processModule - Process entire module and collect debug info
/// anchors.
void processModule(const Module &M);
+ /// processDeclare - Process DbgDeclareInst.
+ void processDeclare(const DbgDeclareInst *DDI);
+ /// Process DbgValueInst.
+ void processValue(const DbgValueInst *DVI);
+
+ /// Clear all lists.
+ void reset();
private:
/// processType - Process DIType.
void processType(DIType DT);
@@ -750,9 +762,6 @@ namespace llvm {
/// processSubprogram - Process DISubprogram.
void processSubprogram(DISubprogram SP);
- /// processDeclare - Process DbgDeclareInst.
- void processDeclare(const DbgDeclareInst *DDI);
-
/// processLocation - Process DILocation.
void processLocation(DILocation Loc);