Movatterモバイル変換


[0]ホーム

URL:


LLVM 20.0.0git
Public Member Functions |List of all members
llvm::RegisterBank Class Reference

This class implements the register bank concept.More...

#include "llvm/CodeGen/RegisterBank.h"

Public Member Functions

constexpr RegisterBank (unsignedID,constchar *Name,constuint32_t *CoveredClasses,unsigned NumRegClasses)
 
unsigned getID ()const
 Get the identifier of this register bank.
 
constchargetName ()const
 Get a user friendly name of this register bank.
 
bool verify (constRegisterBankInfo &RBI,constTargetRegisterInfo &TRI)const
 Check if this register bank is valid.
 
bool covers (constTargetRegisterClass &RC)const
 Check whether this register bank coversRC.
 
bool operator== (constRegisterBank &OtherRB)const
 Check whetherOtherRB is the same as this.
 
bool operator!= (constRegisterBank &OtherRB)const
 
void dump (constTargetRegisterInfo *TRI=nullptr)const
 Dump the register mask ondbgs() stream.
 
void print (raw_ostream &OS,bool IsForDebug=false,constTargetRegisterInfo *TRI=nullptr)const
 Print the register mask on OS.
 

Detailed Description

This class implements the register bank concept.

Two instances ofRegisterBank must have different ID. This property is enforced by theRegisterBankInfo class.

Definition at line28 of fileRegisterBank.h.

Constructor & Destructor Documentation

◆ RegisterBank()

constexpr llvm::RegisterBank::RegisterBank(unsigned ID,
constcharName,
constuint32_tCoveredClasses,
unsigned NumRegClasses 
)
inlineconstexpr

Definition at line39 of fileRegisterBank.h.

Member Function Documentation

◆ covers()

bool RegisterBank::covers(constTargetRegisterClassRC) const

Check whether this register bank coversRC.

In other words, check if this register bank fully covers the registers thatRC contains.

Definition at line52 of fileRegisterBank.cpp.

Referencesllvm::TargetRegisterClass::getID().

Referenced byllvm::AArch64RegisterBankInfo::AArch64RegisterBankInfo(),llvm::ARMRegisterBankInfo::ARMRegisterBankInfo(),llvm::RegisterBankInfo::constrainGenericRegister(),llvm::RegisterBankInfo::getRegBankFromConstraints(),print(),verify(), andllvm::X86RegisterBankInfo::X86RegisterBankInfo().

◆ dump()

LLVM_DUMP_METHOD void RegisterBank::dump(constTargetRegisterInfoTRI =nullptr) const

Dump the register mask ondbgs() stream.

The dump is verbose.

Definition at line66 of fileRegisterBank.cpp.

Referencesllvm::dbgs(),print(), andTRI.

◆ getID()

unsigned llvm::RegisterBank::getID() const
inline

Get the identifier of this register bank.

Definition at line45 of fileRegisterBank.h.

Referenced byllvm::AArch64RegisterBankInfo::AArch64RegisterBankInfo(),llvm::AMDGPURegisterBankInfo::applyMappingImpl(),llvm::ARMRegisterBankInfo::ARMRegisterBankInfo(),llvm::ARM::checkPartMapping(),llvm::AMDGPURegisterBankInfo::collectWaterfallOperands(),getAnySgprS1(),getInsertVecEltOpInfo(),llvm::AArch64RegisterBankInfo::getInstrMapping(),llvm::AMDGPURegisterBankInfo::getInstrMapping(),llvm::PPCRegisterBankInfo::getInstrMapping(),llvm::SIInstrInfo::getInstructionUniformity(),getMinClassForRegBank(),getMinSizeForRegBank(),llvm::AMDGPURegisterBankInfo::getRegBankID(),llvm::SIRegisterInfo::getRegClassForSizeOnBank(),llvm::AMDGPURegisterBankInfo::getValueMappingForPtr(),hashPartialMapping(),AMDGPURegBankLegalizeCombiner::isLaneMask(),isLaneMaskFromSameBlock(),isVectorRegisterBank(),operator==(),print(),selectCopy(),selectMergeValues(),selectUnmergeValues(),verify(),llvm::RegisterBankInfo::verify(), andllvm::X86RegisterBankInfo::X86RegisterBankInfo().

◆ getName()

constchar * llvm::RegisterBank::getName() const
inline

Get a user friendly name of this register bank.

Should be used only for debugging purposes.

Definition at line49 of fileRegisterBank.h.

Referenced byprint(), andllvm::printRegClassOrBank().

◆ operator!=()

bool llvm::RegisterBank::operator!=(constRegisterBankOtherRB) const
inline

Definition at line66 of fileRegisterBank.h.

Referencesoperator==().

◆ operator==()

bool RegisterBank::operator==(constRegisterBankOtherRB) const

Check whetherOtherRB is the same as this.

Definition at line56 of fileRegisterBank.cpp.

Referencesassert(), andgetID().

Referenced byoperator!=().

◆ print()

void RegisterBank::print(raw_ostreamOS,
bool IsForDebug =false,
constTargetRegisterInfoTRI =nullptr 
) const

Print the register mask on OS.

If IsForDebug is false, then only the name of the register bank is printed. Otherwise, all the fields are printing. TRI is then used to print the name of the register classes that this register bank covers.

Definition at line71 of fileRegisterBank.cpp.

Referencesassert(),covers(),End,getID(),getName(),OS,llvm::popcount(), andTRI.

Referenced bydump(), andllvm::operator<<().

◆ verify()

bool RegisterBank::verify(constRegisterBankInfoRBI,
constTargetRegisterInfoTRI 
) const

Check if this register bank is valid.

In other words, if it has been properly constructed.

Note
This method does not check anything when assertions are disabled.
Returns
True is the check was successful.

Definition at line23 of fileRegisterBank.cpp.

Referencesassert(),covers(),End,getID(),llvm::RegisterBankInfo::getMaximumSize(),llvm::TargetRegisterClass::hasSubClassEq(), andTRI.

Referenced byllvm::RegisterBankInfo::verify().


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

Generated on Sun Jul 20 2025 19:35:39 for LLVM by doxygen 1.9.6
[8]ページ先頭

©2009-2025 Movatter.jp