diff options
author | Gabe Black <gblack@eecs.umich.edu> | 2010-09-13 19:26:03 -0700 |
---|---|---|
committer | Gabe Black <gblack@eecs.umich.edu> | 2010-09-13 19:26:03 -0700 |
commit | 6833ca7eedd351596bb1518620af7465f5172fcd (patch) | |
tree | 4a67b3d591132dab3e8273fc9dfba606a1720e4a /src/cpu/inorder/cpu.cc | |
parent | 2edfcbbaee87c1a28351fc0dcd81d52d0d9102a4 (diff) | |
download | gem5-6833ca7eedd351596bb1518620af7465f5172fcd.tar.xz |
Faults: Pass the StaticInst involved, if any, to a Fault's invoke method.
Also move the "Fault" reference counted pointer type into a separate file,
sim/fault.hh. It would be better to name this less similarly to sim/faults.hh
to reduce confusion, but fault.hh matches the name of the type. We could change
Fault to FaultPtr to match other pointer types, and then changing the name of
the file would make more sense.
Diffstat (limited to 'src/cpu/inorder/cpu.cc')
-rw-r--r-- | src/cpu/inorder/cpu.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/cpu/inorder/cpu.cc b/src/cpu/inorder/cpu.cc index 059996b07..5d4d3c580 100644 --- a/src/cpu/inorder/cpu.cc +++ b/src/cpu/inorder/cpu.cc @@ -136,7 +136,7 @@ InOrderCPU::CPUEvent::process() break; case Trap: - cpu->trapCPU(fault, tid); + cpu->trapCPU(fault, tid, inst); break; default: @@ -649,16 +649,16 @@ InOrderCPU::updateMemPorts() #endif void -InOrderCPU::trap(Fault fault, ThreadID tid, int delay) +InOrderCPU::trap(Fault fault, ThreadID tid, DynInstPtr inst, int delay) { //@ Squash Pipeline during TRAP - scheduleCpuEvent(Trap, fault, tid, dummyInst[tid], delay); + scheduleCpuEvent(Trap, fault, tid, inst, delay); } void -InOrderCPU::trapCPU(Fault fault, ThreadID tid) +InOrderCPU::trapCPU(Fault fault, ThreadID tid, DynInstPtr inst) { - fault->invoke(tcBase(tid)); + fault->invoke(tcBase(tid), inst->staticInst); } void |