|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.cmpware.cmp.Link
com.cmpware.cmp.links.PipelineRegister
public class PipelineRegister
This class implements a shared register. This register may be mapped to a memory address or to a special instruction in the processor. Note that this register does not have any sort of control. It may be read or written in any sequence at any time. This is unlike the SharedRegister which is semaphored. Finally, all data written to this register is "shadowed" until a "commit" call is made. This is necessary in multiprocessor simulation environments to assure that proper clock boundaries are preserved.
Copyright (c) 2005 Cmpware, Inc. All Rights Reserved.
| Field Summary | |
|---|---|
static java.lang.String |
copyright
Copyright string |
protected int |
readAddr
The read address (for information only) |
protected int |
readCount
The number of reads |
protected int |
shadow
The shared shadow registers |
protected int |
val
The shared register |
protected int |
writeAddr
The write address (for information only) |
protected int |
writeCount
The number of writes |
| Constructor Summary | |
|---|---|
PipelineRegister()
|
|
| Method Summary | |
|---|---|
int |
getReadAddress()
This method returns the processor address to which the read port of this Memory Mapped IO is mapped. |
int |
getReadCount()
This method returns the number of times the read port has been accessed. |
int |
getReadStallCount()
This method returns the number of times the read port has stalled. |
int |
getValue()
This method returns the most recently written value of the Memory Mapped IO. |
int |
getWriteAddress()
This method returns the processor address to which the write port of this Memory Mapped IO is mapped. |
int |
getWriteCount()
This method returns the number of times the write port has been accessed. |
int |
getWriteStallCount()
This method returns the number of times the write port has stalled. |
boolean |
isReadable()
This method returns a true if the Memory Mapped IO is currently readable. |
boolean |
isWriteable()
This method returns a true if the Memory Mapped IO port is currently writeable. |
int |
read()
This method reads a value from the Memory Mapped IO port. |
void |
readCommit()
All Memory Mapped IO reads are performed whenever data is available. |
void |
reset()
This abstract class is used to reset the link. |
void |
setReadAddress(int addr)
This method sets the read address of the Memeory Mapped IO. |
void |
setWriteAddress(int addr)
This method sets the write address of the Memory Mapped IO. |
void |
write(int val)
This method writes a word to the Memory Mapped IO. |
void |
writeCommit()
All Memory Mapped IO writes are performed whenever data is available. |
| Methods inherited from class com.cmpware.cmp.Link |
|---|
get, setBufferSize |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String copyright
protected int val
protected int shadow
protected int readAddr
protected int writeAddr
protected int readCount
protected int writeCount
| Constructor Detail |
|---|
public PipelineRegister()
| Method Detail |
|---|
public void reset()
MemoryMappedIOReader
public void write(int val)
throws MemoryMappedIOException
MemoryMappedIOWriter
val - The value to write to the Memory Mapped IO.
MemoryMappedIOException - - this method throws
a MemoryMappedIOException if the write could not
be completed on this cycle. This will typically
cause a stall of the processor and a retry on the
next cycle.
public int read()
throws MemoryMappedIOException
MemoryMappedIOReader
MemoryMappedIOException - - this method throws
a MemoryMappedIOException if the read could not
be completed on this cycle. This will typically
cause a stall of the processor and a retry on the
next cycle.public void writeCommit()
MemoryMappedIOWriter
public void readCommit()
MemoryMappedIOReader
public void setReadAddress(int addr)
MemoryMappedIOReader
addr - The Memory Mapped IO read address.public int getReadAddress()
MemoryMappedIOReader
public int getReadCount()
MemoryMappedIOReader
public int getReadStallCount()
MemoryMappedIOReader
public void setWriteAddress(int addr)
MemoryMappedIOWriter
addr - The Memory Mapped IO write address.public int getWriteAddress()
MemoryMappedIOWriter
public int getWriteCount()
MemoryMappedIOWriter
public int getWriteStallCount()
MemoryMappedIOWriter
public int getValue()
MemoryMappedIOReader
public boolean isReadable()
MemoryMappedIOReader
public boolean isWriteable()
MemoryMappedIOWriter
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||