gem5  v20.1.0.0
Public Member Functions | Private Member Functions | Private Attributes | List of all members
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 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 40 of file DataBlock.hh.

Constructor & Destructor Documentation

◆ DataBlock() [1/2]

DataBlock::DataBlock ( )
inline

Definition at line 43 of file DataBlock.hh.

References alloc().

◆ DataBlock() [2/2]

DataBlock::DataBlock ( const DataBlock cp)

Definition at line 34 of file DataBlock.cc.

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

◆ ~DataBlock()

DataBlock::~DataBlock ( )
inline

Definition at line 50 of file DataBlock.hh.

References m_alloc, and m_data.

Member Function Documentation

◆ alloc()

void DataBlock::alloc ( )
private

Definition at line 42 of file DataBlock.cc.

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

Referenced by DataBlock().

◆ assign()

void DataBlock::assign ( uint8_t *  data)
inline

Definition at line 79 of file DataBlock.hh.

References data, m_alloc, and m_data.

◆ atomicPartial()

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

Definition at line 72 of file DataBlock.cc.

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

◆ clear()

void DataBlock::clear ( )

Definition at line 50 of file DataBlock.cc.

References RubySystem::getBlockSizeBytes(), and m_data.

Referenced by alloc(), and VIPERCoalescer::issueRequest().

◆ copyPartial() [1/2]

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

Definition at line 62 of file DataBlock.cc.

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

◆ copyPartial() [2/2]

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

Definition at line 102 of file DataBlock.hh.

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

◆ equal()

bool DataBlock::equal ( const DataBlock obj) const

Definition at line 56 of file DataBlock.cc.

References RubySystem::getBlockSizeBytes(), and m_data.

Referenced by operator==().

◆ getByte()

uint8_t DataBlock::getByte ( int  whichByte) const
inline

Definition at line 90 of file DataBlock.hh.

References m_data.

Referenced by SubBlock::internalMergeFrom(), testAndRead(), and testAndReadMask().

◆ getData()

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

Definition at line 95 of file DataBlock.cc.

References RubySystem::getBlockSizeBytes(), ArmISA::len, m_data, and ArmISA::offset.

Referenced by DMASequencer::dataCallback().

◆ getDataMod()

uint8_t * DataBlock::getDataMod ( int  offset)

Definition at line 102 of file DataBlock.cc.

References m_data, and ArmISA::offset.

Referenced by WriteMask::performAtomic().

◆ operator=()

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

Definition at line 114 of file DataBlock.cc.

References RubySystem::getBlockSizeBytes(), and m_data.

◆ print()

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

Definition at line 81 of file DataBlock.cc.

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

Referenced by operator<<().

◆ setByte()

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

Definition at line 96 of file DataBlock.hh.

References data, and m_data.

Referenced by testAndWrite().

◆ setData()

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

Definition at line 108 of file DataBlock.cc.

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

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

Member Data Documentation

◆ m_alloc

bool DataBlock::m_alloc
private

Definition at line 75 of file DataBlock.hh.

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

◆ m_data

uint8_t* DataBlock::m_data
private

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

Generated on Wed Sep 30 2020 14:02:23 for gem5 by doxygen 1.8.17