LLVM 20.0.0git
Public Member Functions | Public Attributes | List of all members
llvm::dwarf::FormParams Struct Reference

A helper struct providing information about the byte size of DW_FORM values that vary in size depending on the DWARF version, address byte size, or DWARF32/DWARF64. More...

#include "llvm/BinaryFormat/Dwarf.h"

Public Member Functions

uint8_t getRefAddrByteSize () const
 The definition of the size of form DW_FORM_ref_addr depends on the version.
 
uint8_t getDwarfOffsetByteSize () const
 The size of a reference is determined by the DWARF 32/64-bit format.
 
 operator bool () const
 

Public Attributes

uint16_t Version
 
uint8_t AddrSize
 
DwarfFormat Format
 
bool DwarfUsesRelocationsAcrossSections = false
 True if DWARF v2 output generally uses relocations for references to other .debug_* sections.
 

Detailed Description

A helper struct providing information about the byte size of DW_FORM values that vary in size depending on the DWARF version, address byte size, or DWARF32/DWARF64.

Definition at line 1084 of file Dwarf.h.

Member Function Documentation

◆ getDwarfOffsetByteSize()

uint8_t llvm::dwarf::FormParams::getDwarfOffsetByteSize ( ) const
inline

◆ getRefAddrByteSize()

uint8_t llvm::dwarf::FormParams::getRefAddrByteSize ( ) const
inline

The definition of the size of form DW_FORM_ref_addr depends on the version.

In DWARF v2 it's the size of an address; after that, it's the size of a reference.

Definition at line 1095 of file Dwarf.h.

References AddrSize, getDwarfOffsetByteSize(), and Version.

Referenced by llvm::dwarf_linker::parallel::SectionDescriptor::apply(), llvm::dwarf::getFixedFormByteSize(), llvm::DWARFUnitHeader::getRefAddrByteSize(), llvm::DIEEntry::sizeOf(), and writeDIE().

◆ operator bool()

llvm::dwarf::FormParams::operator bool ( ) const
inlineexplicit

Definition at line 1106 of file Dwarf.h.

References AddrSize, and Version.

Member Data Documentation

◆ AddrSize

uint8_t llvm::dwarf::FormParams::AddrSize

◆ DwarfUsesRelocationsAcrossSections

bool llvm::dwarf::FormParams::DwarfUsesRelocationsAcrossSections = false

True if DWARF v2 output generally uses relocations for references to other .debug_* sections.

Definition at line 1090 of file Dwarf.h.

Referenced by llvm::DIEString::sizeOf().

◆ Format

DwarfFormat llvm::dwarf::FormParams::Format

◆ Version

uint16_t llvm::dwarf::FormParams::Version

The documentation for this struct was generated from the following file: