15#ifndef LIEF_DWARF_INFO_H
16#define LIEF_DWARF_INFO_H
40 static std::unique_ptr<DebugInfo>
from_file(
const std::string& path);
69 std::unique_ptr<Type>
find_type(
const std::string& name)
const;
90inline std::unique_ptr<DebugInfo>
load(
const std::string& dwarf_path) {
This class provides a generic interface for accessing debug information from different formats such a...
Definition Abstract/DebugInfo.hpp:38
DebugInfo(std::unique_ptr< details::DebugInfo > impl)
FORMAT
Definition Abstract/DebugInfo.hpp:41
@ DWARF
Definition Abstract/DebugInfo.hpp:43
DebugInfo(std::unique_ptr< details::DebugInfo > impl)
optional< uint64_t > find_function_address(const std::string &name) const override
Attempt to resolve the address of the function specified by name.
static std::unique_ptr< DebugInfo > from_file(const std::string &path)
compilation_units_it compilation_units() const
Iterator on the CompilationUnit embedded in this dwarf.
FORMAT format() const override
Definition DWARF/DebugInfo.hpp:77
std::unique_ptr< Type > find_type(const std::string &name) const
Try to find the type with the given name.
std::unique_ptr< Function > find_function(uint64_t addr) const
Try to find the function at the given virtual address.
std::unique_ptr< Function > find_function(const std::string &name) const
Try to find the function with the given name (mangled or not).
iterator_range< CompilationUnit::Iterator > compilation_units_it
Iterator over the CompilationUnit.
Definition DWARF/DebugInfo.hpp:43
static bool classof(const LIEF::DebugInfo *info)
Definition DWARF/DebugInfo.hpp:81
std::unique_ptr< Variable > find_variable(const std::string &name) const
Try to find the variable with the given name. This name can be mangled or not.
std::unique_ptr< Variable > find_variable(uint64_t addr) const
Try to find the variable at the given virtual address.
~DebugInfo() override=default
This class represents a DWARF function which can be associated with either: DW_TAG_subprogram or DW_T...
Definition DWARF/Function.hpp:42
This class represents a DWARF variable which can be owned by a dwarf::Function or a dwarf::Compilatio...
Definition Variable.hpp:36
Definition iterators.hpp:486
Definition optional.hpp:23
Namespace for the DWARF debug format.
Definition DWARF/CompilationUnit.hpp:28
std::unique_ptr< DebugInfo > load(const std::string &dwarf_path)
Load DWARF file from the given path.
Definition DWARF/DebugInfo.hpp:90
LIEF namespace.
Definition Abstract/Binary.hpp:40
#define LIEF_API
Definition visibility.h:41