class DwarfStringPoolEntryRef

Declaration

class DwarfStringPoolEntryRef { /* full declaration omitted */ };

Description

DwarfStringPoolEntryRef: Dwarf string pool entry reference. Dwarf string pool entry keeps string value and its data. There are two variants how data are represented: 1. By value - StringMapEntry <DwarfStringPoolEntry >. 2. By pointer - StringMapEntry <DwarfStringPoolEntry *>. The "By pointer" variant allows for reducing memory usage for the case when string pool entry does not have data: it keeps the null pointer and so no need to waste space for the full DwarfStringPoolEntry. It is recommended to use "By pointer" variant if not all entries of dwarf string pool have corresponding DwarfStringPoolEntry.

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:44

Member Variables

private PointerUnion<llvm::DwarfStringPoolEntryRef:: ByValStringEntryPtr, llvm::DwarfStringPoolEntryRef:: ByPtrStringEntryPtr> MapEntry = nullptr
Pointer to the dwarf string pool Entry.

Method Overview

Methods

DwarfStringPoolEntryRef()

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:55

DwarfStringPoolEntryRef(
    const StringMapEntry<
        llvm::DwarfStringPoolEntry>& Entry)

Description

ASSUMPTION: DwarfStringPoolEntryRef keeps pointer to \p Entry, thus specified entry mustn`t be reallocated.

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:59

Parameters

const StringMapEntry<llvm::DwarfStringPoolEntry>& Entry

DwarfStringPoolEntryRef(
    const StringMapEntry<
        llvm::DwarfStringPoolEntry*>& Entry)

Description

ASSUMPTION: DwarfStringPoolEntryRef keeps pointer to \p Entry, thus specified entry mustn`t be reallocated.

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:64

Parameters

const StringMapEntry<llvm::DwarfStringPoolEntry*>& Entry

const llvm::DwarfStringPoolEntry& getEntry() const

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:95

Returns

the entire string pool entry for convenience.

unsigned int getIndex() const

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:81

Returns

index for the dwarf string.

uint64_t getOffset() const

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:78

Returns

offset for the dwarf string.

llvm::StringRef getString() const

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:87

Returns

string.

llvm::MCSymbol* getSymbol() const

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:72

Returns

symbol for the dwarf string.

bool operator bool() const

Declared at: llvm/include/llvm/CodeGen/DwarfStringPoolEntry.h:69