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/LineTable.h"
13 #include "lldb/Symbol/SymbolFile.h"
14 
15 #include "llvm/ADT/DenseMap.h"
16 #include "llvm/DebugInfo/CodeView/CVRecord.h"
17 #include "llvm/DebugInfo/CodeView/SymbolRecord.h"
18 #include "llvm/DebugInfo/PDB/PDBTypes.h"
19 
20 #include "CompileUnitIndex.h"
21 #include "PdbIndex.h"
22 
23 namespace clang {
24 class TagDecl;
25 }
26 
27 namespace llvm {
28 namespace codeview {
29 class ClassRecord;
30 class EnumRecord;
31 class ModifierRecord;
32 class PointerRecord;
33 struct UnionRecord;
34 } // namespace codeview
35 } // namespace llvm
36 
37 namespace lldb_private {
38 
39 namespace npdb {
40 class PdbAstBuilder;
41 
43  friend class UdtRecordCompleter;
44 
45  /// LLVM RTTI support.
46  static char ID;
47 
48 public:
49  /// LLVM RTTI support.
50  /// \{
51  bool isA(const void *ClassID) const override {
52  return ClassID == &ID || SymbolFileCommon::isA(ClassID);
53  }
54  static bool classof(const SymbolFile *obj) { return obj->isA(&ID); }
55  /// \}
56 
57  // Static Functions
58  static void Initialize();
59 
60  static void Terminate();
61 
62  static void DebuggerInitialize(Debugger &debugger);
63 
64  static llvm::StringRef GetPluginNameStatic() { return "native-pdb"; }
65 
66  static llvm::StringRef GetPluginDescriptionStatic();
67 
68  static SymbolFile *CreateInstance(lldb::ObjectFileSP objfile_sp);
69 
70  // Constructors and Destructors
71  SymbolFileNativePDB(lldb::ObjectFileSP objfile_sp);
72 
73  ~SymbolFileNativePDB() override;
74 
75  uint32_t CalculateAbilities() override;
76 
77  void InitializeObject() override;
78 
79  uint64_t GetDebugInfoSize() override;
80 
81  // Compile Unit function calls
82 
83  void
85 
87  ParseLanguage(lldb_private::CompileUnit &comp_unit) override;
88 
89  size_t ParseFunctions(lldb_private::CompileUnit &comp_unit) override;
90 
91  bool ParseLineTable(lldb_private::CompileUnit &comp_unit) override;
92 
93  bool ParseDebugMacros(lldb_private::CompileUnit &comp_unit) override;
94 
96  FileSpecList &support_files) override;
97  size_t ParseTypes(lldb_private::CompileUnit &comp_unit) override;
98 
100  const SymbolContext &sc,
101  std::vector<lldb_private::SourceModule> &imported_modules) override;
102 
103  size_t ParseBlocksRecursive(Function &func) override;
104 
106  const CompilerDeclContext &parent_decl_ctx,
107  uint32_t max_matches,
108  VariableList &variables) override;
109 
110  size_t ParseVariablesForContext(const SymbolContext &sc) override;
111 
112  void AddSymbols(Symtab &symtab) override;
113 
117  Type *ResolveTypeUID(lldb::user_id_t type_uid) override;
118  llvm::Optional<ArrayInfo> GetDynamicArrayInfoForUID(
119  lldb::user_id_t type_uid,
120  const lldb_private::ExecutionContext *exe_ctx) override;
121 
122  bool CompleteType(CompilerType &compiler_type) override;
123  uint32_t ResolveSymbolContext(const Address &so_addr,
124  lldb::SymbolContextItem resolve_scope,
125  SymbolContext &sc) override;
126  uint32_t ResolveSymbolContext(const SourceLocationSpec &src_location_spec,
127  lldb::SymbolContextItem resolve_scope,
128  SymbolContextList &sc_list) override;
129 
130  void GetTypes(SymbolContextScope *sc_scope, lldb::TypeClass type_mask,
131  TypeList &type_list) override;
132 
133  void FindFunctions(ConstString name,
134  const CompilerDeclContext &parent_decl_ctx,
135  lldb::FunctionNameType name_type_mask,
136  bool include_inlines, SymbolContextList &sc_list) override;
137 
138  void FindFunctions(const RegularExpression &regex, bool include_inlines,
139  SymbolContextList &sc_list) override;
140 
141  void FindTypes(ConstString name, const CompilerDeclContext &parent_decl_ctx,
142  uint32_t max_matches,
143  llvm::DenseSet<SymbolFile *> &searched_symbol_files,
144  TypeMap &types) override;
145 
146  void FindTypes(llvm::ArrayRef<CompilerContext> pattern, LanguageSet languages,
147  llvm::DenseSet<SymbolFile *> &searched_symbol_files,
148  TypeMap &types) override;
149 
150  llvm::Expected<TypeSystem &>
151  GetTypeSystemForLanguage(lldb::LanguageType language) override;
152 
155  const CompilerDeclContext &parent_decl_ctx) override;
156 
157  llvm::StringRef GetPluginName() override { return GetPluginNameStatic(); }
158 
159  llvm::pdb::PDBFile &GetPDBFile() { return m_index->pdb(); }
160  const llvm::pdb::PDBFile &GetPDBFile() const { return m_index->pdb(); }
161 
162  void DumpClangAST(Stream &s) override;
163 
164 private:
167  const lldb_private::LineTable::Entry &rhs) const {
168  return lhs.file_addr < rhs.file_addr;
169  }
170  };
171 
172  // From address range relative to function base to source line number.
173  using RangeSourceLineVector =
175  // InlineSite contains information in a S_INLINESITE record.
176  struct InlineSite {
178  std::shared_ptr<InlineFunctionInfo> inline_function_info;
180  std::vector<lldb_private::LineTable::Entry> line_entries;
182  };
183 
185 
186  lldb::CompUnitSP ParseCompileUnitAtIndex(uint32_t index) override;
187 
188  void FindTypesByName(llvm::StringRef name, uint32_t max_matches,
189  TypeMap &types);
190 
191  lldb::TypeSP CreateModifierType(PdbTypeSymId type_id,
192  const llvm::codeview::ModifierRecord &mr,
193  CompilerType ct);
194  lldb::TypeSP CreatePointerType(PdbTypeSymId type_id,
195  const llvm::codeview::PointerRecord &pr,
196  CompilerType ct);
197  lldb::TypeSP CreateSimpleType(llvm::codeview::TypeIndex ti, CompilerType ct);
198  lldb::TypeSP CreateTagType(PdbTypeSymId type_id,
199  const llvm::codeview::ClassRecord &cr,
200  CompilerType ct);
201  lldb::TypeSP CreateTagType(PdbTypeSymId type_id,
202  const llvm::codeview::EnumRecord &er,
203  CompilerType ct);
204  lldb::TypeSP CreateTagType(PdbTypeSymId type_id,
205  const llvm::codeview::UnionRecord &ur,
206  CompilerType ct);
207  lldb::TypeSP CreateArrayType(PdbTypeSymId type_id,
208  const llvm::codeview::ArrayRecord &ar,
209  CompilerType ct);
210  lldb::TypeSP CreateFunctionType(PdbTypeSymId type_id,
211  const llvm::codeview::MemberFunctionRecord &pr,
212  CompilerType ct);
213  lldb::TypeSP CreateProcedureType(PdbTypeSymId type_id,
214  const llvm::codeview::ProcedureRecord &pr,
215  CompilerType ct);
216  lldb::TypeSP CreateClassStructUnion(PdbTypeSymId type_id,
217  const llvm::codeview::TagRecord &record,
218  size_t size, CompilerType ct);
219 
220  lldb::FunctionSP GetOrCreateFunction(PdbCompilandSymId func_id,
221  CompileUnit &comp_unit);
222  lldb::CompUnitSP GetOrCreateCompileUnit(const CompilandIndexItem &cci);
223  lldb::TypeSP GetOrCreateType(PdbTypeSymId type_id);
224  lldb::TypeSP GetOrCreateType(llvm::codeview::TypeIndex ti);
225  lldb::VariableSP GetOrCreateGlobalVariable(PdbGlobalSymId var_id);
227  lldb::VariableSP GetOrCreateLocalVariable(PdbCompilandSymId scope_id,
228  PdbCompilandSymId var_id,
229  bool is_param);
230  lldb::TypeSP GetOrCreateTypedef(PdbGlobalSymId id);
231 
232  lldb::FunctionSP CreateFunction(PdbCompilandSymId func_id,
233  CompileUnit &comp_unit);
235  lldb::VariableSP CreateLocalVariable(PdbCompilandSymId scope_id,
236  PdbCompilandSymId var_id, bool is_param);
237  lldb::TypeSP CreateTypedef(PdbGlobalSymId id);
238  lldb::CompUnitSP CreateCompileUnit(const CompilandIndexItem &cci);
239  lldb::TypeSP CreateType(PdbTypeSymId type_id, CompilerType ct);
240  lldb::TypeSP CreateAndCacheType(PdbTypeSymId type_id);
241  lldb::VariableSP CreateGlobalVariable(PdbGlobalSymId var_id);
242  lldb::VariableSP CreateConstantSymbol(PdbGlobalSymId var_id,
243  const llvm::codeview::CVSymbol &cvs);
244  size_t ParseVariablesForCompileUnit(CompileUnit &comp_unit,
245  VariableList &variables);
246  size_t ParseVariablesForBlock(PdbCompilandSymId block_id);
247 
248  llvm::Expected<uint32_t> GetFileIndex(const CompilandIndexItem &cii,
249  uint32_t file_id);
250 
252  PdbCompilandSymId parent,
253  llvm::function_ref<bool(llvm::codeview::SymbolKind, PdbCompilandSymId)>
254  fn);
255 
256  void ParseInlineSite(PdbCompilandSymId inline_site_id, Address func_addr);
257 
258  llvm::BumpPtrAllocator m_allocator;
259 
261  bool m_done_full_type_scan = false;
262 
263  std::unique_ptr<llvm::pdb::PDBFile> m_file_up;
264  std::unique_ptr<PdbIndex> m_index;
265 
266  std::unique_ptr<PdbAstBuilder> m_ast;
267 
268  llvm::DenseMap<lldb::user_id_t, lldb::VariableSP> m_global_vars;
269  llvm::DenseMap<lldb::user_id_t, lldb::VariableSP> m_local_variables;
270  llvm::DenseMap<lldb::user_id_t, lldb::BlockSP> m_blocks;
271  llvm::DenseMap<lldb::user_id_t, lldb::FunctionSP> m_functions;
272  llvm::DenseMap<lldb::user_id_t, lldb::CompUnitSP> m_compilands;
273  llvm::DenseMap<lldb::user_id_t, lldb::TypeSP> m_types;
274  llvm::DenseMap<lldb::user_id_t, std::shared_ptr<InlineSite>> m_inline_sites;
275 };
276 
277 } // namespace npdb
278 } // namespace lldb_private
279 
280 #endif // LLDB_SOURCE_PLUGINS_SYMBOLFILE_NATIVEPDB_SYMBOLFILENATIVEPDB_H
lldb_private::SymbolFile
Provides public interface for all SymbolFiles.
Definition: SymbolFile.h:45
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:1724
llvm
Definition: Debugger.h:50
lldb_private::npdb::SymbolFileNativePDB::GetFileIndex
llvm::Expected< uint32_t > GetFileIndex(const CompilandIndexItem &cii, uint32_t file_id)
Definition: SymbolFileNativePDB.cpp:1242
lldb_private::npdb::SymbolFileNativePDB::LineTableEntryComparator
Definition: SymbolFileNativePDB.h:165
lldb_private::RegularExpression
Definition: RegularExpression.h:18
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateTypedef
lldb::TypeSP GetOrCreateTypedef(PdbGlobalSymId id)
Definition: SymbolFileNativePDB.cpp:1752
lldb_private::npdb::SymbolFileNativePDB::GetDebugInfoSize
uint64_t GetDebugInfoSize() override
Metrics gathering functions.
Definition: SymbolFileNativePDB.cpp:1952
lldb_private::npdb::SymbolFileNativePDB::m_ast
std::unique_ptr< PdbAstBuilder > m_ast
Definition: SymbolFileNativePDB.h:266
lldb_private::npdb::SymbolFileNativePDB::CreateGlobalVariable
lldb::VariableSP CreateGlobalVariable(PdbGlobalSymId var_id)
Definition: SymbolFileNativePDB.cpp:762
lldb_private::npdb::SymbolFileNativePDB::Terminate
static void Terminate()
Definition: SymbolFileNativePDB.cpp:242
lldb_private::npdb::SymbolFileNativePDB::CreateFunctionType
lldb::TypeSP CreateFunctionType(PdbTypeSymId type_id, const llvm::codeview::MemberFunctionRecord &pr, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:622
lldb_private::npdb::SymbolFileNativePDB::CreateSimpleType
lldb::TypeSP CreateSimpleType(llvm::codeview::TypeIndex ti, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:503
lldb_private::npdb::SymbolFileNativePDB::ParseLineTable
bool ParseLineTable(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:1076
lldb_private::SourceLocationSpec
Definition: SourceLocationSpec.h:27
lldb_private::LineTable::Entry::file_addr
lldb::addr_t file_addr
The file address for this line entry.
Definition: LineTable.h:280
lldb_private::npdb::SymbolFileNativePDB::GetPluginDescriptionStatic
static llvm::StringRef GetPluginDescriptionStatic()
Definition: SymbolFileNativePDB.cpp:248
lldb_private::npdb::SymbolFileNativePDB
Definition: SymbolFileNativePDB.h:42
lldb_private::npdb::SymbolFileNativePDB::ParseTypes
size_t ParseTypes(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:1636
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:1600
lldb_private::npdb::SymbolFileNativePDB::LineTableEntryComparator::operator()
bool operator()(const lldb_private::LineTable::Entry &lhs, const lldb_private::LineTable::Entry &rhs) const
Definition: SymbolFileNativePDB.h:166
lldb_private::npdb::PdbCompilandSymId
Definition: PdbSymUid.h:44
lldb_private::npdb::SymbolFileNativePDB::m_index
std::unique_ptr< PdbIndex > m_index
Definition: SymbolFileNativePDB.h:264
lldb_private::npdb::SymbolFileNativePDB::ParseBlocksRecursive
size_t ParseBlocksRecursive(Function &func) override
Definition: SymbolFileNativePDB.cpp:1493
lldb_private::npdb::SymbolFileNativePDB::GetTypes
void GetTypes(SymbolContextScope *sc_scope, lldb::TypeClass type_mask, TypeList &type_list) override
Definition: SymbolFileNativePDB.cpp:1932
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateGlobalVariable
lldb::VariableSP GetOrCreateGlobalVariable(PdbGlobalSymId var_id)
Definition: SymbolFileNativePDB.cpp:873
lldb_private::npdb::SymbolFileNativePDB::CreateFunction
lldb::FunctionSP CreateFunction(PdbCompilandSymId func_id, CompileUnit &comp_unit)
Definition: SymbolFileNativePDB.cpp:400
lldb_private::npdb::SymbolFileNativePDB::CreateConstantSymbol
lldb::VariableSP CreateConstantSymbol(PdbGlobalSymId var_id, const llvm::codeview::CVSymbol &cvs)
Definition: SymbolFileNativePDB.cpp:843
lldb_private::npdb::SymbolFileNativePDB::InlineSite::InlineSite
InlineSite(PdbCompilandSymId parent_id)
Definition: SymbolFileNativePDB.h:181
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:748
CompileUnitIndex.h
lldb_private::npdb::SymbolFileNativePDB::m_obj_load_address
lldb::addr_t m_obj_load_address
Definition: SymbolFileNativePDB.h:260
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:1882
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:442
lldb_private::SymbolFileCommon
Containing protected virtual methods for child classes to override.
Definition: SymbolFile.h:374
lldb_private::npdb::SymbolFileNativePDB::GetTypeSystemForLanguage
llvm::Expected< TypeSystem & > GetTypeSystemForLanguage(lldb::LanguageType language) override
Definition: SymbolFileNativePDB.cpp:1943
lldb_private::SymbolContext
Definition: SymbolContext.h:33
lldb_private::npdb::SymbolFileNativePDB::ResolveTypeUID
Type * ResolveTypeUID(lldb::user_id_t type_uid) override
Definition: SymbolFileNativePDB.cpp:1897
lldb_private::npdb::SymbolFileNativePDB::CompleteType
bool CompleteType(CompilerType &compiler_type) override
Definition: SymbolFileNativePDB.cpp:1925
lldb_private::npdb::SymbolFileNativePDB::InlineSite::line_entries
std::vector< lldb_private::LineTable::Entry > line_entries
Definition: SymbolFileNativePDB.h:180
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:1283
lldb_private::npdb::SymbolFileNativePDB::GetDeclContextContainingUID
CompilerDeclContext GetDeclContextContainingUID(lldb::user_id_t uid) override
Definition: SymbolFileNativePDB.cpp:1892
lldb_private::CompileUnit
Definition: CompileUnit.h:38
lldb_private::npdb::SymbolFileNativePDB::CreateLocalVariable
lldb::VariableSP CreateLocalVariable(PdbCompilandSymId scope_id, PdbCompilandSymId var_id, bool is_param)
Definition: SymbolFileNativePDB.cpp:1687
lldb_private::Function
Definition: Function.h:409
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:1919
lldb_private::npdb::SymbolFileNativePDB::InlineSite::ranges
RangeSourceLineVector ranges
Definition: SymbolFileNativePDB.h:179
lldb_private::npdb::SymbolFileNativePDB::ParseSymbolArrayInScope
size_t ParseSymbolArrayInScope(PdbCompilandSymId parent, llvm::function_ref< bool(llvm::codeview::SymbolKind, PdbCompilandSymId)> fn)
Definition: SymbolFileNativePDB.cpp:1516
lldb_private::npdb::PdbGlobalSymId
Definition: PdbSymUid.h:57
lldb_private::npdb::SymbolFileNativePDB::m_inline_sites
llvm::DenseMap< lldb::user_id_t, std::shared_ptr< InlineSite > > m_inline_sites
Definition: SymbolFileNativePDB.h:274
lldb_private::npdb::SymbolFileNativePDB::GetPluginName
llvm::StringRef GetPluginName() override
Definition: SymbolFileNativePDB.h:157
lldb_private::npdb::SymbolFileNativePDB::CreateTypedef
lldb::TypeSP CreateTypedef(PdbGlobalSymId id)
Definition: SymbolFileNativePDB.cpp:1733
lldb_private::npdb::SymbolFileNativePDB::m_global_vars
llvm::DenseMap< lldb::user_id_t, lldb::VariableSP > m_global_vars
Definition: SymbolFileNativePDB.h:268
lldb_private::npdb::SymbolFileNativePDB::ParseVariablesForContext
size_t ParseVariablesForContext(const SymbolContext &sc) override
Definition: SymbolFileNativePDB.cpp:1843
lldb_private::npdb::SymbolFileNativePDB::classof
static bool classof(const SymbolFile *obj)
Definition: SymbolFileNativePDB.h:54
lldb_private::npdb::SymbolFileNativePDB::CreateClassStructUnion
lldb::TypeSP CreateClassStructUnion(PdbTypeSymId type_id, const llvm::codeview::TagRecord &record, size_t size, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:566
lldb_private::npdb::SymbolFileNativePDB::ParseLanguage
lldb::LanguageType ParseLanguage(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:938
lldb_private::npdb::SymbolFileNativePDB::InlineSite
Definition: SymbolFileNativePDB.h:176
lldb_private::npdb::SymbolFileNativePDB::m_functions
llvm::DenseMap< lldb::user_id_t, lldb::FunctionSP > m_functions
Definition: SymbolFileNativePDB.h:271
lldb_private::npdb::SymbolFileNativePDB::m_local_variables
llvm::DenseMap< lldb::user_id_t, lldb::VariableSP > m_local_variables
Definition: SymbolFileNativePDB.h:269
lldb_private::npdb::SymbolFileNativePDB::FindNamespace
CompilerDeclContext FindNamespace(ConstString name, const CompilerDeclContext &parent_decl_ctx) override
Definition: SymbolFileNativePDB.cpp:1937
lldb_private::npdb::SymbolFileNativePDB::m_types
llvm::DenseMap< lldb::user_id_t, lldb::TypeSP > m_types
Definition: SymbolFileNativePDB.h:273
lldb_private::npdb::SymbolFileNativePDB::ParseCompileUnitAtIndex
lldb::CompUnitSP ParseCompileUnitAtIndex(uint32_t index) override
Definition: SymbolFileNativePDB.cpp:926
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:484
lldb_private::npdb::SymbolFileNativePDB::DebuggerInitialize
static void DebuggerInitialize(Debugger &debugger)
Definition: SymbolFileNativePDB.cpp:246
lldb_private::npdb::PdbTypeSymId
Definition: PdbSymUid.h:70
lldb_private::npdb::SymbolFileNativePDB::ParseVariablesForBlock
size_t ParseVariablesForBlock(PdbCompilandSymId block_id)
Definition: SymbolFileNativePDB.cpp:1760
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:52
lldb_private::npdb::SymbolFileNativePDB::GetPDBFile
llvm::pdb::PDBFile & GetPDBFile()
Definition: SymbolFileNativePDB.h:159
lldb_private::npdb::SymbolFileNativePDB::FindTypesByName
void FindTypesByName(llvm::StringRef name, uint32_t max_matches, TypeMap &types)
Definition: SymbolFileNativePDB.cpp:1619
lldb_private::npdb::SymbolFileNativePDB::CreateModifierType
lldb::TypeSP CreateModifierType(PdbTypeSymId type_id, const llvm::codeview::ModifierRecord &mr, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:464
lldb_private::Debugger
Definition: Debugger.h:74
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateCompileUnit
lldb::CompUnitSP GetOrCreateCompileUnit(const CompilandIndexItem &cci)
Definition: SymbolFileNativePDB.cpp:899
lldb_private::TypeMap
Definition: TypeMap.h:20
lldb_private::npdb::SymbolFileNativePDB::ParseDeclsForContext
void ParseDeclsForContext(lldb_private::CompilerDeclContext decl_ctx) override
Definition: SymbolFileNativePDB.cpp:918
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:1533
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:954
lldb_private::npdb::CompilandIndexItem
Represents a single compile unit.
Definition: CompileUnitIndex.h:39
lldb_private::npdb::SymbolFileNativePDB::AddSymbols
void AddSymbols(Symtab &symtab) override
Definition: SymbolFileNativePDB.cpp:952
lldb_private::npdb::SymbolFileNativePDB::ID
static char ID
LLVM RTTI support.
Definition: SymbolFileNativePDB.h:46
lldb_private::npdb::SymbolFileNativePDB::RangeSourceLineVector
lldb_private::RangeDataVector< uint32_t, uint32_t, int32_t > RangeSourceLineVector
Definition: SymbolFileNativePDB.h:174
lldb_private::Block
Definition: Block.h:41
lldb_private::npdb::SymbolFileNativePDB::m_allocator
llvm::BumpPtrAllocator m_allocator
Definition: SymbolFileNativePDB.h:258
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::npdb::SymbolFileNativePDB::GetPluginNameStatic
static llvm::StringRef GetPluginNameStatic()
Definition: SymbolFileNativePDB.h:64
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:1265
lldb_private::npdb::SymbolFileNativePDB::ParseDebugMacros
bool ParseDebugMacros(lldb_private::CompileUnit &comp_unit) override
Definition: SymbolFileNativePDB.cpp:1236
lldb_private::npdb::SymbolFileNativePDB::m_file_up
std::unique_ptr< llvm::pdb::PDBFile > m_file_up
Definition: SymbolFileNativePDB.h:263
lldb_private::npdb::SymbolFileNativePDB::InitializeObject
void InitializeObject() override
Initialize the SymbolFile object.
Definition: SymbolFileNativePDB.cpp:299
lldb_private::RangeDataVector< uint32_t, uint32_t, int32_t >
lldb_private::npdb::SymbolFileNativePDB::InlineSite::parent_id
PdbCompilandSymId parent_id
Definition: SymbolFileNativePDB.h:177
lldb_private::Type
Definition: Type.h:66
LineTable.h
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:1535
lldb_private::npdb::SymbolFileNativePDB::CreateAndCacheType
lldb::TypeSP CreateAndCacheType(PdbTypeSymId type_id)
Definition: SymbolFileNativePDB.cpp:701
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:889
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::npdb::SymbolFileNativePDB::InlineSite::inline_function_info
std::shared_ptr< InlineFunctionInfo > inline_function_info
Definition: SymbolFileNativePDB.h:178
lldb_private::TypeList
Definition: TypeList.h:20
lldb_private::npdb::SymbolFileNativePDB::ParseVariablesForCompileUnit
size_t ParseVariablesForCompileUnit(CompileUnit &comp_unit, VariableList &variables)
Definition: SymbolFileNativePDB.cpp:1680
lldb_private::LanguageSet
A SmallBitVector that represents a set of source languages (lldb::LanguageType).
Definition: TypeSystem.h:40
lldb_private::npdb::SymbolFileNativePDB::ParseInlineSite
void ParseInlineSite(PdbCompilandSymId inline_site_id, Address func_addr)
Definition: SymbolFileNativePDB.cpp:1289
lldb_private::npdb::SymbolFileNativePDB::CreateProcedureType
lldb::TypeSP CreateProcedureType(PdbTypeSymId type_id, const llvm::codeview::ProcedureRecord &pr, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:632
lldb_private::npdb::SymbolFileNativePDB::CreateArrayType
lldb::TypeSP CreateArrayType(PdbTypeSymId type_id, const llvm::codeview::ArrayRecord &ar, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:607
lldb_private::npdb::SymbolFileNativePDB::GetDeclForUID
CompilerDecl GetDeclForUID(lldb::user_id_t uid) override
Definition: SymbolFileNativePDB.cpp:1874
lldb_private::SymbolFileCommon::isA
bool isA(const void *ClassID) const override
LLVM RTTI support.
Definition: SymbolFile.h:381
lldb_private::npdb::SymbolFileNativePDB::m_compilands
llvm::DenseMap< lldb::user_id_t, lldb::CompUnitSP > m_compilands
Definition: SymbolFileNativePDB.h:272
lldb_private::LineTable::Entry
Definition: LineTable.h:209
lldb_private::npdb::SymbolFileNativePDB::GetOrCreateBlock
Block & GetOrCreateBlock(PdbCompilandSymId block_id)
Definition: SymbolFileNativePDB.cpp:910
lldb_private::npdb::SymbolFileNativePDB::CreateType
lldb::TypeSP CreateType(PdbTypeSymId type_id, CompilerType ct)
Definition: SymbolFileNativePDB.cpp:642
lldb_private::npdb::SymbolFileNativePDB::m_blocks
llvm::DenseMap< lldb::user_id_t, lldb::BlockSP > m_blocks
Definition: SymbolFileNativePDB.h:270
lldb_private::npdb::SymbolFileNativePDB::m_done_full_type_scan
bool m_done_full_type_scan
Definition: SymbolFileNativePDB.h:261
SymbolFile.h
lldb_private::npdb::SymbolFileNativePDB::Initialize
static void Initialize()
Definition: SymbolFileNativePDB.cpp:236
lldb_private::npdb::SymbolFileNativePDB::GetPDBFile
const llvm::pdb::PDBFile & GetPDBFile() const
Definition: SymbolFileNativePDB.h:160
lldb_private::npdb::SymbolFileNativePDB::isA
bool isA(const void *ClassID) const override
LLVM RTTI support.
Definition: SymbolFileNativePDB.h:51
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