thread_context.hh revision 8229
12686Sksewell@umich.edu/*
22100SN/A * Copyright (c) 2006 The Regents of The University of Michigan
35254Sksewell@umich.edu * All rights reserved.
45254Sksewell@umich.edu *
55254Sksewell@umich.edu * Redistribution and use in source and binary forms, with or without
65254Sksewell@umich.edu * modification, are permitted provided that the following conditions are
75254Sksewell@umich.edu * met: redistributions of source code must retain the above copyright
85254Sksewell@umich.edu * notice, this list of conditions and the following disclaimer;
95254Sksewell@umich.edu * redistributions in binary form must reproduce the above copyright
105254Sksewell@umich.edu * notice, this list of conditions and the following disclaimer in the
115254Sksewell@umich.edu * documentation and/or other materials provided with the distribution;
125254Sksewell@umich.edu * neither the name of the copyright holders nor the names of its
135254Sksewell@umich.edu * contributors may be used to endorse or promote products derived from
145254Sksewell@umich.edu * this software without specific prior written permission.
155254Sksewell@umich.edu *
165254Sksewell@umich.edu * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
175254Sksewell@umich.edu * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
185254Sksewell@umich.edu * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
195254Sksewell@umich.edu * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
205254Sksewell@umich.edu * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
215254Sksewell@umich.edu * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
225254Sksewell@umich.edu * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
235254Sksewell@umich.edu * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
245254Sksewell@umich.edu * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
255254Sksewell@umich.edu * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
265254Sksewell@umich.edu * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
275254Sksewell@umich.edu *
285254Sksewell@umich.edu * Authors: Kevin Lim
295254Sksewell@umich.edu */
305254Sksewell@umich.edu
315254Sksewell@umich.edu#ifndef __CPU_THREAD_CONTEXT_HH__
322706Sksewell@umich.edu#define __CPU_THREAD_CONTEXT_HH__
332022SN/A
342022SN/A#include <iostream>
352043SN/A#include <string>
362024SN/A
372024SN/A#include "arch/registers.hh"
382043SN/A#include "arch/types.hh"
392686Sksewell@umich.edu#include "base/types.hh"
404661Sksewell@umich.edu#include "config/full_system.hh"
412022SN/A#include "config/the_isa.hh"
422083SN/A
432686Sksewell@umich.edu// @todo: Figure out a more architecture independent way to obtain the ITB and
442101SN/A// DTB pointers.
452043SN/Anamespace TheISA
462043SN/A{
472101SN/A    class TLB;
482101SN/A}
492686Sksewell@umich.educlass BaseCPU;
502686Sksewell@umich.educlass Checkpoint;
512101SN/Aclass EndQuiesceEvent;
522101SN/Aclass TranslatingPort;
532101SN/Aclass FunctionalPort;
542046SN/Aclass VirtualPort;
552686Sksewell@umich.educlass Process;
562686Sksewell@umich.educlass System;
572686Sksewell@umich.edunamespace TheISA {
582470SN/A    namespace Kernel {
592686Sksewell@umich.edu        class Statistics;
604661Sksewell@umich.edu    };
615222Sksewell@umich.edu};
625222Sksewell@umich.edu
632686Sksewell@umich.edu/**
642686Sksewell@umich.edu * ThreadContext is the external interface to all thread state for
652470SN/A * anything outside of the CPU. It provides all accessor methods to
662241SN/A * state that might be needed by external objects, ranging from
672101SN/A * register values to things such as kernel stats. It is an abstract
682495SN/A * base class; the CPU can create its own ThreadContext by either
692495SN/A * deriving from it, or using the templated ProxyThreadContext.
702495SN/A *
712101SN/A * The ThreadContext is slightly different than the ExecContext.  The
722495SN/A * ThreadContext provides access to an individual thread's state; an
732495SN/A * ExecContext provides ISA access to the CPU (meaning it is
742495SN/A * implicitly multithreaded on SMT systems).  Additionally the
752101SN/A * ThreadState is an abstract class that exactly defines the
762101SN/A * interface; the ExecContext is a more implicit interface that must
772495SN/A * be implemented so that the ISA can access whatever state it needs.
782495SN/A */
792495SN/Aclass ThreadContext
802495SN/A{
812495SN/A  protected:
822495SN/A    typedef TheISA::MachInst MachInst;
832495SN/A    typedef TheISA::IntReg IntReg;
842495SN/A    typedef TheISA::FloatReg FloatReg;
852495SN/A    typedef TheISA::FloatRegBits FloatRegBits;
862495SN/A    typedef TheISA::MiscReg MiscReg;
872495SN/A  public:
882495SN/A
892495SN/A    enum Status
902101SN/A    {
912101SN/A        /// Running.  Instructions should be executed only when
922101SN/A        /// the context is in this state.
932101SN/A        Active,
942101SN/A
952101SN/A        /// Temporarily inactive.  Entered while waiting for
962101SN/A        /// synchronization, etc.
972101SN/A        Suspended,
982101SN/A
992101SN/A        /// Permanently shut down.  Entered when target executes
1002495SN/A        /// m5exit pseudo-instruction.  When all contexts enter
1012495SN/A        /// this state, the simulation will terminate.
1022495SN/A        Halted
1032495SN/A    };
1042495SN/A
1052495SN/A    virtual ~ThreadContext() { };
1062495SN/A
1072495SN/A    virtual BaseCPU *getCpuPtr() = 0;
1082495SN/A
1092495SN/A    virtual int cpuId() = 0;
1102495SN/A
1112495SN/A    virtual int threadId() = 0;
1122495SN/A
1132495SN/A    virtual void setThreadId(int id) = 0;
1142495SN/A
1152043SN/A    virtual int contextId() = 0;
1162043SN/A
1172025SN/A    virtual void setContextId(int id) = 0;
1182043SN/A
1192686Sksewell@umich.edu    virtual TheISA::TLB *getITBPtr() = 0;
1202686Sksewell@umich.edu
1212123SN/A    virtual TheISA::TLB *getDTBPtr() = 0;
1222101SN/A
1236376Sgblack@eecs.umich.edu    virtual System *getSystemPtr() = 0;
1246376Sgblack@eecs.umich.edu
1256376Sgblack@eecs.umich.edu#if FULL_SYSTEM
1266376Sgblack@eecs.umich.edu    virtual TheISA::Kernel::Statistics *getKernelStats() = 0;
1276376Sgblack@eecs.umich.edu
1286376Sgblack@eecs.umich.edu    virtual FunctionalPort *getPhysPort() = 0;
1296376Sgblack@eecs.umich.edu
1306376Sgblack@eecs.umich.edu    virtual VirtualPort *getVirtPort() = 0;
1316376Sgblack@eecs.umich.edu
1326376Sgblack@eecs.umich.edu    virtual void connectMemPorts(ThreadContext *tc) = 0;
1336376Sgblack@eecs.umich.edu#else
1346376Sgblack@eecs.umich.edu    virtual TranslatingPort *getMemPort() = 0;
1356376Sgblack@eecs.umich.edu
1366376Sgblack@eecs.umich.edu    virtual Process *getProcessPtr() = 0;
1376376Sgblack@eecs.umich.edu#endif
1386376Sgblack@eecs.umich.edu
1392101SN/A    virtual Status status() const = 0;
1402042SN/A
1412101SN/A    virtual void setStatus(Status new_status) = 0;
1424661Sksewell@umich.edu
1432686Sksewell@umich.edu    /// Set the status to Active.  Optional delay indicates number of
1444661Sksewell@umich.edu    /// cycles to wait before beginning execution.
1452101SN/A    virtual void activate(int delay = 1) = 0;
1462101SN/A
1472042SN/A    /// Set the status to Suspended.
1482101SN/A    virtual void suspend(int delay = 0) = 0;
1492686Sksewell@umich.edu
1502686Sksewell@umich.edu    /// Set the status to Halted.
1515222Sksewell@umich.edu    virtual void halt(int delay = 0) = 0;
1526036Sksewell@umich.edu
1535222Sksewell@umich.edu#if FULL_SYSTEM
1545222Sksewell@umich.edu    virtual void dumpFuncProfile() = 0;
1555222Sksewell@umich.edu#endif
1562965Sksewell@umich.edu
1576037Sksewell@umich.edu    virtual void takeOverFrom(ThreadContext *old_context) = 0;
1585222Sksewell@umich.edu
1592686Sksewell@umich.edu    virtual void regStats(const std::string &name) = 0;
1605222Sksewell@umich.edu
1612101SN/A    virtual void serialize(std::ostream &os) = 0;
1622083SN/A    virtual void unserialize(Checkpoint *cp, const std::string &section) = 0;
1632043SN/A
1642025SN/A#if FULL_SYSTEM
1652043SN/A    virtual EndQuiesceEvent *getQuiesceEvent() = 0;
1665222Sksewell@umich.edu
1674661Sksewell@umich.edu    // Not necessarily the best location for these...
1685222Sksewell@umich.edu    // Having an extra function just to read these is obnoxious
1694661Sksewell@umich.edu    virtual Tick readLastActivate() = 0;
1702083SN/A    virtual Tick readLastSuspend() = 0;
1712025SN/A
1722043SN/A    virtual void profileClear() = 0;
1734661Sksewell@umich.edu    virtual void profileSample() = 0;
1745222Sksewell@umich.edu#endif
1755222Sksewell@umich.edu
1764661Sksewell@umich.edu    virtual void copyArchRegs(ThreadContext *tc) = 0;
1774661Sksewell@umich.edu
1782686Sksewell@umich.edu    virtual void clearArchRegs() = 0;
1794661Sksewell@umich.edu
1804661Sksewell@umich.edu    //
1814661Sksewell@umich.edu    // New accessors for new decoder.
1824661Sksewell@umich.edu    //
1835222Sksewell@umich.edu    virtual uint64_t readIntReg(int reg_idx) = 0;
1845222Sksewell@umich.edu
1854661Sksewell@umich.edu    virtual FloatReg readFloatReg(int reg_idx) = 0;
1864661Sksewell@umich.edu
1874661Sksewell@umich.edu    virtual FloatRegBits readFloatRegBits(int reg_idx) = 0;
1884661Sksewell@umich.edu
1895222Sksewell@umich.edu    virtual void setIntReg(int reg_idx, uint64_t val) = 0;
1902101SN/A
1912084SN/A    virtual void setFloatReg(int reg_idx, FloatReg val) = 0;
1922025SN/A
1932495SN/A    virtual void setFloatRegBits(int reg_idx, FloatRegBits val) = 0;
1942495SN/A
1952495SN/A    virtual TheISA::PCState pcState() = 0;
1965222Sksewell@umich.edu
1975222Sksewell@umich.edu    virtual void pcState(const TheISA::PCState &val) = 0;
1985222Sksewell@umich.edu
1995222Sksewell@umich.edu    virtual Addr instAddr() = 0;
2005222Sksewell@umich.edu
2015222Sksewell@umich.edu    virtual Addr nextInstAddr() = 0;
2025222Sksewell@umich.edu
2035222Sksewell@umich.edu    virtual MicroPC microPC() = 0;
2045222Sksewell@umich.edu
2055222Sksewell@umich.edu    virtual MiscReg readMiscRegNoEffect(int misc_reg) = 0;
2065222Sksewell@umich.edu
2075222Sksewell@umich.edu    virtual MiscReg readMiscReg(int misc_reg) = 0;
2085222Sksewell@umich.edu
2095222Sksewell@umich.edu    virtual void setMiscRegNoEffect(int misc_reg, const MiscReg &val) = 0;
2105222Sksewell@umich.edu
2115222Sksewell@umich.edu    virtual void setMiscReg(int misc_reg, const MiscReg &val) = 0;
2125222Sksewell@umich.edu
2135222Sksewell@umich.edu    virtual int flattenIntIndex(int reg) = 0;
2145222Sksewell@umich.edu    virtual int flattenFloatIndex(int reg) = 0;
2155222Sksewell@umich.edu
2162495SN/A    virtual uint64_t
2175222Sksewell@umich.edu    readRegOtherThread(int misc_reg, ThreadID tid)
2185222Sksewell@umich.edu    {
2195222Sksewell@umich.edu        return 0;
2205222Sksewell@umich.edu    }
2215222Sksewell@umich.edu
2225222Sksewell@umich.edu    virtual void
2235222Sksewell@umich.edu    setRegOtherThread(int misc_reg, const MiscReg &val, ThreadID tid)
2245222Sksewell@umich.edu    {
2255222Sksewell@umich.edu    }
2265222Sksewell@umich.edu
2275222Sksewell@umich.edu    // Also not necessarily the best location for these two.  Hopefully will go
2285222Sksewell@umich.edu    // away once we decide upon where st cond failures goes.
2295222Sksewell@umich.edu    virtual unsigned readStCondFailures() = 0;
2305222Sksewell@umich.edu
2315222Sksewell@umich.edu    virtual void setStCondFailures(unsigned sc_failures) = 0;
2322495SN/A
2332495SN/A    // Only really makes sense for old CPU model.  Still could be useful though.
2342495SN/A    virtual bool misspeculating() = 0;
2352495SN/A
2362495SN/A#if !FULL_SYSTEM
2372495SN/A    // Same with st cond failures.
2382101SN/A    virtual Counter readFuncExeInst() = 0;
2392043SN/A
2402025SN/A    virtual void syscall(int64_t callnum) = 0;
2412495SN/A
2422495SN/A    // This function exits the thread context in the CPU and returns
2432495SN/A    // 1 if the CPU has no more active threads (meaning it's OK to exit);
2442495SN/A    // Used in syscall-emulation mode when a  thread calls the exit syscall.
2452495SN/A    virtual int exit() { return 1; };
2462495SN/A#endif
2472101SN/A
2482084SN/A    /** function to compare two thread contexts (for debugging) */
2492024SN/A    static void compare(ThreadContext *one, ThreadContext *two);
2502043SN/A};
2512239SN/A
2522239SN/A/**
2532101SN/A * ProxyThreadContext class that provides a way to implement a
2542101SN/A * ThreadContext without having to derive from it. ThreadContext is an
2555222Sksewell@umich.edu * abstract class, so anything that derives from it and uses its
2562101SN/A * interface will pay the overhead of virtual function calls.  This
2572101SN/A * class is created to enable a user-defined Thread object to be used
2582101SN/A * wherever ThreadContexts are used, without paying the overhead of
2592043SN/A * virtual function calls when it is used by itself.  See
2602043SN/A * simple_thread.hh for an example of this.
2612025SN/A */
2622043SN/Atemplate <class TC>
2632043SN/Aclass ProxyThreadContext : public ThreadContext
2642101SN/A{
2652101SN/A  public:
2662101SN/A    ProxyThreadContext(TC *actual_tc)
2672686Sksewell@umich.edu    { actualTC = actual_tc; }
2682686Sksewell@umich.edu
2692101SN/A  private:
2702043SN/A    TC *actualTC;
2712025SN/A
2722043SN/A  public:
2735222Sksewell@umich.edu
2745222Sksewell@umich.edu    BaseCPU *getCpuPtr() { return actualTC->getCpuPtr(); }
2755222Sksewell@umich.edu
2765222Sksewell@umich.edu    int cpuId() { return actualTC->cpuId(); }
2775222Sksewell@umich.edu
2785222Sksewell@umich.edu    int threadId() { return actualTC->threadId(); }
2795222Sksewell@umich.edu
2802101SN/A    void setThreadId(int id) { return actualTC->setThreadId(id); }
2812043SN/A
2822043SN/A    int contextId() { return actualTC->contextId(); }
2832043SN/A
2842101SN/A    void setContextId(int id) { actualTC->setContextId(id); }
2852686Sksewell@umich.edu
2862686Sksewell@umich.edu    TheISA::TLB *getITBPtr() { return actualTC->getITBPtr(); }
2872686Sksewell@umich.edu
2882686Sksewell@umich.edu    TheISA::TLB *getDTBPtr() { return actualTC->getDTBPtr(); }
2892686Sksewell@umich.edu
2902686Sksewell@umich.edu    System *getSystemPtr() { return actualTC->getSystemPtr(); }
2912686Sksewell@umich.edu
2922101SN/A#if FULL_SYSTEM
2932043SN/A    TheISA::Kernel::Statistics *getKernelStats()
2942043SN/A    { return actualTC->getKernelStats(); }
2952043SN/A
2964661Sksewell@umich.edu    FunctionalPort *getPhysPort() { return actualTC->getPhysPort(); }
2974661Sksewell@umich.edu
2982101SN/A    VirtualPort *getVirtPort() { return actualTC->getVirtPort(); }
2992101SN/A
3002101SN/A    void connectMemPorts(ThreadContext *tc) { actualTC->connectMemPorts(tc); }
3012043SN/A#else
3022043SN/A    TranslatingPort *getMemPort() { return actualTC->getMemPort(); }
3032043SN/A
3042123SN/A    Process *getProcessPtr() { return actualTC->getProcessPtr(); }
3052239SN/A#endif
3062686Sksewell@umich.edu
3072686Sksewell@umich.edu    Status status() const { return actualTC->status(); }
3082043SN/A
3092043SN/A    void setStatus(Status new_status) { actualTC->setStatus(new_status); }
3102100SN/A
3112686Sksewell@umich.edu    /// Set the status to Active.  Optional delay indicates number of
3122686Sksewell@umich.edu    /// cycles to wait before beginning execution.
3132686Sksewell@umich.edu    void activate(int delay = 1) { actualTC->activate(delay); }
3142686Sksewell@umich.edu
3152239SN/A    /// Set the status to Suspended.
3162686Sksewell@umich.edu    void suspend(int delay = 0) { actualTC->suspend(); }
3172686Sksewell@umich.edu
3182043SN/A    /// Set the status to Halted.
3192084SN/A    void halt(int delay = 0) { actualTC->halt(); }
3202024SN/A
3212101SN/A#if FULL_SYSTEM
3222686Sksewell@umich.edu    void dumpFuncProfile() { actualTC->dumpFuncProfile(); }
3235222Sksewell@umich.edu#endif
3245222Sksewell@umich.edu
3255222Sksewell@umich.edu    void takeOverFrom(ThreadContext *oldContext)
3265222Sksewell@umich.edu    { actualTC->takeOverFrom(oldContext); }
3275222Sksewell@umich.edu
3285222Sksewell@umich.edu    void regStats(const std::string &name) { actualTC->regStats(name); }
3295222Sksewell@umich.edu
3305222Sksewell@umich.edu    void serialize(std::ostream &os) { actualTC->serialize(os); }
3315222Sksewell@umich.edu    void unserialize(Checkpoint *cp, const std::string &section)
3325222Sksewell@umich.edu    { actualTC->unserialize(cp, section); }
3335222Sksewell@umich.edu
3345222Sksewell@umich.edu#if FULL_SYSTEM
3355222Sksewell@umich.edu    EndQuiesceEvent *getQuiesceEvent() { return actualTC->getQuiesceEvent(); }
3365222Sksewell@umich.edu
3375222Sksewell@umich.edu    Tick readLastActivate() { return actualTC->readLastActivate(); }
3385222Sksewell@umich.edu    Tick readLastSuspend() { return actualTC->readLastSuspend(); }
3395222Sksewell@umich.edu
3405222Sksewell@umich.edu    void profileClear() { return actualTC->profileClear(); }
3415222Sksewell@umich.edu    void profileSample() { return actualTC->profileSample(); }
3422239SN/A#endif
3432239SN/A
3444661Sksewell@umich.edu    // @todo: Do I need this?
3454661Sksewell@umich.edu    void copyArchRegs(ThreadContext *tc) { actualTC->copyArchRegs(tc); }
3464661Sksewell@umich.edu
3474661Sksewell@umich.edu    void clearArchRegs() { actualTC->clearArchRegs(); }
3484661Sksewell@umich.edu
3494661Sksewell@umich.edu    //
3504661Sksewell@umich.edu    // New accessors for new decoder.
3514661Sksewell@umich.edu    //
3524661Sksewell@umich.edu    uint64_t readIntReg(int reg_idx)
3532495SN/A    { return actualTC->readIntReg(reg_idx); }
3542495SN/A
3552495SN/A    FloatReg readFloatReg(int reg_idx)
3562495SN/A    { return actualTC->readFloatReg(reg_idx); }
3572495SN/A
3582495SN/A    FloatRegBits readFloatRegBits(int reg_idx)
3592495SN/A    { return actualTC->readFloatRegBits(reg_idx); }
3602084SN/A
3612084SN/A    void setIntReg(int reg_idx, uint64_t val)
3622024SN/A    { actualTC->setIntReg(reg_idx, val); }
3632101SN/A
3642101SN/A    void setFloatReg(int reg_idx, FloatReg val)
3652101SN/A    { actualTC->setFloatReg(reg_idx, val); }
3662101SN/A
3675222Sksewell@umich.edu    void setFloatRegBits(int reg_idx, FloatRegBits val)
3686376Sgblack@eecs.umich.edu    { actualTC->setFloatRegBits(reg_idx, val); }
3696376Sgblack@eecs.umich.edu
3706376Sgblack@eecs.umich.edu    TheISA::PCState pcState() { return actualTC->pcState(); }
3716376Sgblack@eecs.umich.edu
3726376Sgblack@eecs.umich.edu    void pcState(const TheISA::PCState &val) { actualTC->pcState(val); }
3736376Sgblack@eecs.umich.edu
3746376Sgblack@eecs.umich.edu    Addr instAddr() { return actualTC->instAddr(); }
3756376Sgblack@eecs.umich.edu    Addr nextInstAddr() { return actualTC->nextInstAddr(); }
3766376Sgblack@eecs.umich.edu    MicroPC microPC() { return actualTC->microPC(); }
3776376Sgblack@eecs.umich.edu
3786376Sgblack@eecs.umich.edu    bool readPredicate() { return actualTC->readPredicate(); }
3796376Sgblack@eecs.umich.edu
3806376Sgblack@eecs.umich.edu    void setPredicate(bool val)
3816376Sgblack@eecs.umich.edu    { actualTC->setPredicate(val); }
3826376Sgblack@eecs.umich.edu
3836376Sgblack@eecs.umich.edu    MiscReg readMiscRegNoEffect(int misc_reg)
3846376Sgblack@eecs.umich.edu    { return actualTC->readMiscRegNoEffect(misc_reg); }
3856376Sgblack@eecs.umich.edu
3866376Sgblack@eecs.umich.edu    MiscReg readMiscReg(int misc_reg)
3876376Sgblack@eecs.umich.edu    { return actualTC->readMiscReg(misc_reg); }
3886376Sgblack@eecs.umich.edu
3896376Sgblack@eecs.umich.edu    void setMiscRegNoEffect(int misc_reg, const MiscReg &val)
3906376Sgblack@eecs.umich.edu    { return actualTC->setMiscRegNoEffect(misc_reg, val); }
3916376Sgblack@eecs.umich.edu
3926376Sgblack@eecs.umich.edu    void setMiscReg(int misc_reg, const MiscReg &val)
3936376Sgblack@eecs.umich.edu    { return actualTC->setMiscReg(misc_reg, val); }
3945222Sksewell@umich.edu
3955222Sksewell@umich.edu    int flattenIntIndex(int reg)
3965222Sksewell@umich.edu    { return actualTC->flattenIntIndex(reg); }
3975222Sksewell@umich.edu
3985222Sksewell@umich.edu    int flattenFloatIndex(int reg)
3995222Sksewell@umich.edu    { return actualTC->flattenFloatIndex(reg); }
4004661Sksewell@umich.edu
4014661Sksewell@umich.edu    unsigned readStCondFailures()
4026376Sgblack@eecs.umich.edu    { return actualTC->readStCondFailures(); }
4036376Sgblack@eecs.umich.edu
4046376Sgblack@eecs.umich.edu    void setStCondFailures(unsigned sc_failures)
4056376Sgblack@eecs.umich.edu    { actualTC->setStCondFailures(sc_failures); }
4064661Sksewell@umich.edu
4074661Sksewell@umich.edu    // @todo: Fix this!
4084661Sksewell@umich.edu    bool misspeculating() { return actualTC->misspeculating(); }
4094661Sksewell@umich.edu
4104661Sksewell@umich.edu#if !FULL_SYSTEM
4114661Sksewell@umich.edu    void syscall(int64_t callnum)
4124661Sksewell@umich.edu    { actualTC->syscall(callnum); }
4134661Sksewell@umich.edu
4144661Sksewell@umich.edu    Counter readFuncExeInst() { return actualTC->readFuncExeInst(); }
4154661Sksewell@umich.edu#endif
4164661Sksewell@umich.edu};
4174661Sksewell@umich.edu
4184661Sksewell@umich.edu#endif
4194661Sksewell@umich.edu