LLVM 19.0.0git
Public Member Functions | Public Attributes | List of all members
llvm::MachineConstantPoolEntry Class Reference

This class is a data container for one entry in a MachineConstantPool. More...

#include "llvm/CodeGen/MachineConstantPool.h"

Public Member Functions

 MachineConstantPoolEntry (const Constant *V, Align A)
 
 MachineConstantPoolEntry (MachineConstantPoolValue *V, Align A)
 
bool isMachineConstantPoolEntry () const
 isMachineConstantPoolEntry - Return true if the MachineConstantPoolEntry is indeed a target specific constantpool entry, not a wrapper over a Constant.
 
Align getAlign () const
 
unsigned getSizeInBytes (const DataLayout &DL) const
 
bool needsRelocation () const
 This method classifies the entry according to whether or not it may generate a relocation entry.
 
SectionKind getSectionKind (const DataLayout *DL) const
 

Public Attributes

union {
   const Constant *   ConstVal
 
   MachineConstantPoolValue *   MachineCPVal
 
Val
 The constant itself.
 
Align Alignment
 The required alignment for this entry.
 
bool IsMachineConstantPoolEntry
 

Detailed Description

This class is a data container for one entry in a MachineConstantPool.

It contains a pointer to the value and an offset from the start of the constant pool. An entry in a MachineConstantPool

Definition at line 67 of file MachineConstantPool.h.

Constructor & Destructor Documentation

◆ MachineConstantPoolEntry() [1/2]

llvm::MachineConstantPoolEntry::MachineConstantPoolEntry ( const Constant V,
Align  A 
)
inline

Definition at line 80 of file MachineConstantPool.h.

References Val.

◆ MachineConstantPoolEntry() [2/2]

llvm::MachineConstantPoolEntry::MachineConstantPoolEntry ( MachineConstantPoolValue V,
Align  A 
)
inline

Definition at line 85 of file MachineConstantPool.h.

References Val.

Member Function Documentation

◆ getAlign()

Align llvm::MachineConstantPoolEntry::getAlign ( ) const
inline

Definition at line 95 of file MachineConstantPool.h.

References Alignment.

Referenced by llvm::AsmPrinter::emitConstantPool().

◆ getSectionKind()

SectionKind MachineConstantPoolEntry::getSectionKind ( const DataLayout DL) const

◆ getSizeInBytes()

unsigned MachineConstantPoolEntry::getSizeInBytes ( const DataLayout DL) const

Definition at line 1379 of file MachineFunction.cpp.

References DL, isMachineConstantPoolEntry(), and Val.

Referenced by llvm::AsmPrinter::emitConstantPool(), and getSectionKind().

◆ isMachineConstantPoolEntry()

bool llvm::MachineConstantPoolEntry::isMachineConstantPoolEntry ( ) const
inline

◆ needsRelocation()

bool MachineConstantPoolEntry::needsRelocation ( ) const

This method classifies the entry according to whether or not it may generate a relocation entry.

This must be conservative, so if it might codegen to a relocatable entry, it should say so.

Definition at line 1385 of file MachineFunction.cpp.

References isMachineConstantPoolEntry(), and Val.

Referenced by getSectionKind().

Member Data Documentation

◆ Alignment

Align llvm::MachineConstantPoolEntry::Alignment

The required alignment for this entry.

Definition at line 76 of file MachineConstantPool.h.

Referenced by getAlign(), and llvm::AsmPrinter::GetCPISymbol().

◆ ConstVal

const Constant* llvm::MachineConstantPoolEntry::ConstVal

◆ IsMachineConstantPoolEntry

bool llvm::MachineConstantPoolEntry::IsMachineConstantPoolEntry

Definition at line 78 of file MachineConstantPool.h.

Referenced by isMachineConstantPoolEntry().

◆ MachineCPVal

MachineConstantPoolValue* llvm::MachineConstantPoolEntry::MachineCPVal

◆ 

union { ... } llvm::MachineConstantPoolEntry::Val

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