LLVM  9.0.0svn
Public Member Functions | List of all members
llvm::DWARFUnitHeader Class Reference

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::FormParamsgetFormParams () 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::EntrygetIndexEntry () const
 
uint64_t getTypeHash () const
 
uint32_t getTypeOffset () const
 
uint8_t getUnitType () const
 
bool isTypeUnit () const
 
uint8_t getSize () const
 
uint32_t getNextUnitOffset () const
 

Detailed Description

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 46 of file DWARFUnit.h.

Member Function Documentation

◆ extract()

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 
)

◆ getAbbrOffset()

uint64_t llvm::DWARFUnitHeader::getAbbrOffset ( ) const
inline

Definition at line 86 of file DWARFUnit.h.

Referenced by llvm::DWARFUnit::getAbbreviations().

◆ getAddressByteSize()

uint8_t llvm::DWARFUnitHeader::getAddressByteSize ( ) const
inline

Definition at line 80 of file DWARFUnit.h.

References llvm::dwarf::FormParams::AddrSize.

Referenced by llvm::DWARFUnit::getAddressByteSize().

◆ getDwarfOffsetByteSize()

uint8_t llvm::DWARFUnitHeader::getDwarfOffsetByteSize ( ) const
inline

◆ getDWOId()

Optional<uint64_t> llvm::DWARFUnitHeader::getDWOId ( ) const
inline

Definition at line 87 of file DWARFUnit.h.

◆ getFormat()

dwarf::DwarfFormat llvm::DWARFUnitHeader::getFormat ( ) const
inline

Definition at line 79 of file DWARFUnit.h.

References llvm::dwarf::FormParams::Format.

◆ getFormParams()

const dwarf::FormParams& llvm::DWARFUnitHeader::getFormParams ( ) const
inline

Definition at line 77 of file DWARFUnit.h.

Referenced by llvm::DWARFUnit::getFormParams().

◆ getIndexEntry()

const DWARFUnitIndex::Entry* llvm::DWARFUnitHeader::getIndexEntry ( ) const
inline

◆ getLength()

uint32_t llvm::DWARFUnitHeader::getLength ( ) const
inline

Definition at line 85 of file DWARFUnit.h.

Referenced by llvm::DWARFUnit::dies(), and llvm::DWARFUnit::getLength().

◆ getNextUnitOffset()

uint32_t llvm::DWARFUnitHeader::getNextUnitOffset ( ) const
inline

Definition at line 101 of file DWARFUnit.h.

References Context, and llvm::getDWARFUnitIndex().

Referenced by llvm::DWARFUnit::getNextUnitOffset().

◆ getOffset()

uint32_t llvm::DWARFUnitHeader::getOffset ( ) const
inline

Definition at line 76 of file DWARFUnit.h.

Referenced by llvm::DWARFUnit::getOffset().

◆ getRefAddrByteSize()

uint8_t llvm::DWARFUnitHeader::getRefAddrByteSize ( ) const
inline

◆ getSize()

uint8_t llvm::DWARFUnitHeader::getSize ( ) const
inline

Definition at line 99 of file DWARFUnit.h.

Referenced by llvm::DWARFUnit::getHeaderSize().

◆ getTypeHash()

uint64_t llvm::DWARFUnitHeader::getTypeHash ( ) const
inline

Definition at line 93 of file DWARFUnit.h.

Referenced by llvm::DWARFTypeUnit::getTypeHash().

◆ getTypeOffset()

uint32_t llvm::DWARFUnitHeader::getTypeOffset ( ) const
inline

Definition at line 94 of file DWARFUnit.h.

Referenced by llvm::DWARFTypeUnit::getTypeOffset().

◆ getUnitType()

uint8_t llvm::DWARFUnitHeader::getUnitType ( ) const
inline

Definition at line 95 of file DWARFUnit.h.

Referenced by llvm::DWARFUnit::getUnitType().

◆ getVersion()

uint16_t llvm::DWARFUnitHeader::getVersion ( ) const
inline

Definition at line 78 of file DWARFUnit.h.

References llvm::dwarf::FormParams::Version.

Referenced by llvm::DWARFUnit::getVersion().

◆ isTypeUnit()

bool llvm::DWARFUnitHeader::isTypeUnit ( ) const
inline

◆ setDWOId()

void llvm::DWARFUnitHeader::setDWOId ( uint64_t  Id)
inline

Definition at line 88 of file DWARFUnit.h.

References assert().

Referenced by llvm::DWARFUnit::getCompilationDir(), and llvm::DWARFUnit::setDWOId().


The documentation for this class was generated from the following files: