|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecthades.models.mips.core.Coprocessor
Skeleton for a coprocessor including registers and instruction execution logic
Field Summary | |
protected boolean |
condition
|
protected Registers |
coreReg
|
protected boolean |
debug
|
protected int |
number
|
protected PartHandler |
partHandler
|
protected int[] |
reg
|
Constructor Summary | |
Coprocessor(PartHandler newPartHandler,
int coprocNumber)
|
Method Summary | |
int |
decodeAndExecute(Registers registers,
Splitter splitter)
|
boolean |
getCondition()
|
int |
getCoproNumber()
|
boolean |
getLog()
Get debug mode |
int |
getMemorySize()
Capacity of the memory in words |
int |
getWordWidth()
Witdh of one word in bits |
void |
installEntryHandler(EntryHandler entryHandler)
setEntry() calles this EntryHandler |
void |
por()
Power on reset or hardware reset |
int |
readControlRegister(int address)
|
int |
readMemory(int address)
Read a word from the memory |
int |
readRegister(int address)
|
void |
reset()
software reset |
void |
setCondition(boolean newCondition)
|
void |
setEntry(int entry,
int globalPointer)
Set the entry address and the global pointer if memory contains a executable program |
void |
setLog(boolean newDebug)
Enable or disable logging output |
void |
writeControlRegister(int address,
int word)
|
void |
writeMemory(int address,
int word)
Write a word into the memory |
void |
writeRegister(int address,
int word)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected PartHandler partHandler
protected Registers coreReg
protected int[] reg
protected boolean condition
protected int number
protected boolean debug
Constructor Detail |
public Coprocessor(PartHandler newPartHandler, int coprocNumber)
Method Detail |
public void por()
por
in interface Resetable
public void reset()
reset
in interface Resetable
public int getCoproNumber()
public int getWordWidth()
Memory
getWordWidth
in interface Memory
public int getMemorySize()
Memory
getMemorySize
in interface Memory
public int readMemory(int address)
Memory
readMemory
in interface Memory
public void writeMemory(int address, int word)
Memory
writeMemory
in interface Memory
public void setEntry(int entry, int globalPointer)
Memory
setEntry
in interface Memory
public void installEntryHandler(EntryHandler entryHandler)
Memory
installEntryHandler
in interface Memory
public void setLog(boolean newDebug)
Memory
setLog
in interface Memory
public boolean getLog()
Memory
getLog
in interface Memory
public int readRegister(int address)
public void writeRegister(int address, int word)
public int readControlRegister(int address)
public void writeControlRegister(int address, int word)
public boolean getCondition()
public void setCondition(boolean newCondition)
public int decodeAndExecute(Registers registers, Splitter splitter)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |