diff options
author | Manman Ren <manman.ren@gmail.com> | 2013-09-09 19:47:11 +0000 |
---|---|---|
committer | Manman Ren <manman.ren@gmail.com> | 2013-09-09 19:47:11 +0000 |
commit | 2c9905a1f3bcf22cc2f93332cc8411d11798ba07 (patch) | |
tree | cd46f1895d551822957384c349a4889109610933 /include/llvm/DebugInfo.h | |
parent | 0b67c2127eb3b26b53ccdb925c87aad6ae19819d (diff) | |
download | external_llvm-2c9905a1f3bcf22cc2f93332cc8411d11798ba07.zip external_llvm-2c9905a1f3bcf22cc2f93332cc8411d11798ba07.tar.gz external_llvm-2c9905a1f3bcf22cc2f93332cc8411d11798ba07.tar.bz2 |
Debug Info: Use DIScopeRef for DIType::getContext.
In DIBuilder, the context field of a TAG_member is updated to use the
scope reference. Verifier is updated accordingly.
DebugInfoFinder now needs to generate a type identifier map to have
access to the actual scope. Same applies for BreakpointPrinter.
processModule of DebugInfoFinder is called during initialization phase
of the verifier to make sure the type identifier map is constructed early
enough.
We are now able to unique a simple class as demonstrated by the added
testing case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190334 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/DebugInfo.h')
-rw-r--r-- | include/llvm/DebugInfo.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/llvm/DebugInfo.h b/include/llvm/DebugInfo.h index a758fcc..4ea843c 100644 --- a/include/llvm/DebugInfo.h +++ b/include/llvm/DebugInfo.h @@ -237,7 +237,7 @@ namespace llvm { /// Verify - Verify that a type descriptor is well formed. bool Verify() const; - DIScope getContext() const { return getFieldAs<DIScope>(2); } + DIScopeRef getContext() const { return getFieldAs<DIScopeRef>(2); } StringRef getName() const { return getStringField(3); } unsigned getLineNumber() const { return getUnsignedField(4); } uint64_t getSizeInBits() const { return getUInt64Field(5); } @@ -820,6 +820,7 @@ namespace llvm { SmallVector<MDNode *, 8> TYs; // Types SmallVector<MDNode *, 8> Scopes; // Scopes SmallPtrSet<MDNode *, 64> NodesSeen; + DITypeIdentifierMap TypeIdentifierMap; }; } // end namespace llvm |