017c16aa483e6edabdbbee1bdcd1ce3f8e8a12d1 |
|
27-Mar-2013 |
Greg Clayton <gclayton@apple.com> |
Don't use a "uintptr_t" for the metadata key, use a "void *". This removes all of the casts that were being used and cleans the code up a bit. Also added the ability to dump the metadata. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@178113 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Symbol/ClangExternalASTSourceCommon.cpp
|
a32c5a5aa1fec0f9bc2a5b123f07ff6b8c979999 |
|
27-Oct-2012 |
Jim Ingham <jingham@apple.com> |
This is the first phase of supporting the DW_AT_object_pointer tag. I expanded the decl metadata so it could hold this information, and then used it to look up unfound names in the object pointer if it exists. This gets "frame var" to work for unqualified references to ivars captured in blocks. But the expression parser is ignoring this information still. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@166860 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Symbol/ClangExternalASTSourceCommon.cpp
|
fafffe000eb4a3902ecefc82446d11e6838167c6 |
|
13-Apr-2012 |
Sean Callanan <scallanan@apple.com> |
Added a mechanism for keeping track of where in the debug information individual Decls came from. We've had a metadata infrastructure for a while, which was intended to solve a problem we've since dealt with in a different way. (It was meant to keep track of which definition of an Objective-C class was the "true" definition, but we now find it by searching the symbols for the class symbol.) The metadata is attached to the ExternalASTSource, which means it has a one-to-one correspondence with AST contexts. I've repurposed the metadata infrastructure to hold the object file and DIE offset for the DWARF information corresponding to a Decl. There are methods in ClangASTContext that get and set this metadata, and the ClangASTImporter is capable of tracking down the metadata for Decls that have been copied out of the debug information into the parser's AST context without using any additional memory. To see the metadata, you just have to enable the expression log: - (lldb) log enable lldb expr - and watch the import messages. The high 32 bits of the metadata indicate the index of the object file in its containing DWARFDebugMap; I have also added a log which you can use to track that mapping: - (lldb) log enable dwarf map - This adds 64 bits per Decl, which in my testing hasn't turned out to be very much (debugging Clang produces around 6500 Decls in my tests). To track how much data is being consumed, I've also added a global variable g_TotalSizeOfMetadata which tracks the total number of Decls that have metadata in all active AST contexts. Right now this metadata is enormously useful for tracking down bugs in the debug info parser. In the future I also want to use this information to provide more intelligent error messages instead of printing empty source lines wherever Clang refers to the location where something is defined. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@154634 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Symbol/ClangExternalASTSourceCommon.cpp
|
16d2187c0c3992f22e9cb011f863dc0fe35e3cde |
|
03-Dec-2011 |
Greg Clayton <gclayton@apple.com> |
Added the ability for clients to grab a set of symbol table indexes and then add them to a fast lookup map. lldb_private::Symtab now export the following public typedefs: namespace lldb_private { class Symtab { typedef std::vector<uint32_t> IndexCollection; typedef UniqueCStringMap<uint32_t> NameToIndexMap; }; } Clients can then find symbols by name and or type and end up with a Symtab::IndexCollection that is filled with indexes. These indexes can then be put into a name to index lookup map and control if the mangled and demangled names get added to the map: bool add_demangled = true; bool add_mangled = true; Symtab::NameToIndexMap name_to_index; symtab->AppendSymbolNamesToMap (indexes, add_demangled, add_mangled, name_to_index). This can be repeated as many times as needed to get a lookup table that you are happy with, and then this can be sorted: name_to_index.Sort(); Now name lookups can be done using a subset of the symbols you extracted from the symbol table. This is currently being used to extract objective C types from object files when there is no debug info in SymbolFileSymtab. Cleaned up how the objective C types were being vended to be more efficient and fixed some errors in the regular expression that was being used. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@145777 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Symbol/ClangExternalASTSourceCommon.cpp
|
2fc7e8d0d392fe85f22d9c75212ebca4cbce547f |
|
03-Dec-2011 |
Sean Callanan <scallanan@apple.com> |
Added ClangExternalASTSourceCommon, a local superclass for all our external AST sources that lets us associate arbitrary flags with the types we put into the AST contexts. Also added an API on ClangASTContext that allows access to these flags given only an ASTContext and a type. Because we don't have access to RTTI, and because at some point in the future we might encounter external AST sources that we didn't make (so they don't subclass ClangExternalASTSourceCommon) I added a magic number that we check before doing anything else, so that we can catch that problem as soon as it appears. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@145748 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Symbol/ClangExternalASTSourceCommon.cpp
|