Predecoder: Clear out predecoder state on an ITLB fault.
--HG-- extra : convert_revision : 68f8ff778dbd28ade5070edf5a7d662e7bf0045a
This commit is contained in:
parent
4049c9f76a
commit
a56c651980
6 changed files with 18 additions and 3 deletions
|
@ -65,6 +65,9 @@ namespace AlphaISA
|
|||
{
|
||||
}
|
||||
|
||||
void reset()
|
||||
{}
|
||||
|
||||
//Use this to give data to the predecoder. This should be used
|
||||
//when there is control flow.
|
||||
void moreBytes(Addr pc, Addr fetchPC, MachInst inst)
|
||||
|
|
|
@ -64,6 +64,9 @@ namespace MipsISA
|
|||
{
|
||||
}
|
||||
|
||||
void reset()
|
||||
{}
|
||||
|
||||
//Use this to give data to the predecoder. This should be used
|
||||
//when there is control flow.
|
||||
void moreBytes(Addr pc, Addr fetchPC, MachInst inst)
|
||||
|
|
|
@ -65,6 +65,9 @@ namespace SparcISA
|
|||
{
|
||||
}
|
||||
|
||||
void reset()
|
||||
{}
|
||||
|
||||
//Use this to give data to the predecoder. This should be used
|
||||
//when there is control flow.
|
||||
void moreBytes(Addr pc, Addr fetchPC, MachInst inst)
|
||||
|
|
|
@ -62,7 +62,7 @@
|
|||
|
||||
namespace X86ISA
|
||||
{
|
||||
void Predecoder::reset()
|
||||
void Predecoder::doReset()
|
||||
{
|
||||
origPC = basePC + offset;
|
||||
DPRINTF(Predecoder, "Setting origPC to %#x\n", origPC);
|
||||
|
@ -96,7 +96,7 @@ namespace X86ISA
|
|||
switch(state)
|
||||
{
|
||||
case ResetState:
|
||||
reset();
|
||||
doReset();
|
||||
state = PrefixState;
|
||||
case PrefixState:
|
||||
state = doPrefixState(nextByte);
|
||||
|
|
|
@ -134,7 +134,7 @@ namespace X86ISA
|
|||
outOfBytes = true;
|
||||
}
|
||||
|
||||
void reset();
|
||||
void doReset();
|
||||
|
||||
//State machine state
|
||||
protected:
|
||||
|
@ -182,6 +182,11 @@ namespace X86ISA
|
|||
emi.mode.submode = SixtyFourBitMode;
|
||||
}
|
||||
|
||||
void reset()
|
||||
{
|
||||
state = ResetState;
|
||||
}
|
||||
|
||||
ThreadContext * getTC()
|
||||
{
|
||||
return tc;
|
||||
|
|
|
@ -463,6 +463,7 @@ BaseSimpleCPU::advancePC(Fault fault)
|
|||
fetchOffset = 0;
|
||||
if (fault != NoFault) {
|
||||
curMacroStaticInst = StaticInst::nullStaticInstPtr;
|
||||
predecoder.reset();
|
||||
fault->invoke(tc);
|
||||
thread->setMicroPC(0);
|
||||
thread->setNextMicroPC(1);
|
||||
|
|
Loading…
Reference in a new issue