LLVM
8.0.1
|
Base class describing the header of any kind of "unit." Some information is specific to certain unit types. More...
#include "llvm/DebugInfo/DWARF/DWARFUnit.h"
Public Member Functions | |
bool | extract (DWARFContext &Context, const DWARFDataExtractor &debug_info, uint32_t *offset_ptr, DWARFSectionKind Kind=DW_SECT_INFO, const DWARFUnitIndex *Index=nullptr, const DWARFUnitIndex::Entry *Entry=nullptr) |
Parse a unit header from debug_info starting at offset_ptr . More... | |
uint32_t | getOffset () const |
const dwarf::FormParams & | getFormParams () const |
uint16_t | getVersion () const |
dwarf::DwarfFormat | getFormat () const |
uint8_t | getAddressByteSize () const |
uint8_t | getRefAddrByteSize () const |
uint8_t | getDwarfOffsetByteSize () const |
uint32_t | getLength () const |
uint64_t | getAbbrOffset () const |
Optional< uint64_t > | getDWOId () const |
void | setDWOId (uint64_t Id) |
const DWARFUnitIndex::Entry * | getIndexEntry () const |
uint64_t | getTypeHash () const |
uint32_t | getTypeOffset () const |
uint8_t | getUnitType () const |
bool | isTypeUnit () const |
uint8_t | getSize () const |
uint32_t | getNextUnitOffset () const |
Base class describing the header of any kind of "unit." Some information is specific to certain unit types.
We separate this class out so we can parse the header before deciding what specific kind of unit to construct.
Definition at line 47 of file DWARFUnit.h.
bool DWARFUnitHeader::extract | ( | DWARFContext & | Context, |
const DWARFDataExtractor & | debug_info, | ||
uint32_t * | offset_ptr, | ||
DWARFSectionKind | Kind = DW_SECT_INFO , |
||
const DWARFUnitIndex * | Index = nullptr , |
||
const DWARFUnitIndex::Entry * | Entry = nullptr |
||
) |
Parse a unit header from debug_info
starting at offset_ptr
.
Definition at line 235 of file DWARFUnit.cpp.
References llvm::dwarf::FormParams::AddrSize, assert(), llvm::DW_SECT_ABBREV, llvm::DW_SECT_TYPES, llvm::dwarf::DWARF32, llvm::dwarf::FormParams::Format, llvm::DWARFUnit::getAddressByteSize(), llvm::DWARFUnitIndex::getFromOffset(), llvm::DWARFUnit::getLength(), llvm::DWARFUnit::getNextUnitOffset(), llvm::DWARFDataExtractor::getRelocatedValue(), llvm::DataExtractor::getU16(), llvm::DataExtractor::getU32(), llvm::DataExtractor::getU64(), llvm::DataExtractor::getU8(), llvm::DWARFUnit::getVersion(), llvm::DWARFContext::isSupportedVersion(), llvm::DWARFUnit::isTypeUnit(), llvm::DataExtractor::isValidOffset(), llvm::DWARFContext::setMaxVersionIfGreater(), Size, true, and llvm::dwarf::FormParams::Version.
Referenced by llvm::DWARFUnitVector::addUnitsForDWOSection(), and llvm::DWARFVerifier::handleDebugAbbrev().
|
inline |
Definition at line 87 of file DWARFUnit.h.
Referenced by llvm::DWARFUnit::getAbbreviations().
|
inline |
Definition at line 81 of file DWARFUnit.h.
References llvm::dwarf::FormParams::AddrSize.
Referenced by llvm::DWARFUnit::getAddressByteSize().
|
inline |
Definition at line 83 of file DWARFUnit.h.
References llvm::dwarf::FormParams::getDwarfOffsetByteSize().
Referenced by llvm::DWARFUnit::getDwarfOffsetByteSize().
|
inline |
Definition at line 88 of file DWARFUnit.h.
|
inline |
Definition at line 80 of file DWARFUnit.h.
References llvm::dwarf::FormParams::Format.
|
inline |
Definition at line 78 of file DWARFUnit.h.
Referenced by llvm::DWARFUnit::getFormParams().
|
inline |
Definition at line 93 of file DWARFUnit.h.
Referenced by llvm::DWARFUnit::determineStringOffsetsTableContributionDWO(), llvm::DWARFUnit::DWARFUnit(), and llvm::DWARFUnit::getLineTableOffset().
|
inline |
Definition at line 86 of file DWARFUnit.h.
Referenced by llvm::DWARFUnit::dies(), and llvm::DWARFUnit::getLength().
|
inline |
Definition at line 102 of file DWARFUnit.h.
References Context, llvm::getDWARFUnitIndex(), and Kind.
Referenced by llvm::DWARFUnit::getNextUnitOffset().
|
inline |
Definition at line 77 of file DWARFUnit.h.
Referenced by llvm::DWARFUnit::getOffset().
|
inline |
Definition at line 82 of file DWARFUnit.h.
References llvm::dwarf::FormParams::getRefAddrByteSize().
Referenced by llvm::DWARFUnit::getRefAddrByteSize().
|
inline |
Definition at line 100 of file DWARFUnit.h.
Referenced by llvm::DWARFUnit::getHeaderSize().
|
inline |
Definition at line 94 of file DWARFUnit.h.
Referenced by llvm::DWARFTypeUnit::getTypeHash().
|
inline |
Definition at line 95 of file DWARFUnit.h.
Referenced by llvm::DWARFTypeUnit::getTypeOffset().
|
inline |
Definition at line 96 of file DWARFUnit.h.
Referenced by llvm::DWARFUnit::getUnitType().
|
inline |
Definition at line 79 of file DWARFUnit.h.
References llvm::dwarf::FormParams::Version.
Referenced by llvm::DWARFUnit::getVersion().
|
inline |
Definition at line 97 of file DWARFUnit.h.
Referenced by llvm::DWARFUnitVector::addUnitsForDWOSection(), and llvm::DWARFUnit::isTypeUnit().
|
inline |
Definition at line 89 of file DWARFUnit.h.
References assert().
Referenced by llvm::DWARFUnit::getCompilationDir(), and llvm::DWARFUnit::setDWOId().