diff options
Diffstat (limited to 'include/llvm/IR/DebugInfo.h')
-rw-r--r-- | include/llvm/IR/DebugInfo.h | 23 |
1 files changed, 3 insertions, 20 deletions
diff --git a/include/llvm/IR/DebugInfo.h b/include/llvm/IR/DebugInfo.h index 4caceacbb58e0..972042432b7b4 100644 --- a/include/llvm/IR/DebugInfo.h +++ b/include/llvm/IR/DebugInfo.h @@ -17,10 +17,8 @@ #ifndef LLVM_IR_DEBUGINFO_H #define LLVM_IR_DEBUGINFO_H -#include "llvm/ADT/DenseMap.h" #include "llvm/ADT/SmallPtrSet.h" #include "llvm/ADT/SmallVector.h" -#include "llvm/ADT/StringRef.h" #include "llvm/ADT/iterator_range.h" #include "llvm/IR/DebugInfoMetadata.h" #include "llvm/Support/Casting.h" @@ -32,21 +30,12 @@ namespace llvm { class Module; class DbgDeclareInst; class DbgValueInst; - -/// \brief Maps from type identifier to the actual MDNode. -typedef DenseMap<const MDString *, DIType *> DITypeIdentifierMap; +template <typename K, typename V, typename KeyInfoT, typename BucketT> +class DenseMap; /// \brief Find subprogram that is enclosing this scope. DISubprogram *getDISubprogram(const MDNode *Scope); -/// \brief Find debug info for a given function. -/// -/// \returns a valid subprogram, if found. Otherwise, return \c nullptr. -DISubprogram *getDISubprogram(const Function *F); - -/// \brief Generate map by visiting all retained types. -DITypeIdentifierMap generateDITypeIdentifierMap(const NamedMDNode *CU_Nodes); - /// \brief Strip debug info in the module if it exists. /// /// To do this, we remove all calls to the debugger intrinsics and any named @@ -68,8 +57,6 @@ unsigned getDebugMetadataVersionFromModule(const Module &M); /// used by the CUs. class DebugInfoFinder { public: - DebugInfoFinder() : TypeMapInitialized(false) {} - /// \brief Process entire module and collect debug info anchors. void processModule(const Module &M); @@ -136,11 +123,7 @@ private: SmallVector<DIGlobalVariable *, 8> GVs; SmallVector<DIType *, 8> TYs; SmallVector<DIScope *, 8> Scopes; - SmallPtrSet<const MDNode *, 64> NodesSeen; - DITypeIdentifierMap TypeIdentifierMap; - - /// \brief Specify if TypeIdentifierMap is initialized. - bool TypeMapInitialized; + SmallPtrSet<const MDNode *, 32> NodesSeen; }; } // end namespace llvm |