aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorTorok Edwin <edwintorok@gmail.com>2008-12-16 09:07:36 +0000
committerTorok Edwin <edwintorok@gmail.com>2008-12-16 09:07:36 +0000
commit620f28095bd0411065abb934917b68983b223b3d (patch)
tree2835ad97be5de47062746932badd80a76795162a /include
parenta70c68efc8b43d04b33a1d34670d640fbc9e6e74 (diff)
downloadexternal_llvm-620f28095bd0411065abb934917b68983b223b3d.zip
external_llvm-620f28095bd0411065abb934917b68983b223b3d.tar.gz
external_llvm-620f28095bd0411065abb934917b68983b223b3d.tar.bz2
Add utility functions to search for DbgStopPointInst corresponding to an
instruction or BasicBlock, and to search for DbgDeclareInst corresponding to a variable. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61084 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/llvm/Analysis/DebugInfo.h15
1 files changed, 14 insertions, 1 deletions
diff --git a/include/llvm/Analysis/DebugInfo.h b/include/llvm/Analysis/DebugInfo.h
index c0a43b3..270b36b 100644
--- a/include/llvm/Analysis/DebugInfo.h
+++ b/include/llvm/Analysis/DebugInfo.h
@@ -26,6 +26,9 @@ namespace llvm {
class Module;
class Type;
class Value;
+ class DbgStopPointInst;
+ class DbgDeclareInst;
+ class Instruction;
class DIDescriptor {
public:
@@ -388,7 +391,17 @@ namespace llvm {
Constant *getCastToEmpty(DIDescriptor D);
};
-
+ /// Finds the stoppoint coressponding to this instruction, that is the
+ /// stoppoint that dominates this instruction
+ const DbgStopPointInst *findStopPoint(const Instruction *Inst);
+
+ /// Finds the stoppoint corresponding to first real (non-debug intrinsic)
+ /// instruction in this Basic Block, and returns the stoppoint for it.
+ const DbgStopPointInst *findBBStopPoint(const BasicBlock *BB);
+
+ /// Finds the dbg.declare intrinsic corresponding to this value if any.
+ /// It looks through pointer casts too.
+ const DbgDeclareInst *findDbgDeclare(const Value *V, bool stripCasts = true);
} // end namespace llvm
#endif