LLVM  14.0.0git
Public Member Functions | Public Attributes | List of all members
llvm::StrOffsetsContributionDescriptor Struct Reference

Represents base address of the CU. More...

#include "llvm/DebugInfo/DWARF/DWARFUnit.h"

Collaboration diagram for llvm::StrOffsetsContributionDescriptor:
Collaboration graph
[legend]

Public Member Functions

 StrOffsetsContributionDescriptor (uint64_t Base, uint64_t Size, uint8_t Version, dwarf::DwarfFormat Format)
 
 StrOffsetsContributionDescriptor ()=default
 
uint8_t getVersion () const
 
dwarf::DwarfFormat getFormat () const
 
uint8_t getDwarfOffsetByteSize () const
 
Expected< StrOffsetsContributionDescriptorvalidateContributionSize (DWARFDataExtractor &DA)
 Determine whether a contribution to the string offsets table is consistent with the relevant section size and that its length is a multiple of the size of one of its entries. More...
 

Public Attributes

uint64_t Base = 0
 
uint64_t Size = 0
 The contribution size not including the header. More...
 
dwarf::FormParams FormParams = {0, 0, dwarf::DwarfFormat::DWARF32}
 Format and version. More...
 

Detailed Description

Represents base address of the CU.

Represents a unit's contribution to the string offsets table.

Definition at line 179 of file DWARFUnit.h.

Constructor & Destructor Documentation

◆ StrOffsetsContributionDescriptor() [1/2]

llvm::StrOffsetsContributionDescriptor::StrOffsetsContributionDescriptor ( uint64_t  Base,
uint64_t  Size,
uint8_t  Version,
dwarf::DwarfFormat  Format 
)
inline

Definition at line 186 of file DWARFUnit.h.

References llvm::IndexedInstrProf::Version.

◆ StrOffsetsContributionDescriptor() [2/2]

llvm::StrOffsetsContributionDescriptor::StrOffsetsContributionDescriptor ( )
default

Member Function Documentation

◆ getDwarfOffsetByteSize()

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

Definition at line 193 of file DWARFUnit.h.

References FormParams, and llvm::dwarf::FormParams::getDwarfOffsetByteSize().

Referenced by validateContributionSize().

◆ getFormat()

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

Definition at line 192 of file DWARFUnit.h.

References llvm::dwarf::FormParams::Format, and FormParams.

◆ getVersion()

uint8_t llvm::StrOffsetsContributionDescriptor::getVersion ( ) const
inline

Definition at line 191 of file DWARFUnit.h.

References FormParams, and llvm::dwarf::FormParams::Version.

◆ validateContributionSize()

Expected< StrOffsetsContributionDescriptor > StrOffsetsContributionDescriptor::validateContributionSize ( DWARFDataExtractor DA)

Determine whether a contribution to the string offsets table is consistent with the relevant section size and that its length is a multiple of the size of one of its entries.

Definition at line 832 of file DWARFUnit.cpp.

References llvm::alignTo(), Base, llvm::createStringError(), llvm::M68kBeads::DA, getDwarfOffsetByteSize(), llvm::invalid_argument, and Size.

Referenced by llvm::DWARFUnit::determineStringOffsetsTableContributionDWO(), and parseDWARFStringOffsetsTableHeader().

Member Data Documentation

◆ Base

uint64_t llvm::StrOffsetsContributionDescriptor::Base = 0

Definition at line 180 of file DWARFUnit.h.

Referenced by collectContributionData(), and validateContributionSize().

◆ FormParams

dwarf::FormParams llvm::StrOffsetsContributionDescriptor::FormParams = {0, 0, dwarf::DwarfFormat::DWARF32}

Format and version.

Definition at line 184 of file DWARFUnit.h.

Referenced by getDwarfOffsetByteSize(), getFormat(), and getVersion().

◆ Size

uint64_t llvm::StrOffsetsContributionDescriptor::Size = 0

The contribution size not including the header.

Definition at line 182 of file DWARFUnit.h.

Referenced by validateContributionSize().


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