LLDB mainline
DWARFASTParser.h
Go to the documentation of this file.
1//===-- DWARFASTParser.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_DWARFASTPARSER_H
10#define LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_DWARFASTPARSER_H
11
12#include "DWARFDefines.h"
18#include "llvm/Support/ExtensibleRTTI.h"
19#include <optional>
20
21namespace lldb_private {
22class CompileUnit;
24}
25
26namespace lldb_private::plugin {
27namespace dwarf {
28class DWARFDIE;
29class SymbolFileDWARF;
30
32 : public llvm::RTTIExtends<DWARFASTParser, llvm::RTTIRoot> {
33public:
34 /// LLVM RTTI support
35 static char ID;
36
37 virtual ~DWARFASTParser() = default;
38
40 const DWARFDIE &die,
41 bool *type_is_new_ptr) = 0;
42
44
46 const DWARFDIE &die,
47 AddressRanges ranges) = 0;
48
49 virtual bool CompleteTypeFromDWARF(const DWARFDIE &die, Type *type,
50 const CompilerType &compiler_type) = 0;
51
53
56
59
61 CompilerDeclContext decl_context) = 0;
62
63 virtual std::string GetDIEClassTemplateParams(DWARFDIE die) = 0;
64
65 static std::optional<SymbolFile::ArrayInfo>
66 ParseChildArrayInfo(const DWARFDIE &parent_die,
67 const ExecutionContext *exe_ctx = nullptr);
68
70
71 static lldb::AccessType GetAccessTypeFromDWARF(uint32_t dwarf_accessibility);
72
73 static DWARFDIE GetAnnotation(const DWARFDIE &die, llvm::StringRef name);
74};
75} // namespace dwarf
76} // namespace lldb_private::plugin
77
78#endif // LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_DWARFASTPARSER_H
A class that describes a compilation unit.
Definition CompileUnit.h:43
Represents a generic declaration context in a program.
Represents a generic declaration such as a function declaration.
Generic representation of a type in a programming language.
A uniqued constant string class.
Definition ConstString.h:40
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
A class that describes a function.
Definition Function.h:386
Defines a symbol context baton that can be handed other debug core functions.
virtual void EnsureAllDIEsInDeclContextHaveBeenParsed(CompilerDeclContext decl_context)=0
virtual bool CompleteTypeFromDWARF(const DWARFDIE &die, Type *type, const CompilerType &compiler_type)=0
lldb_private::Type * GetTypeForDIE(const DWARFDIE &die)
virtual std::string GetDIEClassTemplateParams(DWARFDIE die)=0
virtual CompilerDecl GetDeclForUIDFromDWARF(const DWARFDIE &die)=0
virtual Function * ParseFunctionFromDWARF(CompileUnit &comp_unit, const DWARFDIE &die, AddressRanges ranges)=0
virtual ConstString ConstructDemangledNameFromDWARF(const DWARFDIE &die)=0
static lldb::AccessType GetAccessTypeFromDWARF(uint32_t dwarf_accessibility)
virtual lldb::TypeSP ParseTypeFromDWARF(const SymbolContext &sc, const DWARFDIE &die, bool *type_is_new_ptr)=0
virtual CompilerDeclContext GetDeclContextContainingUIDFromDWARF(const DWARFDIE &die)=0
static std::optional< SymbolFile::ArrayInfo > ParseChildArrayInfo(const DWARFDIE &parent_die, const ExecutionContext *exe_ctx=nullptr)
static DWARFDIE GetAnnotation(const DWARFDIE &die, llvm::StringRef name)
virtual CompilerDeclContext GetDeclContextForUIDFromDWARF(const DWARFDIE &die)=0
A class that represents a running process on the host machine.
std::shared_ptr< lldb_private::Type > TypeSP