LLDB  mainline
SymbolFileNativePDB.h
Go to the documentation of this file.
1 //===-- SymbolFileNativePDB.h -----------------------------------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
9 #ifndef LLDB_SOURCE_PLUGINS_SYMBOLFILE_NATIVEPDB_SYMBOLFILENATIVEPDB_H
10 #define LLDB_SOURCE_PLUGINS_SYMBOLFILE_NATIVEPDB_SYMBOLFILENATIVEPDB_H
11 
12 #include "lldb/Symbol/SymbolFile.h"
13 
14 #include "llvm/ADT/DenseMap.h"
15 #include "llvm/DebugInfo/CodeView/CVRecord.h"
16 #include "llvm/DebugInfo/CodeView/SymbolRecord.h"
17 #include "llvm/DebugInfo/PDB/PDBTypes.h"
18 
19 #include "CompileUnitIndex.h"
20 #include "PdbIndex.h"
21 
22 namespace clang {
23 class TagDecl;
24 }
25 
26 namespace llvm {
27 namespace codeview {
28 class ClassRecord;
29 class EnumRecord;
30 class ModifierRecord;
31 class PointerRecord;
32 struct UnionRecord;
33 } // namespace codeview
34 } // namespace llvm
35 
36 namespace lldb_private {
37 
38 namespace npdb {
39 class PdbAstBuilder;
40 
42  friend class UdtRecordCompleter;
43 
44  /// LLVM RTTI support.
45  static char ID;
46 
47 public:
48  /// LLVM RTTI support.
49  /// \{
50  bool isA(const void *ClassID) const override {
51  return ClassID == &ID || SymbolFile::isA(ClassID);
52  }
53  static bool classof(const SymbolFile *obj) { return obj->isA(&ID); }
54  /// \}
55 
56  // Static Functions
57  static void Initialize();
58 
59  static void Terminate();
60 
61  static void DebuggerInitialize(Debugger &debugger);
62 
64 
65  static const char *GetPluginDescriptionStatic();
66 
67  static SymbolFile *CreateInstance(lldb::ObjectFileSP objfile_sp);
68 
69  // Constructors and Destructors
70  SymbolFileNativePDB(lldb::ObjectFileSP objfile_sp);
71 
72  ~SymbolFileNativePDB() override;
73 
74  uint32_t CalculateAbilities() override;
75 
76  void InitializeObject() override;
77 
78  // Compile Unit function calls
79 
80  void
82 
84  ParseLanguage(lldb_private::CompileUnit &comp_unit) override;
85 
86  size_t ParseFunctions(lldb_private::CompileUnit &comp_unit) override;
87 
88  bool ParseLineTable(lldb_private::CompileUnit &comp_unit) override;
89 
90  bool ParseDebugMacros(lldb_private::CompileUnit &comp_unit) override;
91 
93  FileSpecList &support_files) override;
94  size_t ParseTypes(lldb_private::CompileUnit &comp_unit) override;
95 
97  const SymbolContext &sc,
98  std::vector<lldb_private::SourceModule> &imported_modules) override;
99 
100  size_t ParseBlocksRecursive(Function &func) override;
101 
103  const CompilerDeclContext &parent_decl_ctx,
104  uint32_t max_matches,
105  VariableList &variables) override;
106 
107  size_t ParseVariablesForContext(const SymbolContext &sc) override;
108 
109  void AddSymbols(Symtab &symtab) override;
110 
114  Type *ResolveTypeUID(lldb::user_id_t type_uid) override;
115  llvm::Optional<ArrayInfo> GetDynamicArrayInfoForUID(
116  lldb::user_id_t type_uid,
117  const lldb_private::ExecutionContext *exe_ctx) override;
118 
119  bool CompleteType(CompilerType &compiler_type) override;
120  uint32_t ResolveSymbolContext(const Address &so_addr,
121  lldb::SymbolContextItem resolve_scope,
122  SymbolContext &sc) override;
123  uint32_t ResolveSymbolContext(const SourceLocationSpec &src_location_spec,
124  lldb::SymbolContextItem resolve_scope,
125  SymbolContextList &sc_list) override;
126 
127  void GetTypes(SymbolContextScope *sc_scope, lldb::TypeClass type_mask,
128  TypeList &type_list) override;
129 
130  void FindFunctions(ConstString name,
131  const CompilerDeclContext &parent_decl_ctx,
132  lldb::FunctionNameType name_type_mask,
133  bool include_inlines, SymbolContextList &sc_list) override;
134 
135  void FindFunctions(const RegularExpression &regex, bool include_inlines,
136  SymbolContextList &sc_list) override;
137 
138  void FindTypes(ConstString name, const CompilerDeclContext &parent_decl_ctx,
139  uint32_t max_matches,
140  llvm::DenseSet<SymbolFile *> &searched_symbol_files,
141  TypeMap &types) override;
142 
143  void FindTypes(llvm::ArrayRef<CompilerContext> pattern, LanguageSet languages,
144  llvm::DenseSet<SymbolFile *> &searched_symbol_files,
145  TypeMap &types) override;
146 
147  llvm::Expected<TypeSystem &>
148  GetTypeSystemForLanguage(lldb::LanguageType language) override;
149 
152  const CompilerDeclContext &parent_decl_ctx) override;
153 
154  llvm::StringRef GetPluginName() override {
156  }
157 
158  llvm::pdb::PDBFile &GetPDBFile() { return m_index->pdb(); }
159  const llvm::pdb::PDBFile &GetPDBFile() const { return m_index->pdb(); }
160 
161  void DumpClangAST(Stream &s) override;
162 
163 private:
165 
166  lldb::CompUnitSP ParseCompileUnitAtIndex(uint32_t index) override;
167 
168  void FindTypesByName(llvm::StringRef name, uint32_t max_matches,
169  TypeMap &types);
170 
171  lldb::TypeSP CreateModifierType(PdbTypeSymId type_id,
172  const llvm::codeview::ModifierRecord &mr,
173  CompilerType ct);
174  lldb::TypeSP CreatePointerType(PdbTypeSymId type_id,
175  const llvm::codeview::PointerRecord &pr,
176  CompilerType ct);
177  lldb::TypeSP CreateSimpleType(llvm::codeview::TypeIndex ti, CompilerType ct);
178  lldb::TypeSP CreateTagType(PdbTypeSymId type_id,
179  const llvm::codeview::ClassRecord &cr,
180  CompilerType ct);
181  lldb::TypeSP CreateTagType(PdbTypeSymId type_id,
182  const llvm::codeview::EnumRecord &er,
183  CompilerType ct);
184  lldb::TypeSP CreateTagType(PdbTypeSymId type_id,
185  const llvm::codeview::UnionRecord &ur,
186  CompilerType ct);
187  lldb::TypeSP CreateArrayType(PdbTypeSymId type_id,
188  const llvm::codeview::ArrayRecord &ar,
189  CompilerType ct);
190  lldb::TypeSP CreateFunctionType(PdbTypeSymId type_id,
191  const llvm::codeview::MemberFunctionRecord &pr,
192  CompilerType ct);
193  lldb::TypeSP CreateProcedureType(PdbTypeSymId type_id,
194  const llvm::codeview::ProcedureRecord &pr,
195  CompilerType ct);
196  lldb::TypeSP CreateClassStructUnion(PdbTypeSymId type_id,
197  const llvm::codeview::TagRecord &record,
198  size_t size, CompilerType ct);
199 
200  lldb::FunctionSP GetOrCreateFunction(PdbCompilandSymId func_id,
201  CompileUnit &comp_unit);
202  lldb::CompUnitSP GetOrCreateCompileUnit(const CompilandIndexItem &cci);
203  lldb::TypeSP GetOrCreateType(PdbTypeSymId type_id);
204  lldb::TypeSP GetOrCreateType(llvm::codeview::TypeIndex ti);
205  lldb::VariableSP GetOrCreateGlobalVariable(PdbGlobalSymId var_id);
207  lldb::VariableSP GetOrCreateLocalVariable(PdbCompilandSymId scope_id,
208  PdbCompilandSymId var_id,
209  bool is_param);
210  lldb::TypeSP GetOrCreateTypedef(PdbGlobalSymId id);
211 
212  lldb::FunctionSP CreateFunction(PdbCompilandSymId func_id,
213  CompileUnit &comp_unit);
215  lldb::VariableSP CreateLocalVariable(PdbCompilandSymId scope_id,
216  PdbCompilandSymId var_id, bool is_param);
217  lldb::TypeSP CreateTypedef(PdbGlobalSymId id);
218  lldb::CompUnitSP CreateCompileUnit(const CompilandIndexItem &cci);
219  lldb::TypeSP CreateType(PdbTypeSymId type_id, CompilerType ct);
220  lldb::TypeSP CreateAndCacheType(PdbTypeSymId type_id);
221  lldb::VariableSP CreateGlobalVariable(PdbGlobalSymId var_id);
222  lldb::VariableSP CreateConstantSymbol(PdbGlobalSymId var_id,
223  const llvm::codeview::CVSymbol &cvs);
224  size_t ParseVariablesForCompileUnit(CompileUnit &comp_unit,
225  VariableList &variables);
226  size_t ParseVariablesForBlock(PdbCompilandSymId block_id);
227 
228  llvm::BumpPtrAllocator m_allocator;
229 
231  bool m_done_full_type_scan = false;
232 
233  std::unique_ptr<llvm::pdb::PDBFile> m_file_up;
234  std::unique_ptr<PdbIndex> m_index;
235 
236  std::unique_ptr<PdbAstBuilder> m_ast;
237 
238  llvm::DenseMap<lldb::user_id_t, lldb::VariableSP> m_global_vars;
239  llvm::DenseMap<lldb::user_id_t, lldb::VariableSP> m_local_variables;
240  llvm::DenseMap<lldb::user_id_t, lldb::BlockSP> m_blocks;
241  llvm::DenseMap<lldb::user_id_t, lldb::FunctionSP> m_functions;
242  llvm::DenseMap<lldb::user_id_t, lldb::CompUnitSP> m_compilands;
243  llvm::DenseMap<lldb::user_id_t, lldb::TypeSP> m_types;
244 };
245 
246 } // namespace npdb
247 } // namespace lldb_private
248 
249 #endif // LLDB_SOURCE_PLUGINS_SYMBOLFILE_NATIVEPDB_SYMBOLFILENATIVEPDB_H
lldb_private::SymbolFile
Definition: SymbolFile.h:37
lldb_private::ExecutionContext
Definition: ExecutionContext.h:292
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateLocalVariable
lldb::VariableSP GetOrCreateLocalVariable(PdbCompilandSymId scope_id, PdbCompilandSymId var_id, bool is_param)
Definition: SymbolFileNativePDB.cpp:1346
llvm
Definition: Debugger.h:49
lldb_private::RegularExpression
Definition: RegularExpression.h:18
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateTypedef
lldb::TypeSP GetOrCreateTypedef(PdbGlobalSymId id)
Definition: SymbolFileNativePDB.cpp:1374
lldb_private::npdb::SymbolFileNativePDB::m_ast
std::unique_ptr< PdbAstBuilder > m_ast
Definition: SymbolFileNativePDB.h:236
lldb_private::npdb::SymbolFileNativePDB::CreateGlobalVariable
lldb::VariableSP CreateGlobalVariable(PdbGlobalSymId var_id)
Definition: SymbolFileNativePDB.cpp:724
lldb_private::npdb::SymbolFileNativePDB::Terminate
static void Terminate()
Definition: SymbolFileNativePDB.cpp:237
lldb_private::npdb::SymbolFileNativePDB::CreateFunctionType
lldb::TypeSP CreateFunctionType(PdbTypeSymId type_id, const llvm::codeview::MemberFunctionRecord &pr, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:586
lldb_private::npdb::SymbolFileNativePDB::CreateSimpleType
lldb::TypeSP CreateSimpleType(llvm::codeview::TypeIndex ti, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:467
lldb_private::npdb::SymbolFileNativePDB::ParseLineTable
bool ParseLineTable(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:1045
lldb_private::SourceLocationSpec
Definition: SourceLocationSpec.h:27
lldb_private::npdb::SymbolFileNativePDB
Definition: SymbolFileNativePDB.h:41
lldb_private::npdb::SymbolFileNativePDB::ParseTypes
size_t ParseTypes(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:1259
lldb_private::npdb::SymbolFileNativePDB::FindTypes
void FindTypes(ConstString name, const CompilerDeclContext &parent_decl_ctx, uint32_t max_matches, llvm::DenseSet< SymbolFile * > &searched_symbol_files, TypeMap &types) override
Definition: SymbolFileNativePDB.cpp:1223
lldb_private::npdb::PdbCompilandSymId
Definition: PdbSymUid.h:44
lldb_private::npdb::SymbolFileNativePDB::m_index
std::unique_ptr< PdbIndex > m_index
Definition: SymbolFileNativePDB.h:234
lldb_private::npdb::SymbolFileNativePDB::ParseBlocksRecursive
size_t ParseBlocksRecursive(Function &func) override
Definition: SymbolFileNativePDB.cpp:1149
lldb_private::npdb::SymbolFileNativePDB::GetTypes
void GetTypes(SymbolContextScope *sc_scope, lldb::TypeClass type_mask, TypeList &type_list) override
Definition: SymbolFileNativePDB.cpp:1550
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateGlobalVariable
lldb::VariableSP GetOrCreateGlobalVariable(PdbGlobalSymId var_id)
Definition: SymbolFileNativePDB.cpp:833
lldb_private::npdb::SymbolFileNativePDB::CreateFunction
lldb::FunctionSP CreateFunction(PdbCompilandSymId func_id, CompileUnit &comp_unit)
Definition: SymbolFileNativePDB.cpp:366
lldb_private::npdb::SymbolFileNativePDB::CreateConstantSymbol
lldb::VariableSP CreateConstantSymbol(PdbGlobalSymId var_id, const llvm::codeview::CVSymbol &cvs)
Definition: SymbolFileNativePDB.cpp:803
lldb::LanguageType
LanguageType
Programming language type.
Definition: lldb-enumerations.h:436
lldb_private::SymbolContextList
Definition: SymbolContext.h:379
lldb_private::CompilerDecl
Represents a generic declaration such as a function declaration.
Definition: CompilerDecl.h:28
lldb_private::npdb::SymbolFileNativePDB::ResolveSymbolContext
uint32_t ResolveSymbolContext(const Address &so_addr, lldb::SymbolContextItem resolve_scope, SymbolContext &sc) override
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateType
lldb::TypeSP GetOrCreateType(PdbTypeSymId type_id)
Definition: SymbolFileNativePDB.cpp:710
CompileUnitIndex.h
lldb_private::npdb::SymbolFileNativePDB::m_obj_load_address
lldb::addr_t m_obj_load_address
Definition: SymbolFileNativePDB.h:230
lldb_private::Stream
Definition: Stream.h:28
lldb::addr_t
uint64_t addr_t
Definition: lldb-types.h:83
lldb_private::npdb::SymbolFileNativePDB::GetDeclContextForUID
CompilerDeclContext GetDeclContextForUID(lldb::user_id_t uid) override
Definition: SymbolFileNativePDB.cpp:1500
lldb_private::npdb::SymbolFileNativePDB::CreateTagType
lldb::TypeSP CreateTagType(PdbTypeSymId type_id, const llvm::codeview::ClassRecord &cr, CompilerType ct)
lldb_private::npdb::SymbolFileNativePDB::CreateInstance
static SymbolFile * CreateInstance(lldb::ObjectFileSP objfile_sp)
Definition: SymbolFileNativePDB.cpp:252
lldb_private::npdb::SymbolFileNativePDB::CreateCompileUnit
lldb::CompUnitSP CreateCompileUnit(const CompilandIndexItem &cci)
Definition: SymbolFileNativePDB.cpp:407
lldb_private::npdb::SymbolFileNativePDB::GetTypeSystemForLanguage
llvm::Expected< TypeSystem & > GetTypeSystemForLanguage(lldb::LanguageType language) override
Definition: SymbolFileNativePDB.cpp:1561
lldb_private::SymbolContext
Definition: SymbolContext.h:33
lldb_private::npdb::SymbolFileNativePDB::ResolveTypeUID
Type * ResolveTypeUID(lldb::user_id_t type_uid) override
Definition: SymbolFileNativePDB.cpp:1515
lldb_private::npdb::SymbolFileNativePDB::CompleteType
bool CompleteType(CompilerType &compiler_type) override
Definition: SymbolFileNativePDB.cpp:1543
lldb_private::VariableList
Definition: VariableList.h:18
PdbIndex.h
lldb_private::npdb::SymbolFileNativePDB::ParseImportedModules
bool ParseImportedModules(const SymbolContext &sc, std::vector< lldb_private::SourceModule > &imported_modules) override
Definition: SymbolFileNativePDB.cpp:1143
lldb_private::npdb::SymbolFileNativePDB::GetDeclContextContainingUID
CompilerDeclContext GetDeclContextContainingUID(lldb::user_id_t uid) override
Definition: SymbolFileNativePDB.cpp:1510
lldb_private::CompileUnit
Definition: CompileUnit.h:38
lldb_private::npdb::SymbolFileNativePDB::GetPluginNameStatic
static ConstString GetPluginNameStatic()
Definition: SymbolFileNativePDB.cpp:243
lldb_private::npdb::SymbolFileNativePDB::CreateLocalVariable
lldb::VariableSP CreateLocalVariable(PdbCompilandSymId scope_id, PdbCompilandSymId var_id, bool is_param)
Definition: SymbolFileNativePDB.cpp:1310
lldb_private::Function
Definition: Function.h:413
lldb_private::npdb::SymbolFileNativePDB::GetDynamicArrayInfoForUID
llvm::Optional< ArrayInfo > GetDynamicArrayInfoForUID(lldb::user_id_t type_uid, const lldb_private::ExecutionContext *exe_ctx) override
If type_uid points to an array type, return its characteristics.
Definition: SymbolFileNativePDB.cpp:1537
lldb_private::npdb::PdbGlobalSymId
Definition: PdbSymUid.h:57
lldb_private::npdb::SymbolFileNativePDB::GetPluginName
llvm::StringRef GetPluginName() override
Definition: SymbolFileNativePDB.h:154
lldb_private::npdb::SymbolFileNativePDB::CreateTypedef
lldb::TypeSP CreateTypedef(PdbGlobalSymId id)
Definition: SymbolFileNativePDB.cpp:1355
lldb_private::npdb::SymbolFileNativePDB::m_global_vars
llvm::DenseMap< lldb::user_id_t, lldb::VariableSP > m_global_vars
Definition: SymbolFileNativePDB.h:238
lldb_private::ConstString::GetStringRef
llvm::StringRef GetStringRef() const
Get the string value as a llvm::StringRef.
Definition: ConstString.h:202
lldb_private::npdb::SymbolFileNativePDB::ParseVariablesForContext
size_t ParseVariablesForContext(const SymbolContext &sc) override
Definition: SymbolFileNativePDB.cpp:1461
lldb_private::npdb::SymbolFileNativePDB::classof
static bool classof(const SymbolFile *obj)
Definition: SymbolFileNativePDB.h:53
lldb_private::npdb::SymbolFileNativePDB::CreateClassStructUnion
lldb::TypeSP CreateClassStructUnion(PdbTypeSymId type_id, const llvm::codeview::TagRecord &record, size_t size, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:530
lldb_private::npdb::SymbolFileNativePDB::ParseLanguage
lldb::LanguageType ParseLanguage(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:894
lldb_private::npdb::SymbolFileNativePDB::m_functions
llvm::DenseMap< lldb::user_id_t, lldb::FunctionSP > m_functions
Definition: SymbolFileNativePDB.h:241
lldb_private::npdb::SymbolFileNativePDB::m_local_variables
llvm::DenseMap< lldb::user_id_t, lldb::VariableSP > m_local_variables
Definition: SymbolFileNativePDB.h:239
lldb_private::npdb::SymbolFileNativePDB::FindNamespace
CompilerDeclContext FindNamespace(ConstString name, const CompilerDeclContext &parent_decl_ctx) override
Definition: SymbolFileNativePDB.cpp:1555
lldb_private::npdb::SymbolFileNativePDB::m_types
llvm::DenseMap< lldb::user_id_t, lldb::TypeSP > m_types
Definition: SymbolFileNativePDB.h:243
lldb_private::npdb::SymbolFileNativePDB::ParseCompileUnitAtIndex
lldb::CompUnitSP ParseCompileUnitAtIndex(uint32_t index) override
Definition: SymbolFileNativePDB.cpp:882
lldb_private::ConstString
Definition: ConstString.h:40
lldb_private::npdb::SymbolFileNativePDB::CreatePointerType
lldb::TypeSP CreatePointerType(PdbTypeSymId type_id, const llvm::codeview::PointerRecord &pr, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:448
lldb_private::npdb::SymbolFileNativePDB::DebuggerInitialize
static void DebuggerInitialize(Debugger &debugger)
Definition: SymbolFileNativePDB.cpp:241
lldb_private::npdb::PdbTypeSymId
Definition: PdbSymUid.h:70
lldb_private::npdb::SymbolFileNativePDB::ParseVariablesForBlock
size_t ParseVariablesForBlock(PdbCompilandSymId block_id)
Definition: SymbolFileNativePDB.cpp:1382
lldb_private::npdb::SymbolFileNativePDB::CreateBlock
Block & CreateBlock(PdbCompilandSymId block_id)
Definition: SymbolFileNativePDB.cpp:335
lldb_private::SymbolFile::isA
virtual bool isA(const void *ClassID) const
LLVM RTTI support.
Definition: SymbolFile.h:44
lldb_private::npdb::SymbolFileNativePDB::GetPDBFile
llvm::pdb::PDBFile & GetPDBFile()
Definition: SymbolFileNativePDB.h:158
lldb_private::npdb::SymbolFileNativePDB::FindTypesByName
void FindTypesByName(llvm::StringRef name, uint32_t max_matches, TypeMap &types)
Definition: SymbolFileNativePDB.cpp:1242
lldb_private::npdb::SymbolFileNativePDB::CreateModifierType
lldb::TypeSP CreateModifierType(PdbTypeSymId type_id, const llvm::codeview::ModifierRecord &mr, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:428
lldb_private::Debugger
Definition: Debugger.h:70
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateCompileUnit
lldb::CompUnitSP GetOrCreateCompileUnit(const CompilandIndexItem &cci)
Definition: SymbolFileNativePDB.cpp:855
lldb_private::TypeMap
Definition: TypeMap.h:20
lldb_private::npdb::SymbolFileNativePDB::ParseDeclsForContext
void ParseDeclsForContext(lldb_private::CompilerDeclContext decl_ctx) override
Definition: SymbolFileNativePDB.cpp:874
lldb_private::CompilerDeclContext
Represents a generic declaration context in a program.
Definition: CompilerDeclContext.h:30
lldb_private::SymbolContextScope
Definition: SymbolContextScope.h:64
lldb_private::npdb::SymbolFileNativePDB::DumpClangAST
void DumpClangAST(Stream &s) override
Definition: SymbolFileNativePDB.cpp:1156
lldb_private::npdb::SymbolFileNativePDB::GetPluginDescriptionStatic
static const char * GetPluginDescriptionStatic()
Definition: SymbolFileNativePDB.cpp:248
lldb_private::npdb::SymbolFileNativePDB::SymbolFileNativePDB
SymbolFileNativePDB(lldb::ObjectFileSP objfile_sp)
Definition: SymbolFileNativePDB.cpp:256
lldb_private::npdb::SymbolFileNativePDB::ParseFunctions
size_t ParseFunctions(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:910
lldb_private::npdb::CompilandIndexItem
Represents a single compile unit.
Definition: CompileUnitIndex.h:37
lldb_private::npdb::SymbolFileNativePDB::AddSymbols
void AddSymbols(Symtab &symtab) override
Definition: SymbolFileNativePDB.cpp:908
lldb_private::npdb::SymbolFileNativePDB::ID
static char ID
LLVM RTTI support.
Definition: SymbolFileNativePDB.h:45
lldb_private::Block
Definition: Block.h:41
lldb_private::npdb::SymbolFileNativePDB::m_allocator
llvm::BumpPtrAllocator m_allocator
Definition: SymbolFileNativePDB.h:228
lldb_private::Symtab
Definition: Symtab.h:22
uint32_t
lldb_private::npdb::SymbolFileNativePDB::CalculateAbilities
uint32_t CalculateAbilities() override
Definition: SymbolFileNativePDB.cpp:261
lldb_private::npdb::UdtRecordCompleter
Definition: UdtRecordCompleter.h:39
lldb_private::Address
Definition: Address.h:59
lldb_private::npdb::SymbolFileNativePDB::ParseSupportFiles
bool ParseSupportFiles(lldb_private::CompileUnit &comp_unit, FileSpecList &support_files) override
Definition: SymbolFileNativePDB.cpp:1125
lldb_private::npdb::SymbolFileNativePDB::ParseDebugMacros
bool ParseDebugMacros(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:1120
lldb_private::npdb::SymbolFileNativePDB::m_file_up
std::unique_ptr< llvm::pdb::PDBFile > m_file_up
Definition: SymbolFileNativePDB.h:233
lldb_private::npdb::SymbolFileNativePDB::InitializeObject
void InitializeObject() override
Initialize the SymbolFile object.
Definition: SymbolFileNativePDB.cpp:299
lldb_private::Type
Definition: Type.h:66
lldb_private::npdb::SymbolFileNativePDB::CalculateNumCompileUnits
uint32_t CalculateNumCompileUnits() override
Definition: SymbolFileNativePDB.cpp:320
lldb_private::npdb::SymbolFileNativePDB::FindGlobalVariables
void FindGlobalVariables(ConstString name, const CompilerDeclContext &parent_decl_ctx, uint32_t max_matches, VariableList &variables) override
Definition: SymbolFileNativePDB.cpp:1158
lldb_private::npdb::SymbolFileNativePDB::CreateAndCacheType
lldb::TypeSP CreateAndCacheType(PdbTypeSymId type_id)
Definition: SymbolFileNativePDB.cpp:665
clang
Definition: ASTResultSynthesizer.h:15
lldb_private::CompilerType
Generic representation of a type in a programming language.
Definition: CompilerType.h:33
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateFunction
lldb::FunctionSP GetOrCreateFunction(PdbCompilandSymId func_id, CompileUnit &comp_unit)
Definition: SymbolFileNativePDB.cpp:845
lldb::user_id_t
uint64_t user_id_t
Definition: lldb-types.h:84
lldb_private
A class that represents a running process on the host machine.
Definition: SBCommandInterpreterRunOptions.h:16
lldb_private::npdb::SymbolFileNativePDB::~SymbolFileNativePDB
~SymbolFileNativePDB() override
lldb_private::TypeList
Definition: TypeList.h:20
lldb_private::npdb::SymbolFileNativePDB::ParseVariablesForCompileUnit
size_t ParseVariablesForCompileUnit(CompileUnit &comp_unit, VariableList &variables)
Definition: SymbolFileNativePDB.cpp:1303
lldb_private::LanguageSet
A SmallBitVector that represents a set of source languages (lldb::LanguageType).
Definition: TypeSystem.h:40
lldb_private::npdb::SymbolFileNativePDB::CreateProcedureType
lldb::TypeSP CreateProcedureType(PdbTypeSymId type_id, const llvm::codeview::ProcedureRecord &pr, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:596
lldb_private::npdb::SymbolFileNativePDB::CreateArrayType
lldb::TypeSP CreateArrayType(PdbTypeSymId type_id, const llvm::codeview::ArrayRecord &ar, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:571
lldb_private::npdb::SymbolFileNativePDB::GetDeclForUID
CompilerDecl GetDeclForUID(lldb::user_id_t uid) override
Definition: SymbolFileNativePDB.cpp:1492
lldb_private::npdb::SymbolFileNativePDB::m_compilands
llvm::DenseMap< lldb::user_id_t, lldb::CompUnitSP > m_compilands
Definition: SymbolFileNativePDB.h:242
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateBlock
Block & GetOrCreateBlock(PdbCompilandSymId block_id)
Definition: SymbolFileNativePDB.cpp:866
lldb_private::npdb::SymbolFileNativePDB::CreateType
lldb::TypeSP CreateType(PdbTypeSymId type_id, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:606
lldb_private::npdb::SymbolFileNativePDB::m_blocks
llvm::DenseMap< lldb::user_id_t, lldb::BlockSP > m_blocks
Definition: SymbolFileNativePDB.h:240
lldb_private::npdb::SymbolFileNativePDB::m_done_full_type_scan
bool m_done_full_type_scan
Definition: SymbolFileNativePDB.h:231
SymbolFile.h
lldb_private::npdb::SymbolFileNativePDB::Initialize
static void Initialize()
Definition: SymbolFileNativePDB.cpp:231
lldb_private::npdb::SymbolFileNativePDB::GetPDBFile
const llvm::pdb::PDBFile & GetPDBFile() const
Definition: SymbolFileNativePDB.h:159
lldb_private::npdb::SymbolFileNativePDB::isA
bool isA(const void *ClassID) const override
LLVM RTTI support.
Definition: SymbolFileNativePDB.h:50
lldb_private::npdb::SymbolFileNativePDB::FindFunctions
void FindFunctions(ConstString name, const CompilerDeclContext &parent_decl_ctx, lldb::FunctionNameType name_type_mask, bool include_inlines, SymbolContextList &sc_list) override