#if !FULL_SYSTEM
-void TrapInstruction::invoke(ThreadContext * tc)
-{
- // Should be handled in ISA.
-}
-
void SpillNNormal::invoke(ThreadContext *tc)
{
doNormalFault(tc, trapType());
static TrapType _baseTrapType;
static FaultPriority _priority;
static FaultStat _count;
- uint64_t syscall_num;
TrapType baseTrapType() {return _baseTrapType;}
public:
- TrapInstruction(uint32_t n, uint64_t syscall) :
- EnumeratedFault(n), syscall_num(syscall) {;}
+ TrapInstruction(int32_t n) : EnumeratedFault(n) {;}
FaultName name() {return _name;}
FaultPriority priority() {return _priority;}
FaultStat & countStat() {return _count;}
-#if !FULL_SYSTEM
- void invoke(ThreadContext * tc);
-#endif
};
#if FULL_SYSTEM
int lTrapNum = I ? (Rs1 + SW_TRAP) : (Rs1 + Rs2);
DPRINTF(Sparc, "The trap number is %d\n", lTrapNum);
- fault = new TrapInstruction(lTrapNum, R1);
+ fault = new TrapInstruction(lTrapNum);
#else
DPRINTF(Sparc, "The syscall number is %d\n", R1);
xc->syscall(R1);
#if FULL_SYSTEM
int lTrapNum = I ? (Rs1 + SW_TRAP) : (Rs1 + Rs2);
DPRINTF(Sparc, "The trap number is %d\n", lTrapNum);
- fault = new TrapInstruction(lTrapNum, R1);
+ fault = new TrapInstruction(lTrapNum);
#else
DPRINTF(Sparc, "The syscall number is %d\n", R1);
xc->syscall(R1);