gem5  v22.1.0.0
Public Member Functions | Private Member Functions | Private Attributes | List of all members
gem5::ruby::DataBlock Class Reference

#include <DataBlock.hh>

Public Member Functions

 DataBlock ()
 
 DataBlock (const DataBlock &cp)
 
 ~DataBlock ()
 
DataBlockoperator= (const DataBlock &obj)
 
void assign (uint8_t *data)
 
void clear ()
 
uint8_t getByte (int whichByte) const
 
const uint8_t * getData (int offset, int len) const
 
uint8_t * getDataMod (int offset)
 
void setByte (int whichByte, uint8_t data)
 
void setData (const uint8_t *data, int offset, int len)
 
void setData (PacketPtr pkt)
 
void copyPartial (const DataBlock &dblk, int offset, int len)
 
void copyPartial (const DataBlock &dblk, const WriteMask &mask)
 
void atomicPartial (const DataBlock &dblk, const WriteMask &mask)
 
bool equal (const DataBlock &obj) const
 
void print (std::ostream &out) const
 

Private Member Functions

void alloc ()
 

Private Attributes

uint8_t * m_data
 
bool m_alloc
 

Detailed Description

Definition at line 60 of file DataBlock.hh.

Constructor & Destructor Documentation

◆ DataBlock() [1/2]

gem5::ruby::DataBlock::DataBlock ( )
inline

Definition at line 63 of file DataBlock.hh.

References alloc().

◆ DataBlock() [2/2]

gem5::ruby::DataBlock::DataBlock ( const DataBlock cp)

Definition at line 52 of file DataBlock.cc.

References gem5::ruby::RubySystem::getBlockSizeBytes(), m_alloc, and m_data.

◆ ~DataBlock()

gem5::ruby::DataBlock::~DataBlock ( )
inline

Definition at line 70 of file DataBlock.hh.

References m_alloc, and m_data.

Member Function Documentation

◆ alloc()

void gem5::ruby::DataBlock::alloc ( )
private

Definition at line 60 of file DataBlock.cc.

References clear(), gem5::ruby::RubySystem::getBlockSizeBytes(), m_alloc, and m_data.

Referenced by DataBlock().

◆ assign()

void gem5::ruby::DataBlock::assign ( uint8_t *  data)
inline

Definition at line 100 of file DataBlock.hh.

References data, m_alloc, and m_data.

◆ atomicPartial()

void gem5::ruby::DataBlock::atomicPartial ( const DataBlock dblk,
const WriteMask mask 
)

◆ clear()

void gem5::ruby::DataBlock::clear ( )

◆ copyPartial() [1/2]

void gem5::ruby::DataBlock::copyPartial ( const DataBlock dblk,
const WriteMask mask 
)

◆ copyPartial() [2/2]

void gem5::ruby::DataBlock::copyPartial ( const DataBlock dblk,
int  offset,
int  len 
)
inline

Definition at line 123 of file DataBlock.hh.

References len, m_data, gem5::ArmISA::offset, and setData().

◆ equal()

bool gem5::ruby::DataBlock::equal ( const DataBlock obj) const

Definition at line 74 of file DataBlock.cc.

References gem5::ruby::RubySystem::getBlockSizeBytes(), and m_data.

Referenced by gem5::ruby::operator==().

◆ getByte()

uint8_t gem5::ruby::DataBlock::getByte ( int  whichByte) const
inline

◆ getData()

const uint8_t * gem5::ruby::DataBlock::getData ( int  offset,
int  len 
) const

◆ getDataMod()

uint8_t * gem5::ruby::DataBlock::getDataMod ( int  offset)

Definition at line 118 of file DataBlock.cc.

References m_data, and gem5::ArmISA::offset.

Referenced by gem5::ruby::WriteMask::performAtomic().

◆ operator=()

DataBlock & gem5::ruby::DataBlock::operator= ( const DataBlock obj)

Definition at line 138 of file DataBlock.cc.

References gem5::ruby::RubySystem::getBlockSizeBytes(), and m_data.

◆ print()

void gem5::ruby::DataBlock::print ( std::ostream &  out) const

Definition at line 99 of file DataBlock.cc.

References gem5::ruby::RubySystem::getBlockSizeBytes(), gem5::ArmISA::i, and m_data.

Referenced by gem5::ruby::operator<<().

◆ setByte()

void gem5::ruby::DataBlock::setByte ( int  whichByte,
uint8_t  data 
)
inline

Definition at line 117 of file DataBlock.hh.

References data, and m_data.

Referenced by gem5::ruby::testAndWrite().

◆ setData() [1/2]

void gem5::ruby::DataBlock::setData ( const uint8_t *  data,
int  offset,
int  len 
)

Definition at line 124 of file DataBlock.cc.

References data, len, m_data, and gem5::ArmISA::offset.

Referenced by copyPartial(), and gem5::ruby::VIPERCoalescer::issueRequest().

◆ setData() [2/2]

void gem5::ruby::DataBlock::setData ( PacketPtr  pkt)

Member Data Documentation

◆ m_alloc

bool gem5::ruby::DataBlock::m_alloc
private

Definition at line 96 of file DataBlock.hh.

Referenced by alloc(), assign(), DataBlock(), and ~DataBlock().

◆ m_data

uint8_t* gem5::ruby::DataBlock::m_data
private

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

Generated on Wed Dec 21 2022 10:24:22 for gem5 by doxygen 1.9.1