35a36
> #include "arch/sparc/process.hh"
42,44d42
< #if !FULL_SYSTEM
< #include "arch/sparc/process.hh"
< #endif
669,670c667,670
< #if !FULL_SYSTEM
< doNormalFault(tc, trapType(), false);
---
> if (FullSystem) {
> SparcFaultBase::invoke(tc, inst);
> } else {
> doNormalFault(tc, trapType(), false);
672c672
< Process *p = tc->getProcessPtr();
---
> Process *p = tc->getProcessPtr();
674,676c674,676
< //XXX This will only work in faults from a SparcLiveProcess
< SparcLiveProcess *lp = dynamic_cast<SparcLiveProcess *>(p);
< assert(lp);
---
> //XXX This will only work in faults from a SparcLiveProcess
> SparcLiveProcess *lp = dynamic_cast<SparcLiveProcess *>(p);
> assert(lp);
678,682c678,680
< // Then adjust the PC and NPC
< tc->pcState(lp->readSpillStart());
< #else
< SparcFaultBase::invoke(tc, inst);
< #endif
---
> // Then adjust the PC and NPC
> tc->pcState(lp->readSpillStart());
> }
688,689c686,689
< #if !FULL_SYSTEM
< doNormalFault(tc, trapType(), false);
---
> if (FullSystem) {
> SparcFaultBase::invoke(tc, inst);
> } else {
> doNormalFault(tc, trapType(), false);
691c691
< Process *p = tc->getProcessPtr();
---
> Process *p = tc->getProcessPtr();
693,695c693,695
< //XXX This will only work in faults from a SparcLiveProcess
< SparcLiveProcess *lp = dynamic_cast<SparcLiveProcess *>(p);
< assert(lp);
---
> //XXX This will only work in faults from a SparcLiveProcess
> SparcLiveProcess *lp = dynamic_cast<SparcLiveProcess *>(p);
> assert(lp);
697,701c697,699
< // Then adjust the PC and NPC
< tc->pcState(lp->readFillStart());
< #else
< SparcFaultBase::invoke(tc, inst);
< #endif
---
> // Then adjust the PC and NPC
> tc->pcState(lp->readFillStart());
> }
707,710c705,710
< #if !FULL_SYSTEM
< // In SE, this mechanism is how the process requests a service from the
< // operating system. We'll get the process object from the thread context
< // and let it service the request.
---
> if (FullSystem) {
> SparcFaultBase::invoke(tc, inst);
> } else {
> // In SE, this mechanism is how the process requests a service from
> // the operating system. We'll get the process object from the thread
> // context and let it service the request.
712c712
< Process *p = tc->getProcessPtr();
---
> Process *p = tc->getProcessPtr();
714,715c714,715
< SparcLiveProcess *lp = dynamic_cast<SparcLiveProcess *>(p);
< assert(lp);
---
> SparcLiveProcess *lp = dynamic_cast<SparcLiveProcess *>(p);
> assert(lp);
717c717
< lp->handleTrap(_n, tc);
---
> lp->handleTrap(_n, tc);
719,726c719,724
< // We need to explicitly advance the pc, since that's not done for us
< // on a faulting instruction
< PCState pc = tc->pcState();
< pc.advance();
< tc->pcState(pc);
< #else
< SparcFaultBase::invoke(tc, inst);
< #endif
---
> // We need to explicitly advance the pc, since that's not done for us
> // on a faulting instruction
> PCState pc = tc->pcState();
> pc.advance();
> tc->pcState(pc);
> }