summaryrefslogtreecommitdiff
path: root/cpu
diff options
context:
space:
mode:
authorGabe Black <gblack@eecs.umich.edu>2006-02-27 23:26:13 -0500
committerGabe Black <gblack@eecs.umich.edu>2006-02-27 23:26:13 -0500
commit6165419d356fb0cdbcb70d22dcd2f32e689eb7db (patch)
tree61dc14eca57e4be6dbfd53d68ae5e2e1ad2343ec /cpu
parent36b2d9815e32781aba1f51acb0b89cdd4f3e2da9 (diff)
downloadgem5-6165419d356fb0cdbcb70d22dcd2f32e689eb7db.tar.xz
Changed ev5_trap from a function of the execution context to a function of the fault. The actual function still resides in the execution context.
--HG-- extra : convert_revision : 56e33536cdd9079ace03896b85ea3c84b6eb4e57
Diffstat (limited to 'cpu')
-rw-r--r--cpu/exec_context.cc2
-rw-r--r--cpu/exec_context.hh2
-rw-r--r--cpu/simple/cpu.cc4
-rw-r--r--cpu/simple/cpu.hh2
4 files changed, 5 insertions, 5 deletions
diff --git a/cpu/exec_context.cc b/cpu/exec_context.cc
index cf0ced7b0..7e8b81e18 100644
--- a/cpu/exec_context.cc
+++ b/cpu/exec_context.cc
@@ -227,7 +227,7 @@ ExecContext::trap(Fault fault)
/** @todo: Going to hack it for now. Do a true fixup later. */
#if FULL_SYSTEM
- ev5_trap(fault);
+ fault->ev5_trap(this);
#else
fatal("fault (%d) detected @ PC 0x%08p", fault, readPC());
#endif
diff --git a/cpu/exec_context.hh b/cpu/exec_context.hh
index 834eacec8..e23370d0b 100644
--- a/cpu/exec_context.hh
+++ b/cpu/exec_context.hh
@@ -425,7 +425,7 @@ class ExecContext
void setIntrFlag(int val) { regs.intrflag = val; }
Fault hwrei();
bool inPalMode() { return AlphaISA::PcPAL(regs.pc); }
- void ev5_trap(Fault fault);
+ void ev5_temp_trap(Fault fault);
bool simPalCheck(int palFunc);
#endif
diff --git a/cpu/simple/cpu.cc b/cpu/simple/cpu.cc
index 4b0eda386..1f362876f 100644
--- a/cpu/simple/cpu.cc
+++ b/cpu/simple/cpu.cc
@@ -688,7 +688,7 @@ SimpleCPU::tick()
if (ipl && ipl > xc->regs.ipr[IPR_IPLR]) {
ipr[IPR_ISR] = summary;
ipr[IPR_INTID] = ipl;
- xc->ev5_trap(new InterruptFault);
+ (new InterruptFault)->ev5_trap(xc);
DPRINTF(Flow, "Interrupt! IPLR=%d ipl=%d summary=%x\n",
ipr[IPR_IPLR], ipl, summary);
@@ -812,7 +812,7 @@ SimpleCPU::tick()
if (fault != NoFault) {
#if FULL_SYSTEM
- xc->ev5_trap(fault);
+ fault->ev5_trap(xc);
#else // !FULL_SYSTEM
fatal("fault (%d) detected @ PC 0x%08p", fault, xc->regs.pc);
#endif // FULL_SYSTEM
diff --git a/cpu/simple/cpu.hh b/cpu/simple/cpu.hh
index ed7b1e29b..c58b3c5ba 100644
--- a/cpu/simple/cpu.hh
+++ b/cpu/simple/cpu.hh
@@ -334,7 +334,7 @@ class SimpleCPU : public BaseCPU
int readIntrFlag() { return xc->readIntrFlag(); }
void setIntrFlag(int val) { xc->setIntrFlag(val); }
bool inPalMode() { return xc->inPalMode(); }
- void ev5_trap(Fault fault) { xc->ev5_trap(fault); }
+ void ev5_trap(Fault fault) { fault->ev5_trap(xc); }
bool simPalCheck(int palFunc) { return xc->simPalCheck(palFunc); }
#else
void syscall() { xc->syscall(); }