gem5 v24.0.0.0
Loading...
Searching...
No Matches
gem5::o3::PhysRegFile Class Reference

Simple physical register file class. More...

#include <regfile.hh>

Public Types

using IdRange
 

Public Member Functions

 PhysRegFile (unsigned _numPhysicalIntRegs, unsigned _numPhysicalFloatRegs, unsigned _numPhysicalVecRegs, unsigned _numPhysicalVecPredRegs, unsigned _numPhysicalMatRegs, unsigned _numPhysicalCCRegs, const BaseISA::RegClasses &classes)
 Constructs a physical register file with the specified amount of integer and floating point registers.
 
 ~PhysRegFile ()
 Destructor to free resources.
 
void initFreeList (UnifiedFreeList *freeList)
 Initialize the free list.
 
unsigned totalNumPhysRegs () const
 
PhysRegIdPtr getMiscRegId (RegIndex reg_idx)
 Gets a misc register PhysRegIdPtr.
 
RegVal getReg (PhysRegIdPtr phys_reg) const
 
void getReg (PhysRegIdPtr phys_reg, void *val) const
 
void * getWritableReg (PhysRegIdPtr phys_reg)
 
void setReg (PhysRegIdPtr phys_reg, RegVal val)
 
void setReg (PhysRegIdPtr phys_reg, const void *val)
 

Private Types

using PhysIds = std::vector<PhysRegId>
 

Private Attributes

RegFile intRegFile
 Integer register file.
 
std::vector< PhysRegIdintRegIds
 
RegFile floatRegFile
 Floating point register file.
 
std::vector< PhysRegIdfloatRegIds
 
RegFile vectorRegFile
 Vector register file.
 
std::vector< PhysRegIdvecRegIds
 
RegFile vectorElemRegFile
 Vector element register file.
 
std::vector< PhysRegIdvecElemIds
 
RegFile vecPredRegFile
 Predicate register file.
 
std::vector< PhysRegIdvecPredRegIds
 
RegFile matRegFile
 Matrix register file.
 
std::vector< PhysRegIdmatRegIds
 
RegFile ccRegFile
 Condition-code register file.
 
std::vector< PhysRegIdccRegIds
 
std::vector< PhysRegIdmiscRegIds
 Misc Reg Ids.
 
unsigned numPhysicalIntRegs
 Number of physical general purpose registers.
 
unsigned numPhysicalFloatRegs
 Number of physical floating point registers.
 
unsigned numPhysicalVecRegs
 Number of physical vector registers.
 
unsigned numPhysicalVecElemRegs
 Number of physical vector element registers.
 
unsigned numPhysicalVecPredRegs
 Number of physical predicate registers.
 
unsigned numPhysicalMatRegs
 Number of physical matrix registers.
 
unsigned numPhysicalCCRegs
 Number of physical CC registers.
 
unsigned totalNumRegs
 Total number of physical registers.
 

Detailed Description

Simple physical register file class.

Definition at line 65 of file regfile.hh.

Member Typedef Documentation

◆ IdRange

Initial value:
std::pair<PhysIds::iterator,
PhysIds::iterator>
STL pair class.
Definition stl.hh:58

Definition at line 71 of file regfile.hh.

◆ PhysIds

Definition at line 69 of file regfile.hh.

Constructor & Destructor Documentation

◆ PhysRegFile()

gem5::o3::PhysRegFile::PhysRegFile ( unsigned _numPhysicalIntRegs,
unsigned _numPhysicalFloatRegs,
unsigned _numPhysicalVecRegs,
unsigned _numPhysicalVecPredRegs,
unsigned _numPhysicalMatRegs,
unsigned _numPhysicalCCRegs,
const BaseISA::RegClasses & classes )

◆ ~PhysRegFile()

gem5::o3::PhysRegFile::~PhysRegFile ( )
inline

Destructor to free resources.

Definition at line 159 of file regfile.hh.

Member Function Documentation

◆ getMiscRegId()

PhysRegIdPtr gem5::o3::PhysRegFile::getMiscRegId ( RegIndex reg_idx)
inline

Gets a misc register PhysRegIdPtr.

Definition at line 168 of file regfile.hh.

References miscRegIds.

Referenced by gem5::o3::UnifiedRenameMap::lookup().

◆ getReg() [1/2]

◆ getReg() [2/2]

◆ getWritableReg()

◆ initFreeList()

◆ setReg() [1/2]

◆ setReg() [2/2]

◆ totalNumPhysRegs()

unsigned gem5::o3::PhysRegFile::totalNumPhysRegs ( ) const
inline
Returns
the total number of physical registers.

Definition at line 165 of file regfile.hh.

References totalNumRegs.

Member Data Documentation

◆ ccRegFile

RegFile gem5::o3::PhysRegFile::ccRegFile
private

Condition-code register file.

Definition at line 99 of file regfile.hh.

Referenced by getReg(), and setReg().

◆ ccRegIds

std::vector<PhysRegId> gem5::o3::PhysRegFile::ccRegIds
private

Definition at line 100 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ floatRegFile

RegFile gem5::o3::PhysRegFile::floatRegFile
private

Floating point register file.

Definition at line 79 of file regfile.hh.

Referenced by getReg(), and setReg().

◆ floatRegIds

std::vector<PhysRegId> gem5::o3::PhysRegFile::floatRegIds
private

Definition at line 80 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ intRegFile

RegFile gem5::o3::PhysRegFile::intRegFile
private

Integer register file.

Definition at line 75 of file regfile.hh.

Referenced by getReg(), and setReg().

◆ intRegIds

std::vector<PhysRegId> gem5::o3::PhysRegFile::intRegIds
private

Definition at line 76 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ matRegFile

RegFile gem5::o3::PhysRegFile::matRegFile
private

Matrix register file.

Definition at line 95 of file regfile.hh.

Referenced by getReg(), getWritableReg(), and setReg().

◆ matRegIds

std::vector<PhysRegId> gem5::o3::PhysRegFile::matRegIds
private

Definition at line 96 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ miscRegIds

std::vector<PhysRegId> gem5::o3::PhysRegFile::miscRegIds
private

Misc Reg Ids.

Definition at line 103 of file regfile.hh.

Referenced by getMiscRegId(), and PhysRegFile().

◆ numPhysicalCCRegs

unsigned gem5::o3::PhysRegFile::numPhysicalCCRegs
private

Number of physical CC registers.

Definition at line 138 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ numPhysicalFloatRegs

unsigned gem5::o3::PhysRegFile::numPhysicalFloatRegs
private

Number of physical floating point registers.

Definition at line 113 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ numPhysicalIntRegs

unsigned gem5::o3::PhysRegFile::numPhysicalIntRegs
private

Number of physical general purpose registers.

Definition at line 108 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ numPhysicalMatRegs

unsigned gem5::o3::PhysRegFile::numPhysicalMatRegs
private

Number of physical matrix registers.

Definition at line 133 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ numPhysicalVecElemRegs

unsigned gem5::o3::PhysRegFile::numPhysicalVecElemRegs
private

Number of physical vector element registers.

Definition at line 123 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ numPhysicalVecPredRegs

unsigned gem5::o3::PhysRegFile::numPhysicalVecPredRegs
private

Number of physical predicate registers.

Definition at line 128 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ numPhysicalVecRegs

unsigned gem5::o3::PhysRegFile::numPhysicalVecRegs
private

Number of physical vector registers.

Definition at line 118 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ totalNumRegs

unsigned gem5::o3::PhysRegFile::totalNumRegs
private

Total number of physical registers.

Definition at line 141 of file regfile.hh.

Referenced by totalNumPhysRegs().

◆ vecElemIds

std::vector<PhysRegId> gem5::o3::PhysRegFile::vecElemIds
private

Definition at line 88 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ vecPredRegFile

RegFile gem5::o3::PhysRegFile::vecPredRegFile
private

Predicate register file.

Definition at line 91 of file regfile.hh.

Referenced by getReg(), getWritableReg(), and setReg().

◆ vecPredRegIds

std::vector<PhysRegId> gem5::o3::PhysRegFile::vecPredRegIds
private

Definition at line 92 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ vecRegIds

std::vector<PhysRegId> gem5::o3::PhysRegFile::vecRegIds
private

Definition at line 84 of file regfile.hh.

Referenced by initFreeList(), and PhysRegFile().

◆ vectorElemRegFile

RegFile gem5::o3::PhysRegFile::vectorElemRegFile
private

Vector element register file.

Definition at line 87 of file regfile.hh.

Referenced by getReg(), and setReg().

◆ vectorRegFile

RegFile gem5::o3::PhysRegFile::vectorRegFile
private

Vector register file.

Definition at line 83 of file regfile.hh.

Referenced by getReg(), getWritableReg(), and setReg().


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

Generated on Tue Jun 18 2024 16:24:20 for gem5 by doxygen 1.11.0