LLDB mainline
Classes | Public Types | Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
lldb_private::plugin::dwarf::DWARFFormValue Class Reference

#include <DWARFFormValue.h>

Classes

struct  ValueTypeTag
 

Public Types

enum  {
  eValueTypeInvalid = 0 , eValueTypeUnsigned , eValueTypeSigned , eValueTypeCStr ,
  eValueTypeBlock
}
 
typedef struct lldb_private::plugin::dwarf::DWARFFormValue::ValueTypeTag ValueType
 

Public Member Functions

 DWARFFormValue ()=default
 
 DWARFFormValue (const DWARFUnit *unit)
 
 DWARFFormValue (const DWARFUnit *unit, dw_form_t form)
 
const DWARFUnitGetUnit () const
 
void SetUnit (const DWARFUnit *unit)
 
dw_form_t Form () const
 
dw_form_tFormRef ()
 
void SetForm (dw_form_t form)
 
const ValueTypeValue () const
 
ValueTypeValueRef ()
 
void SetValue (const ValueType &val)
 
void Dump (Stream &s) const
 
bool ExtractValue (const DWARFDataExtractor &data, lldb::offset_t *offset_ptr)
 
const uint8_t * BlockData () const
 
std::optional< uint8_t > GetFixedSize () const
 
DWARFDIE Reference () const
 
std::pair< DWARFUnit *, uint64_t > ReferencedUnitAndOffset () const
 If this is a reference to another DIE, return the corresponding DWARFUnit and DIE offset such that Unit->GetDIE(offset) produces the desired DIE.
 
uint64_t Reference (dw_offset_t offset) const
 
bool Boolean () const
 
uint64_t Unsigned () const
 
void SetUnsigned (uint64_t uval)
 
int64_t Signed () const
 
void SetSigned (int64_t sval)
 
const char * AsCString () const
 
dw_addr_t Address () const
 
bool IsValid () const
 
bool SkipValue (const DWARFDataExtractor &debug_info_data, lldb::offset_t *offset_ptr) const
 
void Clear ()
 

Static Public Member Functions

static std::optional< uint8_t > GetFixedSize (dw_form_t form, const DWARFUnit *u)
 
static bool SkipValue (const dw_form_t form, const DWARFDataExtractor &debug_info_data, lldb::offset_t *offset_ptr, const DWARFUnit *unit)
 
static bool IsBlockForm (const dw_form_t form)
 
static bool IsDataForm (const dw_form_t form)
 
static int Compare (const DWARFFormValue &a, const DWARFFormValue &b)
 
static bool FormIsSupported (dw_form_t form)
 

Protected Attributes

const DWARFUnitm_unit = nullptr
 
dw_form_t m_form = dw_form_t(0)
 
ValueType m_value
 

Detailed Description

Definition at line 22 of file DWARFFormValue.h.

Member Typedef Documentation

◆ ValueType

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
eValueTypeInvalid 
eValueTypeUnsigned 
eValueTypeSigned 
eValueTypeCStr 
eValueTypeBlock 

Definition at line 35 of file DWARFFormValue.h.

Constructor & Destructor Documentation

◆ DWARFFormValue() [1/3]

lldb_private::plugin::dwarf::DWARFFormValue::DWARFFormValue ( )
default

◆ DWARFFormValue() [2/3]

lldb_private::plugin::dwarf::DWARFFormValue::DWARFFormValue ( const DWARFUnit unit)
inline

Definition at line 44 of file DWARFFormValue.h.

◆ DWARFFormValue() [3/3]

lldb_private::plugin::dwarf::DWARFFormValue::DWARFFormValue ( const DWARFUnit unit,
dw_form_t  form 
)
inline

Definition at line 45 of file DWARFFormValue.h.

Member Function Documentation

◆ Address()

dw_addr_t DWARFFormValue::Address ( ) const

◆ AsCString()

const char * DWARFFormValue::AsCString ( ) const

◆ BlockData()

const uint8_t * DWARFFormValue::BlockData ( ) const

◆ Boolean()

bool lldb_private::plugin::dwarf::DWARFFormValue::Boolean ( ) const
inline

◆ Clear()

void DWARFFormValue::Clear ( )

Definition at line 25 of file DWARFFormValue.cpp.

References m_form, m_unit, and m_value.

Referenced by DWARFASTParserClang::ParseTypeModifier().

◆ Compare()

static int lldb_private::plugin::dwarf::DWARFFormValue::Compare ( const DWARFFormValue a,
const DWARFFormValue b 
)
static

◆ Dump()

void DWARFFormValue::Dump ( Stream s) const

◆ ExtractValue()

bool DWARFFormValue::ExtractValue ( const DWARFDataExtractor data,
lldb::offset_t offset_ptr 
)

◆ Form()

dw_form_t lldb_private::plugin::dwarf::DWARFFormValue::Form ( ) const
inline

◆ FormIsSupported()

bool DWARFFormValue::FormIsSupported ( dw_form_t  form)
static

Definition at line 603 of file DWARFFormValue.cpp.

Referenced by GetUnsupportedForms().

◆ FormRef()

dw_form_t & lldb_private::plugin::dwarf::DWARFFormValue::FormRef ( )
inline

Definition at line 50 of file DWARFFormValue.h.

References m_form.

Referenced by ExtractAttrAndFormValue().

◆ GetFixedSize() [1/2]

std::optional< uint8_t > DWARFFormValue::GetFixedSize ( ) const

◆ GetFixedSize() [2/2]

std::optional< uint8_t > DWARFFormValue::GetFixedSize ( dw_form_t  form,
const DWARFUnit u 
)
static

◆ GetUnit()

const DWARFUnit * lldb_private::plugin::dwarf::DWARFFormValue::GetUnit ( ) const
inline

◆ IsBlockForm()

bool DWARFFormValue::IsBlockForm ( const dw_form_t  form)
static

◆ IsDataForm()

bool DWARFFormValue::IsDataForm ( const dw_form_t  form)
static

◆ IsValid()

bool lldb_private::plugin::dwarf::DWARFFormValue::IsValid ( ) const
inline

◆ Reference() [1/2]

DWARFDIE DWARFFormValue::Reference ( ) const

◆ Reference() [2/2]

uint64_t DWARFFormValue::Reference ( dw_offset_t  offset) const

◆ ReferencedUnitAndOffset()

std::pair< DWARFUnit *, uint64_t > DWARFFormValue::ReferencedUnitAndOffset ( ) const

◆ SetForm()

void lldb_private::plugin::dwarf::DWARFFormValue::SetForm ( dw_form_t  form)
inline

◆ SetSigned()

void lldb_private::plugin::dwarf::DWARFFormValue::SetSigned ( int64_t  sval)
inline

◆ SetUnit()

void lldb_private::plugin::dwarf::DWARFFormValue::SetUnit ( const DWARFUnit unit)
inline

◆ SetUnsigned()

void lldb_private::plugin::dwarf::DWARFFormValue::SetUnsigned ( uint64_t  uval)
inline

◆ SetValue()

void lldb_private::plugin::dwarf::DWARFFormValue::SetValue ( const ValueType val)
inline

◆ Signed()

int64_t lldb_private::plugin::dwarf::DWARFFormValue::Signed ( ) const
inline

◆ SkipValue() [1/2]

bool DWARFFormValue::SkipValue ( const dw_form_t  form,
const DWARFDataExtractor debug_info_data,
lldb::offset_t offset_ptr,
const DWARFUnit unit 
)
static

◆ SkipValue() [2/2]

bool DWARFFormValue::SkipValue ( const DWARFDataExtractor debug_info_data,
lldb::offset_t offset_ptr 
) const

◆ Unsigned()

uint64_t lldb_private::plugin::dwarf::DWARFFormValue::Unsigned ( ) const
inline

◆ Value()

const ValueType & lldb_private::plugin::dwarf::DWARFFormValue::Value ( ) const
inline

Definition at line 52 of file DWARFFormValue.h.

References m_value.

Referenced by lldb_private::plugin::dwarf::DWARFAttributes::Append().

◆ ValueRef()

ValueType & lldb_private::plugin::dwarf::DWARFFormValue::ValueRef ( )
inline

Definition at line 53 of file DWARFFormValue.h.

References m_value.

Member Data Documentation

◆ m_form

dw_form_t lldb_private::plugin::dwarf::DWARFFormValue::m_form = dw_form_t(0)
protected

◆ m_unit

const DWARFUnit* lldb_private::plugin::dwarf::DWARFFormValue::m_unit = nullptr
protected

◆ m_value

ValueType lldb_private::plugin::dwarf::DWARFFormValue::m_value
protected

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