torc-master
|
Bitstream packet for Virtex class architectures. More...
#include <VirtexPacket.hpp>
Public Types | |
enum | EPacketType { ePacketType1 = 1, ePacketType2, ePacketTypeCount = 8 } |
Packet type enumeration. More... | |
enum | EOpcode { eOpcodeNOP = 0, eOpcodeRead, eOpcodeWrite, eOpcodeReserved, eOpcodeCount } |
Packet opcode enumeration. More... | |
enum | EPacket { ePacketMaskType = 0xe0000000, ePacketShiftType = 29, ePacketMaskOpcode = 0x18000000, ePacketShiftOpcode = 27, ePacketMaskType1Address = 0x07ffe000, ePacketShiftType1Address = 13, ePacketMaskType1Reserved = 0x00001800, ePacketShiftType1Reserved = 11, ePacketMaskType1Count = 0x000007ff, ePacketShiftType1Count = 0, ePacketMaskType2Count = 0x07ffffff, ePacketShiftType2Count = 0 } |
Packet subfields. More... | |
enum | ESynchronization { eSynchronizationDummy = 0xffffffff, eSynchronizationSync = 0xaa995566, eSynchronizationBusWidthSync = 0x000000bb, eSynchronizationBusWidthDetect = 0x11220044 } |
Synchronization words. More... | |
Public Member Functions | |
VirtexPacket (void) | |
Null constructor. More... | |
VirtexPacket (uint32_t inHeader, uint32_t inCount, uint32_t inWord, uint32_t *inWords) | |
Full constructor. More... | |
VirtexPacket (uint32_t inHeader, uint32_t inWord) | |
Header plus single word constructor. More... | |
VirtexPacket (uint32_t inHeader) | |
Header only constructor. More... | |
VirtexPacket (const VirtexPacket &rhs) | |
Copy constructor. More... | |
void | write (std::ostream &inStream) const |
Write a packet. More... | |
uint32_t | operator[] (size_t inIndex) const |
EPacketType | getType (void) const |
EOpcode | getOpcode (void) const |
int | getAddress (void) const |
uint32_t | getHeader (void) const |
uint32_t | getWordCount (void) const |
Returns the number of payload words in the packet, excluding the header word. More... | |
uint32_t | getWordSize (void) const |
Returns the total number of words in the packet, including the header word. More... | |
const WordSharedArray | getWords (void) const |
brief Returns the raw packet words, including the header word. More... | |
bool | isType1 (void) const |
bool | isType2 (void) const |
bool | isNop (void) const |
bool | isReserved (void) const |
bool | isRead (void) const |
bool | isWrite (void) const |
bool | isDummyWord (void) const |
bool | isSyncWord (void) const |
bool | isBusWidthSyncWord (void) const |
bool | isBusWidthDetectWord (void) const |
Static Public Member Functions | |
static VirtexPacket | read (std::istream &inStream) |
Read a packet. More... | |
static VirtexPacket | makeNullType1Write (uint32_t inAddress) |
Construct a null type 1 write packet. More... | |
static VirtexPacket | makeType1Write (uint32_t inAddress, uint32_t inWord) |
Construct a type 1 write packet. More... | |
static VirtexPacket | makeType1Write (uint32_t inAddress, uint32_t inCount, uint32_t *inWords) |
Construct a multi-word type 1 write packet. More... | |
static VirtexPacket | makeType2Write (uint32_t inCount, uint32_t *inWords) |
Construct a type 2 write packet. More... | |
static uint32_t | makeHeader (EPacketType inType, EOpcode inOpcode, uint32_t inAddress, uint32_t inCount) |
Construct a packet header. More... | |
Data Fields | |
uint32_t | mHeader |
uint32_t | mCount |
uint32_t | mWord |
WordSharedArray | mWords |
EPacketType | mType |
EOpcode | mOpcode |
int | mAddress |
Static Public Attributes | |
static const char * | sPacketTypeName [ePacketTypeCount] |
Packet type names. More... | |
static const char * | sOpcodeName [eOpcodeCount] |
Packet opcode names. More... | |
Protected Types | |
typedef boost::uint32_t | uint32_t |
Imported type name. More... | |
typedef boost::shared_array < uint32_t > | WordSharedArray |
Word shared array type. More... | |
Protected Member Functions | |
void | initialize (void) |
Friends | |
class | torc::bitstream::bitstream::VirtexPacketUnitTest |
Bitstream packet for Virtex class architectures.
Definition at line 76 of file VirtexPacket.hpp.
|
protected |
Imported type name.
Definition at line 81 of file VirtexPacket.hpp.
|
protected |
Word shared array type.
Definition at line 83 of file VirtexPacket.hpp.
|
inherited |
Packet opcode enumeration.
Enumerator | |
---|---|
eOpcodeNOP | |
eOpcodeRead | |
eOpcodeWrite | |
eOpcodeReserved | |
eOpcodeCount |
Definition at line 45 of file VirtexPacket.hpp.
|
inherited |
Packet subfields.
Definition at line 51 of file VirtexPacket.hpp.
|
inherited |
Packet type enumeration.
Enumerator | |
---|---|
ePacketType1 | |
ePacketType2 | |
ePacketTypeCount |
Definition at line 41 of file VirtexPacket.hpp.
|
inherited |
Synchronization words.
Enumerator | |
---|---|
eSynchronizationDummy | |
eSynchronizationSync | |
eSynchronizationBusWidthSync | |
eSynchronizationBusWidthDetect |
Definition at line 67 of file VirtexPacket.hpp.
|
inline |
Null constructor.
Definition at line 108 of file VirtexPacket.hpp.
|
inline |
Full constructor.
Definition at line 111 of file VirtexPacket.hpp.
Header plus single word constructor.
Definition at line 117 of file VirtexPacket.hpp.
|
inline |
Header only constructor.
Definition at line 122 of file VirtexPacket.hpp.
|
inline |
Copy constructor.
Definition at line 127 of file VirtexPacket.hpp.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Returns the number of payload words in the packet, excluding the header word.
Definition at line 246 of file VirtexPacket.hpp.
|
inline |
brief Returns the raw packet words, including the header word.
Definition at line 250 of file VirtexPacket.hpp.
|
inline |
Returns the total number of words in the packet, including the header word.
Definition at line 248 of file VirtexPacket.hpp.
|
inlineprotected |
Definition at line 85 of file VirtexPacket.hpp.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlinestatic |
Construct a packet header.
Definition at line 215 of file VirtexPacket.hpp.
|
inlinestatic |
Construct a null type 1 write packet.
A type 1 write packet to the FDRI register is generally only useful to specify the current register in preparation for a type 2 write. The type 2 write header includes a size but specifies no target register, hence the prior null type 1 packet.
Definition at line 188 of file VirtexPacket.hpp.
|
inlinestatic |
Construct a type 1 write packet.
Definition at line 192 of file VirtexPacket.hpp.
|
inlinestatic |
Construct a multi-word type 1 write packet.
Definition at line 196 of file VirtexPacket.hpp.
|
inlinestatic |
Construct a type 2 write packet.
Definition at line 202 of file VirtexPacket.hpp.
|
inline |
Definition at line 234 of file VirtexPacket.hpp.
|
inlinestatic |
Read a packet.
Definition at line 134 of file VirtexPacket.hpp.
|
inline |
Write a packet.
Definition at line 176 of file VirtexPacket.hpp.
|
friend |
Definition at line 77 of file VirtexPacket.hpp.
int torc::bitstream::VirtexPacket::mAddress |
Definition at line 100 of file VirtexPacket.hpp.
uint32_t torc::bitstream::VirtexPacket::mCount |
Definition at line 95 of file VirtexPacket.hpp.
uint32_t torc::bitstream::VirtexPacket::mHeader |
Definition at line 94 of file VirtexPacket.hpp.
EOpcode torc::bitstream::VirtexPacket::mOpcode |
Definition at line 99 of file VirtexPacket.hpp.
EPacketType torc::bitstream::VirtexPacket::mType |
Definition at line 98 of file VirtexPacket.hpp.
uint32_t torc::bitstream::VirtexPacket::mWord |
Definition at line 96 of file VirtexPacket.hpp.
WordSharedArray torc::bitstream::VirtexPacket::mWords |
Definition at line 97 of file VirtexPacket.hpp.
|
static |
Packet opcode names.
Definition at line 104 of file VirtexPacket.hpp.
|
static |
Packet type names.
Definition at line 102 of file VirtexPacket.hpp.