diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/alpha/tlb.hh --- a/src/arch/alpha/tlb.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/alpha/tlb.hh Fri Feb 10 17:26:29 2012 -0600 @@ -144,6 +144,10 @@ Fault translateAtomic(RequestPtr req, ThreadContext *tc, Mode mode); void translateTiming(RequestPtr req, ThreadContext *tc, Translation *translation, Mode mode); + /** + * translateFunctional stub function for future CheckerCPU support + */ + Fault translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode); }; } // namespace AlphaISA diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/alpha/tlb.cc --- a/src/arch/alpha/tlb.cc Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/alpha/tlb.cc Fri Feb 10 17:26:29 2012 -0600 @@ -600,6 +600,13 @@ translation->finish(translateAtomic(req, tc, mode), req, tc, mode); } +Fault +TLB::translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode) +{ + panic("Not implemented\n"); + return NoFault; +} + } // namespace AlphaISA AlphaISA::TLB * diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/mips/tlb.hh --- a/src/arch/mips/tlb.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/mips/tlb.hh Fri Feb 10 17:26:29 2012 -0600 @@ -114,6 +114,11 @@ void translateTiming(RequestPtr req, ThreadContext *tc, Translation *translation, Mode mode); + /** Function stub for CheckerCPU compilation issues. MIPS does not + * support the Checker model at the moment. + */ + Fault translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode); + private: Fault translateInst(RequestPtr req, ThreadContext *tc); Fault translateData(RequestPtr req, ThreadContext *tc, bool write); diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/mips/tlb.cc --- a/src/arch/mips/tlb.cc Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/mips/tlb.cc Fri Feb 10 17:26:29 2012 -0600 @@ -339,6 +339,13 @@ translation->finish(translateAtomic(req, tc, mode), req, tc, mode); } +Fault +TLB::translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode) +{ + panic("Not implemented\n"); + return NoFault; +} + MipsISA::PTE & TLB::index(bool advance) diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/power/tlb.hh --- a/src/arch/power/tlb.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/power/tlb.hh Fri Feb 10 17:26:29 2012 -0600 @@ -160,6 +160,10 @@ Fault translateAtomic(RequestPtr req, ThreadContext *tc, Mode mode); void translateTiming(RequestPtr req, ThreadContext *tc, Translation *translation, Mode mode); + /** Stub function for CheckerCPU compilation support. Power ISA not + * supported by Checker at the moment + */ + Fault translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode); // Checkpointing void serialize(std::ostream &os); diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/power/tlb.cc --- a/src/arch/power/tlb.cc Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/power/tlb.cc Fri Feb 10 17:26:29 2012 -0600 @@ -326,6 +326,13 @@ translation->finish(translateAtomic(req, tc, mode), req, tc, mode); } +Fault +TLB::translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode) +{ + panic("Not implemented\n"); + return NoFault; +} + PowerISA::PTE & TLB::index(bool advance) { diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/sparc/tlb.hh --- a/src/arch/sparc/tlb.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/sparc/tlb.hh Fri Feb 10 17:26:29 2012 -0600 @@ -164,6 +164,10 @@ Fault translateAtomic(RequestPtr req, ThreadContext *tc, Mode mode); void translateTiming(RequestPtr req, ThreadContext *tc, Translation *translation, Mode mode); + /** Stub function for compilation support with CheckerCPU. SPARC ISA + * does not support the Checker model at the moment + */ + Fault translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode); Tick doMmuRegRead(ThreadContext *tc, Packet *pkt); Tick doMmuRegWrite(ThreadContext *tc, Packet *pkt); void GetTsbPtr(ThreadContext *tc, Addr addr, int ctx, Addr *ptrs); diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/sparc/tlb.cc --- a/src/arch/sparc/tlb.cc Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/sparc/tlb.cc Fri Feb 10 17:26:29 2012 -0600 @@ -841,6 +841,13 @@ translation->finish(translateAtomic(req, tc, mode), req, tc, mode); } +Fault +TLB::translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode) +{ + panic("Not implemented\n"); + return NoFault; +} + Tick TLB::doMmuRegRead(ThreadContext *tc, Packet *pkt) { diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/x86/tlb.hh --- a/src/arch/x86/tlb.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/x86/tlb.hh Fri Feb 10 17:26:29 2012 -0600 @@ -114,6 +114,10 @@ Fault translateAtomic(RequestPtr req, ThreadContext *tc, Mode mode); void translateTiming(RequestPtr req, ThreadContext *tc, Translation *translation, Mode mode); + /** Stub function for compilation support of CheckerCPU. x86 ISA does + * not support Checker model at the moment + */ + Fault translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode); TlbEntry * insert(Addr vpn, TlbEntry &entry); diff -r 4c858acb2863 -r ea1d5a2a3c35 src/arch/x86/tlb.cc --- a/src/arch/x86/tlb.cc Fri Feb 10 11:31:49 2012 -0600 +++ b/src/arch/x86/tlb.cc Fri Feb 10 17:26:29 2012 -0600 @@ -405,6 +405,13 @@ translation->finish(fault, req, tc, mode); } +Fault +TLB::translateFunctional(RequestPtr req, ThreadContext *tc, Mode mode) +{ + panic("Not implemented\n"); + return NoFault; +} + Walker * TLB::getWalker() { diff -r 4c858acb2863 -r ea1d5a2a3c35 src/cpu/checker/cpu.hh --- a/src/cpu/checker/cpu.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/cpu/checker/cpu.hh Fri Feb 10 17:26:29 2012 -0600 @@ -291,6 +291,20 @@ int reg_idx = si->destRegIdx(idx) - TheISA::Ctrl_Base_DepTag; return thread->setMiscReg(reg_idx, val); } + +#if THE_ISA == MIPS_ISA + uint64_t readRegOtherThread(int misc_reg) + { + panic("MIPS MT not defined for CheckerCPU.\n"); + return 0; + } + + void setRegOtherThread(int misc_reg, const TheISA::MiscReg &val) + { + panic("MIPS MT not defined for CheckerCPU.\n"); + } +#endif + ///////////////////////////////////////// void recordPCChange(const TheISA::PCState &val) diff -r 4c858acb2863 -r ea1d5a2a3c35 src/cpu/checker/cpu_impl.hh --- a/src/cpu/checker/cpu_impl.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/cpu/checker/cpu_impl.hh Fri Feb 10 17:26:29 2012 -0600 @@ -44,6 +44,7 @@ #include #include +#include "arch/isa_traits.hh" #include "arch/vtophys.hh" #include "base/refcnt.hh" #include "config/the_isa.hh" @@ -201,9 +202,9 @@ // maintain $r0 semantics thread->setIntReg(ZeroReg, 0); -#ifdef TARGET_ALPHA - thread->setFloatRegDouble(ZeroReg, 0.0); -#endif // TARGET_ALPHA +#if THE_ISA == ALPHA_ISA + thread->setFloatReg(ZeroReg, 0.0); +#endif // Check if any recent PC changes match up with anything we // expect to happen. This is mostly to check if traps or @@ -319,7 +320,9 @@ thread->pcState(pcState); instPtr = thread->decoder.decode(newMachInst, pcState.instAddr()); - machInst = newMachInst; +#if THE_ISA != X86_ISA + machInst = newMachInst; +#endif } else { fetchDone = false; fetchOffset += sizeof(TheISA::MachInst); @@ -475,7 +478,11 @@ } } - MachInst mi = static_cast(inst->staticInst->machInst); + + MachInst mi; +#if THE_ISA != X86_ISA + mi = static_cast(inst->staticInst->machInst); +#endif if (mi != machInst) { panic("%lli: Binary instructions do not match! Inst: %#x, " diff -r 4c858acb2863 -r ea1d5a2a3c35 src/cpu/inorder/thread_context.hh --- a/src/cpu/inorder/thread_context.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/cpu/inorder/thread_context.hh Fri Feb 10 17:26:29 2012 -0600 @@ -76,6 +76,12 @@ /** @TODO: PERF: Should we bind this to a pointer in constructor? */ TheISA::TLB *getDTBPtr() { return cpu->getDTBPtr(); } + /** Currently InOrder model does not support CheckerCPU, this is + * merely here for supporting compilation of gem5 with the Checker + * as a runtime option + */ + BaseCPU *getCheckerCpuPtr() { return NULL; } + Decoder *getDecoderPtr() { return cpu->getDecoderPtr(); } System *getSystemPtr() { return cpu->system; } @@ -215,6 +221,12 @@ void pcState(const TheISA::PCState &val) { cpu->pcState(val, thread->threadId()); } + /** Needs to be implemented for future CheckerCPU support. + * See O3CPU for examples on how to integrate Checker. + */ + void pcStateNoRecord(const TheISA::PCState &val) + {} + Addr instAddr() { return cpu->instAddr(thread->threadId()); } diff -r 4c858acb2863 -r ea1d5a2a3c35 src/cpu/o3/commit_impl.hh --- a/src/cpu/o3/commit_impl.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/cpu/o3/commit_impl.hh Fri Feb 10 17:26:29 2012 -0600 @@ -1335,7 +1335,7 @@ // // Pick off the software prefetches // -#ifdef TARGET_ALPHA +#if THE_ISA == ALPHA_ISA if (inst->isDataPrefetch()) { statComSwp[tid]++; } else { diff -r 4c858acb2863 -r ea1d5a2a3c35 src/cpu/o3/iew_impl.hh --- a/src/cpu/o3/iew_impl.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/cpu/o3/iew_impl.hh Fri Feb 10 17:26:29 2012 -0600 @@ -1617,11 +1617,11 @@ // // Pick off the software prefetches // -#ifdef TARGET_ALPHA +#if THE_ISA == ALPHA_ISA if (inst->isDataPrefetch()) iewExecutedSwp[tid]++; else - iewIewExecutedcutedInsts++; + iewExecutedInsts++; #else iewExecutedInsts++; #endif diff -r 4c858acb2863 -r ea1d5a2a3c35 src/cpu/ozone/back_end_impl.hh --- a/src/cpu/ozone/back_end_impl.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/cpu/ozone/back_end_impl.hh Fri Feb 10 17:26:29 2012 -0600 @@ -1731,7 +1731,7 @@ // // Pick off the software prefetches // -#ifdef TARGET_ALPHA +#ifdef THE_ISA == ALPHA_ISA if (inst->isDataPrefetch()) exe_swp[tid]++; else @@ -1766,7 +1766,7 @@ // // Pick off the software prefetches // -#ifdef TARGET_ALPHA +#if THE_ISA == ALPHA_ISA if (inst->isDataPrefetch()) { stat_com_swp[tid]++; } else { diff -r 4c858acb2863 -r ea1d5a2a3c35 src/cpu/ozone/lw_back_end_impl.hh --- a/src/cpu/ozone/lw_back_end_impl.hh Fri Feb 10 11:31:49 2012 -0600 +++ b/src/cpu/ozone/lw_back_end_impl.hh Fri Feb 10 17:26:29 2012 -0600 @@ -1472,7 +1472,7 @@ // // Pick off the software prefetches // -#ifdef TARGET_ALPHA +#ifdef THE_ISA == ALPHA_ISA if (inst->isDataPrefetch()) exeSwp[tid]++; else @@ -1512,7 +1512,7 @@ // // Pick off the software prefetches // -#ifdef TARGET_ALPHA +#ifdef THE_ISA == ALPHA_ISA if (inst->isDataPrefetch()) { statComSwp[tid]++; } else {