LLDB mainline
DWARFASTParserClang.h
Go to the documentation of this file.
1//===-- DWARFASTParserClang.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_DWARF_DWARFASTPARSERCLANG_H
10#define LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_DWARFASTPARSERCLANG_H
11
12#include "clang/AST/CharUnits.h"
13#include "clang/AST/Type.h"
14#include "llvm/ADT/DenseMap.h"
15#include "llvm/ADT/SmallPtrSet.h"
16#include "llvm/ADT/SmallVector.h"
17
18#include "DWARFASTParser.h"
19#include "DWARFDIE.h"
20#include "DWARFDefines.h"
21#include "DWARFFormValue.h"
22#include "LogChannelDWARF.h"
24
27
28#include <optional>
29#include <vector>
30
31namespace lldb_private {
32class CompileUnit;
33}
34namespace lldb_private::plugin {
35namespace dwarf {
36class DWARFDebugInfoEntry;
37class SymbolFileDWARF;
38} // namespace dwarf
39} // namespace lldb_private::plugin
40
42
44public:
46
48
49 // DWARFASTParser interface.
53 bool *type_is_new_ptr) override;
54
56 const lldb_private::plugin::dwarf::DWARFDIE &die) override;
57
61 const lldb_private::AddressRange &func_range) override;
62
63 bool
66 lldb_private::CompilerType &compiler_type) override;
67
69 const lldb_private::plugin::dwarf::DWARFDIE &die) override;
70
72 lldb_private::CompilerDeclContext decl_context) override;
73
75 const lldb_private::plugin::dwarf::DWARFDIE &die) override;
76
78 const lldb_private::plugin::dwarf::DWARFDIE &die) override;
79
81
82 /// Extracts an value for a given Clang integer type from a DWARFFormValue.
83 ///
84 /// \param int_type The Clang type that defines the bit size and signedness
85 /// of the integer that should be extracted. Has to be either
86 /// an integer type or an enum type. For enum types the
87 /// underlying integer type will be considered as the
88 /// expected integer type that should be extracted.
89 /// \param form_value The DWARFFormValue that contains the integer value.
90 /// \return An APInt containing the same integer value as the given
91 /// DWARFFormValue with the bit width of the given integer type.
92 /// Returns an error if the value in the DWARFFormValue does not fit
93 /// into the given integer type or the integer type isn't supported.
94 llvm::Expected<llvm::APInt> ExtractIntFromFormValue(
95 const lldb_private::CompilerType &int_type,
96 const lldb_private::plugin::dwarf::DWARFFormValue &form_value) const;
97
98 /// Returns the template parameters of a class DWARFDIE as a string.
99 ///
100 /// This is mostly useful for -gsimple-template-names which omits template
101 /// parameters from the DIE name and instead always adds template parameter
102 /// children DIEs.
103 ///
104 /// \param die The struct/class DWARFDIE containing template parameters.
105 /// \return A string, including surrounding '<>', of the template parameters.
106 /// If the DIE's name already has '<>', returns an empty ConstString because
107 /// it's assumed that the caller is using the DIE name anyway.
109 const lldb_private::plugin::dwarf::DWARFDIE &die) override;
110
111protected:
112 /// Protected typedefs and members.
113 /// @{
115 typedef std::vector<DelayedAddObjCClassProperty> DelayedPropertyList;
116
117 typedef llvm::DenseMap<
119 clang::DeclContext *>
121 typedef std::multimap<const clang::DeclContext *,
124 typedef llvm::DenseMap<
128 typedef llvm::DenseMap<
131
137 std::unique_ptr<lldb_private::ClangASTImporter> m_clang_ast_importer_up;
138 /// @}
139
140 clang::DeclContext *
142
143 clang::BlockDecl *
145
146 clang::NamespaceDecl *
148
149 /// Returns the namespace decl that a DW_TAG_imported_declaration imports.
150 ///
151 /// \param[in] die The import declaration to resolve. If the DIE is not a
152 /// DW_TAG_imported_declaration the behaviour is undefined.
153 ///
154 /// \returns The decl corresponding to the namespace that the specified
155 /// 'die' imports. If the imported entity is not a namespace
156 /// or another import declaration, returns nullptr. If an error
157 /// occurs, returns nullptr.
158 clang::NamespaceDecl *ResolveImportedDeclarationDIE(
160
163 &template_param_infos);
164
168 &template_param_infos);
169
170 std::string
172
175 lldb_private::CompilerType &class_compiler_type,
176 std::vector<std::unique_ptr<clang::CXXBaseSpecifier>> &base_classes,
177 std::vector<lldb_private::plugin::dwarf::DWARFDIE> &member_function_dies,
178 DelayedPropertyList &delayed_properties,
179 const lldb::AccessType default_accessibility,
181
182 size_t
183 ParseChildParameters(clang::DeclContext *containing_decl_ctx,
185 bool skip_artificial, bool &is_static, bool &is_variadic,
186 bool &has_template_params,
187 std::vector<lldb_private::CompilerType> &function_args,
188 std::vector<clang::ParmVarDecl *> &function_param_decls,
189 unsigned &type_quals);
190
192 lldb_private::CompilerType &compiler_type, bool is_signed,
193 uint32_t enumerator_byte_size,
194 const lldb_private::plugin::dwarf::DWARFDIE &parent_die);
195
196 /// Parse a structure, class, or union type DIE.
201
202 clang::Decl *
204
205 clang::DeclContext *
207
208 clang::DeclContext *GetClangDeclContextContainingDIE(
213
215 const lldb_private::plugin::dwarf::DWARFDIE &src_class_die,
216 const lldb_private::plugin::dwarf::DWARFDIE &dst_class_die,
217 lldb_private::Type *class_type,
218 std::vector<lldb_private::plugin::dwarf::DWARFDIE> &failures);
219
220 clang::DeclContext *GetCachedClangDeclContextForDIE(
222
223 void LinkDeclContextToDIE(clang::DeclContext *decl_ctx,
225
226 void LinkDeclToDIE(clang::Decl *decl,
228
229 /// If \p type_sp is valid, calculate and set its symbol context scope, and
230 /// update the type list for its backing symbol file.
231 ///
232 /// Returns \p type_sp.
236
237 /// Follow Clang Module Skeleton CU references to find a type definition.
241 lldb_private::Log *log);
242
243 // Return true if this type is a declaration to a type in an external
244 // module.
247
248 static bool classof(const DWARFASTParser *Parser) {
249 return Parser->GetKind() == Kind::DWARFASTParserClang;
250 }
251
252private:
253 struct FieldInfo {
254 uint64_t bit_size = 0;
255 uint64_t bit_offset = 0;
256 bool is_bitfield = false;
257 bool is_artificial = false;
258
259 FieldInfo() = default;
260
261 void SetIsBitfield(bool flag) { is_bitfield = flag; }
262 bool IsBitfield() { return is_bitfield; }
263
264 void SetIsArtificial(bool flag) { is_artificial = flag; }
265 bool IsArtificial() const { return is_artificial; }
266
267 bool NextBitfieldOffsetIsValid(const uint64_t next_bit_offset) const {
268 // Any subsequent bitfields must not overlap and must be at a higher
269 // bit offset than any previous bitfield + size.
270 return (bit_size + bit_offset) <= next_bit_offset;
271 }
272 };
273
274 /// Parsed form of all attributes that are relevant for parsing type members.
276 explicit MemberAttributes(
279 lldb::ModuleSP module_sp);
280 const char *name = nullptr;
281 /// Indicates how many bits into the word (according to the host endianness)
282 /// the low-order bit of the field starts. Can be negative.
283 int64_t bit_offset = 0;
284 /// Indicates the size of the field in bits.
285 size_t bit_size = 0;
288 std::optional<uint64_t> byte_size;
289 std::optional<lldb_private::plugin::dwarf::DWARFFormValue> const_value_form;
291 /// Indicates the byte offset of the word from the base address of the
292 /// structure.
294 bool is_artificial = false;
295 bool is_declaration = false;
296 };
297
298 /// Returns 'true' if we should create an unnamed bitfield
299 /// and add it to the parser's current AST.
300 ///
301 /// \param[in] last_field_info FieldInfo of the previous DW_TAG_member
302 /// we parsed.
303 /// \param[in] last_field_end Offset (in bits) where the last parsed field
304 /// ended.
305 /// \param[in] this_field_info FieldInfo of the current DW_TAG_member
306 /// being parsed.
307 /// \param[in] layout_info Layout information of all decls parsed by the
308 /// current parser.
310 FieldInfo const &last_field_info, uint64_t last_field_end,
311 FieldInfo const &this_field_info,
312 lldb_private::ClangASTImporter::LayoutInfo const &layout_info) const;
313
314 /// Parses a DW_TAG_APPLE_property DIE and appends the parsed data to the
315 /// list of delayed Objective-C properties.
316 ///
317 /// Note: The delayed property needs to be finalized to actually create the
318 /// property declarations in the module AST.
319 ///
320 /// \param die The DW_TAG_APPLE_property DIE that will be parsed.
321 /// \param parent_die The parent DIE.
322 /// \param class_clang_type The Objective-C class that will contain the
323 /// created property.
324 /// \param delayed_properties The list of delayed properties that the result
325 /// will be appended to.
326 void
329 const lldb_private::CompilerType &class_clang_type,
330 DelayedPropertyList &delayed_properties);
331
332 void
335 const lldb_private::CompilerType &class_clang_type,
336 lldb::AccessType default_accessibility,
338 FieldInfo &last_field_info);
339
340 /// If the specified 'die' represents a static data member, creates
341 /// a 'clang::VarDecl' for it and attaches it to specified parent
342 /// 'class_clang_type'.
343 ///
344 /// \param[in] die The member declaration we want to create a
345 /// clang::VarDecl for.
346 ///
347 /// \param[in] attrs The parsed attributes for the specified 'die'.
348 ///
349 /// \param[in] class_clang_type The parent RecordType of the static
350 /// member this function will create.
353 const MemberAttributes &attrs,
354 const lldb_private::CompilerType &class_clang_type);
355
357 lldb_private::Type *type,
358 lldb_private::CompilerType &clang_type);
360 lldb_private::Type *type,
361 lldb_private::CompilerType &clang_type);
362
371 const ParsedDWARFTypeAttributes &attrs);
373 const ParsedDWARFTypeAttributes &attrs);
376 const ParsedDWARFTypeAttributes &attrs);
377
378 /// Parses a DW_TAG_inheritance DIE into a base/super class.
379 ///
380 /// \param die The DW_TAG_inheritance DIE to parse.
381 /// \param parent_die The parent DIE of the given DIE.
382 /// \param class_clang_type The C++/Objective-C class representing parent_die.
383 /// For an Objective-C class this method sets the super class on success. For
384 /// a C++ class this will *not* add the result as a base class.
385 /// \param default_accessibility The default accessibility that is given to
386 /// base classes if they don't have an explicit accessibility set.
387 /// \param module_sp The current Module.
388 /// \param base_classes The list of C++ base classes that will be appended
389 /// with the parsed base class on success.
390 /// \param layout_info The layout information that will be updated for C++
391 /// base classes with the base offset.
392 void ParseInheritance(
395 const lldb_private::CompilerType class_clang_type,
396 const lldb::AccessType default_accessibility,
397 const lldb::ModuleSP &module_sp,
398 std::vector<std::unique_ptr<clang::CXXBaseSpecifier>> &base_classes,
400
401 /// Parses DW_TAG_variant_part DIE into a structure that encodes all variants
402 /// Note that this is currently being emitted by rustc and not Clang
403 /// \param die DW_TAG_variant_part DIE to parse
404 /// \param parent_die The parent DW_TAG_structure_type to parse
405 /// \param class_clang_type The Rust struct representing parent_die.
406 /// \param default_accesibility The default accessibility that is given to
407 /// base classes if they don't have an explicit accessibility set
408 /// \param layout_info The layout information that will be updated for
409 // base classes with the base offset
410 void
413 lldb_private::CompilerType &class_clang_type,
414 const lldb::AccessType default_accesibility,
416
417 /// Tries to find the definition DW_TAG_variable DIE of the the specified
418 /// DW_TAG_member 'die'. If such definition exists, returns the
419 /// DW_AT_const_value of that definition if available. Returns std::nullopt
420 /// otherwise.
421 ///
422 /// In newer versions of clang, DW_AT_const_value attributes are not attached
423 /// to the declaration of a inline static data-member anymore, but rather on
424 /// its definition. This function is used to locate said constant.
425 std::optional<lldb_private::plugin::dwarf::DWARFFormValue>
427};
428
429/// Parsed form of all attributes that are relevant for type reconstruction.
430/// Some attributes are relevant for all kinds of types (declaration), while
431/// others are only meaningful to a specific type (is_virtual)
435
437 bool is_artificial = false;
439 bool is_explicit = false;
441 bool is_inline = false;
442 bool is_scoped_enum = false;
443 bool is_vector = false;
444 bool is_virtual = false;
446 bool exports_symbols = false;
447 clang::StorageClass storage = clang::SC_None;
448 const char *mangled_name = nullptr;
458 std::optional<uint64_t> byte_size;
459 std::optional<uint64_t> alignment;
460 size_t calling_convention = llvm::dwarf::DW_CC_normal;
461 uint32_t bit_stride = 0;
462 uint32_t byte_stride = 0;
463 uint32_t encoding = 0;
464 clang::RefQualifierKind ref_qual =
465 clang::RQ_None; ///< Indicates ref-qualifier of
466 ///< C++ member function if present.
467 ///< Is RQ_None otherwise.
468};
469
470#endif // LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_DWARFASTPARSERCLANG_H
lldb::TypeSP ParsePointerToMemberType(const lldb_private::plugin::dwarf::DWARFDIE &die, const ParsedDWARFTypeAttributes &attrs)
clang::NamespaceDecl * ResolveImportedDeclarationDIE(const lldb_private::plugin::dwarf::DWARFDIE &die)
Returns the namespace decl that a DW_TAG_imported_declaration imports.
void CreateStaticMemberVariable(const lldb_private::plugin::dwarf::DWARFDIE &die, const MemberAttributes &attrs, const lldb_private::CompilerType &class_clang_type)
If the specified 'die' represents a static data member, creates a 'clang::VarDecl' for it and attache...
size_t ParseChildParameters(clang::DeclContext *containing_decl_ctx, const lldb_private::plugin::dwarf::DWARFDIE &parent_die, bool skip_artificial, bool &is_static, bool &is_variadic, bool &has_template_params, std::vector< lldb_private::CompilerType > &function_args, std::vector< clang::ParmVarDecl * > &function_param_decls, unsigned &type_quals)
std::unique_ptr< lldb_private::ClangASTImporter > m_clang_ast_importer_up
lldb::TypeSP ParseEnum(const lldb_private::SymbolContext &sc, const lldb_private::plugin::dwarf::DWARFDIE &die, ParsedDWARFTypeAttributes &attrs)
static bool classof(const DWARFASTParser *Parser)
llvm::DenseMap< const lldb_private::plugin::dwarf::DWARFDebugInfoEntry *, clang::Decl * > DIEToDeclMap
lldb::TypeSP UpdateSymbolContextScopeForType(const lldb_private::SymbolContext &sc, const lldb_private::plugin::dwarf::DWARFDIE &die, lldb::TypeSP type_sp)
If type_sp is valid, calculate and set its symbol context scope, and update the type list for its bac...
lldb_private::TypeSystemClang & m_ast
bool ShouldCreateUnnamedBitfield(FieldInfo const &last_field_info, uint64_t last_field_end, FieldInfo const &this_field_info, lldb_private::ClangASTImporter::LayoutInfo const &layout_info) const
Returns 'true' if we should create an unnamed bitfield and add it to the parser's current AST.
lldb::TypeSP ParseArrayType(const lldb_private::plugin::dwarf::DWARFDIE &die, const ParsedDWARFTypeAttributes &attrs)
lldb_private::ClangASTImporter & GetClangASTImporter()
clang::BlockDecl * ResolveBlockDIE(const lldb_private::plugin::dwarf::DWARFDIE &die)
lldb::TypeSP ParseTypeFromDWARF(const lldb_private::SymbolContext &sc, const lldb_private::plugin::dwarf::DWARFDIE &die, bool *type_is_new_ptr) override
bool CompleteEnumType(const lldb_private::plugin::dwarf::DWARFDIE &die, lldb_private::Type *type, lldb_private::CompilerType &clang_type)
bool CompleteTypeFromDWARF(const lldb_private::plugin::dwarf::DWARFDIE &die, lldb_private::Type *type, lldb_private::CompilerType &compiler_type) override
clang::DeclContext * GetClangDeclContextContainingDIE(const lldb_private::plugin::dwarf::DWARFDIE &die, lldb_private::plugin::dwarf::DWARFDIE *decl_ctx_die)
clang::DeclContext * GetDeclContextForBlock(const lldb_private::plugin::dwarf::DWARFDIE &die)
void ParseInheritance(const lldb_private::plugin::dwarf::DWARFDIE &die, const lldb_private::plugin::dwarf::DWARFDIE &parent_die, const lldb_private::CompilerType class_clang_type, const lldb::AccessType default_accessibility, const lldb::ModuleSP &module_sp, std::vector< std::unique_ptr< clang::CXXBaseSpecifier > > &base_classes, lldb_private::ClangASTImporter::LayoutInfo &layout_info)
Parses a DW_TAG_inheritance DIE into a base/super class.
lldb_private::Function * ParseFunctionFromDWARF(lldb_private::CompileUnit &comp_unit, const lldb_private::plugin::dwarf::DWARFDIE &die, const lldb_private::AddressRange &func_range) override
std::optional< lldb_private::plugin::dwarf::DWARFFormValue > FindConstantOnVariableDefinition(lldb_private::plugin::dwarf::DWARFDIE die)
Tries to find the definition DW_TAG_variable DIE of the the specified DW_TAG_member 'die'.
std::multimap< const clang::DeclContext *, const lldb_private::plugin::dwarf::DWARFDIE > DeclContextToDIEMap
lldb::TypeSP ParseTypeModifier(const lldb_private::SymbolContext &sc, const lldb_private::plugin::dwarf::DWARFDIE &die, ParsedDWARFTypeAttributes &attrs)
lldb::TypeSP ParseTypeFromClangModule(const lldb_private::SymbolContext &sc, const lldb_private::plugin::dwarf::DWARFDIE &die, lldb_private::Log *log)
Follow Clang Module Skeleton CU references to find a type definition.
DIEToDeclContextMap m_die_to_decl_ctx
void ParseObjCProperty(const lldb_private::plugin::dwarf::DWARFDIE &die, const lldb_private::plugin::dwarf::DWARFDIE &parent_die, const lldb_private::CompilerType &class_clang_type, DelayedPropertyList &delayed_properties)
Parses a DW_TAG_APPLE_property DIE and appends the parsed data to the list of delayed Objective-C pro...
void EnsureAllDIEsInDeclContextHaveBeenParsed(lldb_private::CompilerDeclContext decl_context) override
clang::NamespaceDecl * ResolveNamespaceDIE(const lldb_private::plugin::dwarf::DWARFDIE &die)
lldb_private::ConstString GetDIEClassTemplateParams(const lldb_private::plugin::dwarf::DWARFDIE &die) override
Returns the template parameters of a class DWARFDIE as a string.
lldb_private::ConstString ConstructDemangledNameFromDWARF(const lldb_private::plugin::dwarf::DWARFDIE &die) override
lldb_private::CompilerDeclContext GetDeclContextContainingUIDFromDWARF(const lldb_private::plugin::dwarf::DWARFDIE &die) override
lldb::TypeSP ParseStructureLikeDIE(const lldb_private::SymbolContext &sc, const lldb_private::plugin::dwarf::DWARFDIE &die, ParsedDWARFTypeAttributes &attrs)
Parse a structure, class, or union type DIE.
void ParseRustVariantPart(lldb_private::plugin::dwarf::DWARFDIE &die, const lldb_private::plugin::dwarf::DWARFDIE &parent_die, lldb_private::CompilerType &class_clang_type, const lldb::AccessType default_accesibility, lldb_private::ClangASTImporter::LayoutInfo &layout_info)
Parses DW_TAG_variant_part DIE into a structure that encodes all variants Note that this is currently...
~DWARFASTParserClang() override
std::vector< DelayedAddObjCClassProperty > DelayedPropertyList
std::string GetCPlusPlusQualifiedName(const lldb_private::plugin::dwarf::DWARFDIE &die)
lldb::ModuleSP GetModuleForType(const lldb_private::plugin::dwarf::DWARFDIE &die)
bool CopyUniqueClassMethodTypes(const lldb_private::plugin::dwarf::DWARFDIE &src_class_die, const lldb_private::plugin::dwarf::DWARFDIE &dst_class_die, lldb_private::Type *class_type, std::vector< lldb_private::plugin::dwarf::DWARFDIE > &failures)
clang::DeclContext * GetClangDeclContextForDIE(const lldb_private::plugin::dwarf::DWARFDIE &die)
bool ParseTemplateDIE(const lldb_private::plugin::dwarf::DWARFDIE &die, lldb_private::TypeSystemClang::TemplateParameterInfos &template_param_infos)
lldb_private::CompilerDeclContext GetDeclContextForUIDFromDWARF(const lldb_private::plugin::dwarf::DWARFDIE &die) override
llvm::Expected< llvm::APInt > ExtractIntFromFormValue(const lldb_private::CompilerType &int_type, const lldb_private::plugin::dwarf::DWARFFormValue &form_value) const
Extracts an value for a given Clang integer type from a DWARFFormValue.
bool CompleteRecordType(const lldb_private::plugin::dwarf::DWARFDIE &die, lldb_private::Type *type, lldb_private::CompilerType &clang_type)
clang::DeclContext * GetCachedClangDeclContextForDIE(const lldb_private::plugin::dwarf::DWARFDIE &die)
DIEToModuleMap m_die_to_module
void ParseSingleMember(const lldb_private::plugin::dwarf::DWARFDIE &die, const lldb_private::plugin::dwarf::DWARFDIE &parent_die, const lldb_private::CompilerType &class_clang_type, lldb::AccessType default_accessibility, lldb_private::ClangASTImporter::LayoutInfo &layout_info, FieldInfo &last_field_info)
DeclContextToDIEMap m_decl_ctx_to_die
bool ParseChildMembers(const lldb_private::plugin::dwarf::DWARFDIE &die, lldb_private::CompilerType &class_compiler_type, std::vector< std::unique_ptr< clang::CXXBaseSpecifier > > &base_classes, std::vector< lldb_private::plugin::dwarf::DWARFDIE > &member_function_dies, DelayedPropertyList &delayed_properties, const lldb::AccessType default_accessibility, lldb_private::ClangASTImporter::LayoutInfo &layout_info)
size_t ParseChildEnumerators(lldb_private::CompilerType &compiler_type, bool is_signed, uint32_t enumerator_byte_size, const lldb_private::plugin::dwarf::DWARFDIE &parent_die)
llvm::DenseMap< const lldb_private::plugin::dwarf::DWARFDebugInfoEntry *, clang::DeclContext * > DIEToDeclContextMap
lldb::TypeSP ParseSubroutine(const lldb_private::plugin::dwarf::DWARFDIE &die, const ParsedDWARFTypeAttributes &attrs)
lldb_private::CompilerDecl GetDeclForUIDFromDWARF(const lldb_private::plugin::dwarf::DWARFDIE &die) override
llvm::DenseMap< const lldb_private::plugin::dwarf::DWARFDebugInfoEntry *, lldb_private::OptionalClangModuleID > DIEToModuleMap
bool ParseTemplateParameterInfos(const lldb_private::plugin::dwarf::DWARFDIE &parent_die, lldb_private::TypeSystemClang::TemplateParameterInfos &template_param_infos)
clang::Decl * GetClangDeclForDIE(const lldb_private::plugin::dwarf::DWARFDIE &die)
void LinkDeclToDIE(clang::Decl *decl, const lldb_private::plugin::dwarf::DWARFDIE &die)
void LinkDeclContextToDIE(clang::DeclContext *decl_ctx, const lldb_private::plugin::dwarf::DWARFDIE &die)
lldb_private::OptionalClangModuleID GetOwningClangModule(const lldb_private::plugin::dwarf::DWARFDIE &die)
A section + offset based address range class.
Definition: AddressRange.h:25
Manages and observes all Clang AST node importing in LLDB.
A class that describes a compilation unit.
Definition: CompileUnit.h:41
Represents a generic declaration context in a program.
Represents a generic declaration such as a function declaration.
Definition: CompilerDecl.h:28
Generic representation of a type in a programming language.
Definition: CompilerType.h:36
A uniqued constant string class.
Definition: ConstString.h:40
A class that describes the declaration location of a lldb object.
Definition: Declaration.h:24
A class that describes a function.
Definition: Function.h:399
Defines a symbol context baton that can be handed other debug core functions.
Definition: SymbolContext.h:33
A TypeSystem implementation based on Clang.
DWARFDebugInfoEntry objects assume that they are living in one big vector and do pointer arithmetic o...
#define UINT64_MAX
Definition: lldb-defines.h:23
#define UINT32_MAX
Definition: lldb-defines.h:19
A class that represents a running process on the host machine.
Definition: SBAttachInfo.h:14
LanguageType
Programming language type.
@ eLanguageTypeUnknown
Unknown or invalid language value.
std::shared_ptr< lldb_private::Type > TypeSP
Definition: lldb-forward.h:445
std::shared_ptr< lldb_private::Module > ModuleSP
Definition: lldb-forward.h:361
bool NextBitfieldOffsetIsValid(const uint64_t next_bit_offset) const
Parsed form of all attributes that are relevant for parsing type members.
int64_t bit_offset
Indicates how many bits into the word (according to the host endianness) the low-order bit of the fie...
uint32_t member_byte_offset
Indicates the byte offset of the word from the base address of the structure.
lldb_private::plugin::dwarf::DWARFFormValue encoding_form
size_t bit_size
Indicates the size of the field in bits.
std::optional< lldb_private::plugin::dwarf::DWARFFormValue > const_value_form
Parsed form of all attributes that are relevant for type reconstruction.
lldb_private::Declaration decl
lldb_private::ConstString name
std::optional< uint64_t > alignment
lldb::LanguageType class_language
std::optional< uint64_t > byte_size
lldb_private::plugin::dwarf::DWARFFormValue signature
lldb_private::plugin::dwarf::DWARFFormValue type
lldb_private::plugin::dwarf::DWARFDIE object_pointer
clang::RefQualifierKind ref_qual
Indicates ref-qualifier of C++ member function if present.
lldb_private::plugin::dwarf::DWARFFormValue specification
lldb_private::plugin::dwarf::DWARFFormValue abstract_origin
lldb_private::plugin::dwarf::DWARFFormValue containing_type