faults.hh revision 5268
12131SN/A/*
25268Sksewell@umich.edu * Copyright (c) 2003-2005 The Regents of The University of Michigan
35224Sksewell@umich.edu * Copyright (c) 2007 MIPS Technologies, Inc.
45224Sksewell@umich.edu * All rights reserved.
52131SN/A *
65224Sksewell@umich.edu * Redistribution and use in source and binary forms, with or without
75224Sksewell@umich.edu * modification, are permitted provided that the following conditions are
85224Sksewell@umich.edu * met: redistributions of source code must retain the above copyright
95224Sksewell@umich.edu * notice, this list of conditions and the following disclaimer;
105224Sksewell@umich.edu * redistributions in binary form must reproduce the above copyright
115224Sksewell@umich.edu * notice, this list of conditions and the following disclaimer in the
125224Sksewell@umich.edu * documentation and/or other materials provided with the distribution;
135224Sksewell@umich.edu * neither the name of the copyright holders nor the names of its
145224Sksewell@umich.edu * contributors may be used to endorse or promote products derived from
155224Sksewell@umich.edu * this software without specific prior written permission.
162131SN/A *
175224Sksewell@umich.edu * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
185224Sksewell@umich.edu * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
195224Sksewell@umich.edu * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
205224Sksewell@umich.edu * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
215224Sksewell@umich.edu * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
225224Sksewell@umich.edu * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
235224Sksewell@umich.edu * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
245224Sksewell@umich.edu * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
255224Sksewell@umich.edu * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
265224Sksewell@umich.edu * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
275224Sksewell@umich.edu * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
282665Ssaidi@eecs.umich.edu *
295224Sksewell@umich.edu * Authors: Gabe Black
305224Sksewell@umich.edu *          Korey Sewell
315222Sksewell@umich.edu *          Jaidev Patwardhan
322131SN/A */
332131SN/A
342239SN/A#ifndef __MIPS_FAULTS_HH__
352239SN/A#define __MIPS_FAULTS_HH__
362131SN/A
372131SN/A#include "sim/faults.hh"
382447SN/A
392447SN/A// The design of the "name" and "vect" functions is in sim/faults.hh
402447SN/A
412447SN/Anamespace MipsISA
422447SN/A{
432447SN/Atypedef const Addr FaultVect;
442131SN/A
452239SN/Aclass MipsFault : public FaultBase
462131SN/A{
472447SN/A  protected:
482447SN/A    virtual bool skipFaultingInstruction() {return false;}
492447SN/A    virtual bool setRestartAddress() {return true;}
502131SN/A  public:
515222Sksewell@umich.edu    Addr BadVAddr;
525222Sksewell@umich.edu    Addr EntryHi_Asid;
535222Sksewell@umich.edu    Addr EntryHi_VPN2;
545222Sksewell@umich.edu    Addr EntryHi_VPN2X;
555222Sksewell@umich.edu    Addr Context_BadVPN2;
562447SN/A#if FULL_SYSTEM
575222Sksewell@umich.edu  void invoke(ThreadContext * tc) {};
585222Sksewell@umich.edu  void setExceptionState(ThreadContext *,uint8_t);
595222Sksewell@umich.edu  void setHandlerPC(Addr,ThreadContext *);
602447SN/A#endif
612447SN/A    virtual FaultVect vect() = 0;
622447SN/A    virtual FaultStat & countStat() = 0;
632131SN/A};
642131SN/A
652447SN/Aclass MachineCheckFault : public MipsFault
662131SN/A{
672447SN/A  private:
682447SN/A    static FaultName _name;
692447SN/A    static FaultVect _vect;
702447SN/A    static FaultStat _count;
712131SN/A  public:
724695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
732447SN/A    FaultVect vect() {return _vect;}
742447SN/A    FaultStat & countStat() {return _count;}
755222Sksewell@umich.edu    bool isMachineCheckFault() {return true;}
765222Sksewell@umich.edu};
775222Sksewell@umich.edu
785222Sksewell@umich.educlass NonMaskableInterrupt : public MipsFault
795222Sksewell@umich.edu{
805222Sksewell@umich.edu  private:
815222Sksewell@umich.edu    static FaultName _name;
825222Sksewell@umich.edu    static FaultVect _vect;
835222Sksewell@umich.edu    static FaultStat _count;
845222Sksewell@umich.edu  public:
855222Sksewell@umich.edu    FaultName name() const {return _name;}
865222Sksewell@umich.edu    FaultVect vect() {return _vect;}
875222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
885222Sksewell@umich.edu    bool isNonMaskableInterrupt() {return true;}
892447SN/A};
902131SN/A
912447SN/Aclass AlignmentFault : public MipsFault
922131SN/A{
932447SN/A  private:
942447SN/A    static FaultName _name;
952447SN/A    static FaultVect _vect;
962447SN/A    static FaultStat _count;
972131SN/A  public:
984695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
992447SN/A    FaultVect vect() {return _vect;}
1002447SN/A    FaultStat & countStat() {return _count;}
1015222Sksewell@umich.edu    bool isAlignmentFault() {return true;}
1022447SN/A};
1032131SN/A
1045222Sksewell@umich.educlass AddressErrorFault : public MipsFault
1055222Sksewell@umich.edu{
1065222Sksewell@umich.edu  private:
1075222Sksewell@umich.edu    static FaultName _name;
1085222Sksewell@umich.edu    static FaultVect _vect;
1095222Sksewell@umich.edu    static FaultStat _count;
1105222Sksewell@umich.edu  public:
1115222Sksewell@umich.edu    FaultName name() const {return _name;}
1125222Sksewell@umich.edu    FaultVect vect() {return _vect;}
1135222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
1145222Sksewell@umich.edu#if FULL_SYSTEM
1155222Sksewell@umich.edu    void invoke(ThreadContext * tc);
1165222Sksewell@umich.edu#endif
1175222Sksewell@umich.edu
1185222Sksewell@umich.edu};
1195222Sksewell@umich.educlass StoreAddressErrorFault : public MipsFault
1205222Sksewell@umich.edu{
1215222Sksewell@umich.edu  private:
1225222Sksewell@umich.edu    static FaultName _name;
1235222Sksewell@umich.edu    static FaultVect _vect;
1245222Sksewell@umich.edu    static FaultStat _count;
1255222Sksewell@umich.edu  public:
1265222Sksewell@umich.edu    FaultName name() const {return _name;}
1275222Sksewell@umich.edu    FaultVect vect() {return _vect;}
1285222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
1295222Sksewell@umich.edu#if FULL_SYSTEM
1305222Sksewell@umich.edu    void invoke(ThreadContext * tc);
1315222Sksewell@umich.edu#endif
1325222Sksewell@umich.edu
1335222Sksewell@umich.edu};
1344661Sksewell@umich.educlass UnimplementedOpcodeFault : public MipsFault
1354661Sksewell@umich.edu{
1364661Sksewell@umich.edu  private:
1374661Sksewell@umich.edu    static FaultName _name;
1384661Sksewell@umich.edu    static FaultVect _vect;
1394661Sksewell@umich.edu    static FaultStat _count;
1404661Sksewell@umich.edu  public:
1414695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
1424661Sksewell@umich.edu    FaultVect vect() {return _vect;}
1434661Sksewell@umich.edu    FaultStat & countStat() {return _count;}
1444661Sksewell@umich.edu};
1454661Sksewell@umich.edu
1462447SN/A
1475222Sksewell@umich.educlass TLBRefillIFetchFault : public MipsFault
1482447SN/A{
1492447SN/A  private:
1505222Sksewell@umich.edu    Addr vaddr;
1512447SN/A    static FaultName _name;
1522447SN/A    static FaultVect _vect;
1532447SN/A    static FaultStat _count;
1542131SN/A  public:
1554695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
1562447SN/A    FaultVect vect() {return _vect;}
1572447SN/A    FaultStat & countStat() {return _count;}
1584661Sksewell@umich.edu    void invoke(ThreadContext * tc);
1592447SN/A};
1605222Sksewell@umich.educlass TLBInvalidIFetchFault : public MipsFault
1614661Sksewell@umich.edu{
1624661Sksewell@umich.edu  private:
1635222Sksewell@umich.edu    Addr vaddr;
1644661Sksewell@umich.edu    static FaultName _name;
1654661Sksewell@umich.edu    static FaultVect _vect;
1664661Sksewell@umich.edu    static FaultStat _count;
1674661Sksewell@umich.edu  public:
1684695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
1694661Sksewell@umich.edu    FaultVect vect() {return _vect;}
1704661Sksewell@umich.edu    FaultStat & countStat() {return _count;}
1714661Sksewell@umich.edu    void invoke(ThreadContext * tc);
1724661Sksewell@umich.edu};
1734661Sksewell@umich.edu
1742447SN/Aclass NDtbMissFault : public MipsFault
1752131SN/A{
1762447SN/A  private:
1772447SN/A    static FaultName _name;
1782447SN/A    static FaultVect _vect;
1792447SN/A    static FaultStat _count;
1802131SN/A  public:
1814695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
1822447SN/A    FaultVect vect() {return _vect;}
1832447SN/A    FaultStat & countStat() {return _count;}
1842447SN/A};
1852131SN/A
1862447SN/Aclass PDtbMissFault : public MipsFault
1872131SN/A{
1882447SN/A  private:
1892447SN/A    static FaultName _name;
1902447SN/A    static FaultVect _vect;
1912447SN/A    static FaultStat _count;
1922131SN/A  public:
1934695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
1942447SN/A    FaultVect vect() {return _vect;}
1952447SN/A    FaultStat & countStat() {return _count;}
1962447SN/A};
1972131SN/A
1982447SN/Aclass DtbPageFault : public MipsFault
1992131SN/A{
2002447SN/A  private:
2012447SN/A    static FaultName _name;
2022447SN/A    static FaultVect _vect;
2032447SN/A    static FaultStat _count;
2042131SN/A  public:
2054695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
2062447SN/A    FaultVect vect() {return _vect;}
2072447SN/A    FaultStat & countStat() {return _count;}
2082447SN/A};
2092131SN/A
2102447SN/Aclass DtbAcvFault : public MipsFault
2112131SN/A{
2122447SN/A  private:
2132447SN/A    static FaultName _name;
2142447SN/A    static FaultVect _vect;
2152447SN/A    static FaultStat _count;
2162131SN/A  public:
2174695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
2182447SN/A    FaultVect vect() {return _vect;}
2192447SN/A    FaultStat & countStat() {return _count;}
2202447SN/A};
2212131SN/A
2225222Sksewell@umich.educlass CacheErrorFault : public MipsFault
2235222Sksewell@umich.edu{
2245222Sksewell@umich.edu  private:
2255222Sksewell@umich.edu    Addr vaddr;
2265222Sksewell@umich.edu    static FaultName _name;
2275222Sksewell@umich.edu    static FaultVect _vect;
2285222Sksewell@umich.edu    static FaultStat _count;
2295222Sksewell@umich.edu  public:
2305222Sksewell@umich.edu    FaultName name() const {return _name;}
2315222Sksewell@umich.edu    FaultVect vect() {return _vect;}
2325222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
2335222Sksewell@umich.edu    void invoke(ThreadContext * tc);
2345222Sksewell@umich.edu};
2355222Sksewell@umich.edu
2365222Sksewell@umich.edu
2375222Sksewell@umich.edu
2385222Sksewell@umich.edu
2395222Sksewell@umich.edustatic inline Fault genMachineCheckFault()
2405222Sksewell@umich.edu{
2415222Sksewell@umich.edu    return new MachineCheckFault;
2425222Sksewell@umich.edu}
2435222Sksewell@umich.edu
2445222Sksewell@umich.edustatic inline Fault genAlignmentFault()
2455222Sksewell@umich.edu{
2465222Sksewell@umich.edu    return new AlignmentFault;
2475222Sksewell@umich.edu}
2485222Sksewell@umich.edu
2495222Sksewell@umich.educlass ResetFault : public MipsFault
2505222Sksewell@umich.edu{
2515222Sksewell@umich.edu  private:
2525222Sksewell@umich.edu    static FaultName _name;
2535222Sksewell@umich.edu    static FaultVect _vect;
2545222Sksewell@umich.edu    static FaultStat _count;
2555222Sksewell@umich.edu  public:
2565222Sksewell@umich.edu    FaultName name() const {return _name;}
2575222Sksewell@umich.edu    FaultVect vect() {return _vect;}
2585222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
2595222Sksewell@umich.edu    void invoke(ThreadContext * tc);
2605222Sksewell@umich.edu
2615222Sksewell@umich.edu};
2625222Sksewell@umich.educlass SystemCallFault : public MipsFault
2635222Sksewell@umich.edu{
2645222Sksewell@umich.edu  private:
2655222Sksewell@umich.edu    static FaultName _name;
2665222Sksewell@umich.edu    static FaultVect _vect;
2675222Sksewell@umich.edu    static FaultStat _count;
2685222Sksewell@umich.edu  public:
2695222Sksewell@umich.edu    FaultName name() const {return _name;}
2705222Sksewell@umich.edu    FaultVect vect() {return _vect;}
2715222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
2725222Sksewell@umich.edu    void invoke(ThreadContext * tc);
2735222Sksewell@umich.edu};
2745222Sksewell@umich.edu
2755222Sksewell@umich.educlass SoftResetFault : public MipsFault
2765222Sksewell@umich.edu{
2775222Sksewell@umich.edu  private:
2785222Sksewell@umich.edu    static FaultName _name;
2795222Sksewell@umich.edu    static FaultVect _vect;
2805222Sksewell@umich.edu    static FaultStat _count;
2815222Sksewell@umich.edu  public:
2825222Sksewell@umich.edu    FaultName name() const {return _name;}
2835222Sksewell@umich.edu    FaultVect vect() {return _vect;}
2845222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
2855222Sksewell@umich.edu    void invoke(ThreadContext * tc);
2865222Sksewell@umich.edu};
2875222Sksewell@umich.educlass DebugSingleStep : public MipsFault
2885222Sksewell@umich.edu{
2895222Sksewell@umich.edu  private:
2905222Sksewell@umich.edu    static FaultName _name;
2915222Sksewell@umich.edu    static FaultVect _vect;
2925222Sksewell@umich.edu    static FaultStat _count;
2935222Sksewell@umich.edu  public:
2945222Sksewell@umich.edu    FaultName name() const {return _name;}
2955222Sksewell@umich.edu    FaultVect vect() {return _vect;}
2965222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
2975222Sksewell@umich.edu    void invoke(ThreadContext * tc);
2985222Sksewell@umich.edu};
2995222Sksewell@umich.educlass DebugInterrupt : public MipsFault
3005222Sksewell@umich.edu{
3015222Sksewell@umich.edu  private:
3025222Sksewell@umich.edu    static FaultName _name;
3035222Sksewell@umich.edu    static FaultVect _vect;
3045222Sksewell@umich.edu    static FaultStat _count;
3055222Sksewell@umich.edu  public:
3065222Sksewell@umich.edu    FaultName name() const {return _name;}
3075222Sksewell@umich.edu    FaultVect vect() {return _vect;}
3085222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
3095222Sksewell@umich.edu    void invoke(ThreadContext * tc);
3105222Sksewell@umich.edu};
3115222Sksewell@umich.edu
3125222Sksewell@umich.educlass CoprocessorUnusableFault : public MipsFault
3135222Sksewell@umich.edu{
3145222Sksewell@umich.edu  private:
3155222Sksewell@umich.edu    static FaultName _name;
3165222Sksewell@umich.edu    static FaultVect _vect;
3175222Sksewell@umich.edu    static FaultStat _count;
3185222Sksewell@umich.edu    int coProcID;
3195222Sksewell@umich.edu  public:
3205222Sksewell@umich.edu    FaultName name() const {return _name;}
3215222Sksewell@umich.edu    FaultVect vect() {return _vect;}
3225222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
3235222Sksewell@umich.edu    void invoke(ThreadContext * tc);
3245222Sksewell@umich.edu    CoprocessorUnusableFault(int _procid){ coProcID = _procid;}
3255222Sksewell@umich.edu};
3265222Sksewell@umich.edu
3275222Sksewell@umich.educlass ReservedInstructionFault : public MipsFault
3285222Sksewell@umich.edu{
3295222Sksewell@umich.edu  private:
3305222Sksewell@umich.edu    static FaultName _name;
3315222Sksewell@umich.edu    static FaultVect _vect;
3325222Sksewell@umich.edu    static FaultStat _count;
3335222Sksewell@umich.edu  public:
3345222Sksewell@umich.edu    FaultName name() const {return _name;}
3355222Sksewell@umich.edu    FaultVect vect() {return _vect;}
3365222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
3375222Sksewell@umich.edu    void invoke(ThreadContext * tc);
3385222Sksewell@umich.edu};
3395222Sksewell@umich.edu
3405222Sksewell@umich.educlass ThreadFault : public MipsFault
3415222Sksewell@umich.edu{
3425222Sksewell@umich.edu  private:
3435222Sksewell@umich.edu    static FaultName _name;
3445222Sksewell@umich.edu    static FaultVect _vect;
3455222Sksewell@umich.edu    static FaultStat _count;
3465222Sksewell@umich.edu  public:
3475222Sksewell@umich.edu    FaultName name() const {return _name;}
3485222Sksewell@umich.edu    FaultVect vect() {return _vect;}
3495222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
3505222Sksewell@umich.edu    void invoke(ThreadContext * tc);
3515222Sksewell@umich.edu};
3525222Sksewell@umich.edu
3535222Sksewell@umich.edu
3545222Sksewell@umich.educlass ArithmeticFault : public MipsFault
3555222Sksewell@umich.edu{
3565222Sksewell@umich.edu  protected:
3575222Sksewell@umich.edu    bool skipFaultingInstruction() {return true;}
3585222Sksewell@umich.edu  private:
3595222Sksewell@umich.edu    static FaultName _name;
3605222Sksewell@umich.edu    static FaultVect _vect;
3615222Sksewell@umich.edu    static FaultStat _count;
3625222Sksewell@umich.edu  public:
3635222Sksewell@umich.edu    FaultName name() const {return _name;}
3645222Sksewell@umich.edu    FaultVect vect() {return _vect;}
3655222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
3665222Sksewell@umich.edu#if FULL_SYSTEM
3675222Sksewell@umich.edu    void invoke(ThreadContext * tc);
3685222Sksewell@umich.edu#endif
3695222Sksewell@umich.edu};
3705222Sksewell@umich.edu
3715222Sksewell@umich.educlass InterruptFault : public MipsFault
3725222Sksewell@umich.edu{
3735222Sksewell@umich.edu  protected:
3745222Sksewell@umich.edu    bool setRestartAddress() {return false;}
3755222Sksewell@umich.edu  private:
3765222Sksewell@umich.edu    static FaultName _name;
3775222Sksewell@umich.edu    static FaultVect _vect;
3785222Sksewell@umich.edu    static FaultStat _count;
3795222Sksewell@umich.edu  public:
3805222Sksewell@umich.edu    FaultName name() const {return _name;}
3815222Sksewell@umich.edu    FaultVect vect() {return _vect;}
3825222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
3835222Sksewell@umich.edu
3845222Sksewell@umich.edu#if FULL_SYSTEM
3855222Sksewell@umich.edu    void invoke(ThreadContext * tc);
3865222Sksewell@umich.edu#endif
3875222Sksewell@umich.edu
3885222Sksewell@umich.edu    //void invoke(ThreadContext * tc);
3895222Sksewell@umich.edu};
3905222Sksewell@umich.edu
3915222Sksewell@umich.educlass TrapFault : public MipsFault
3925222Sksewell@umich.edu{
3935222Sksewell@umich.edu  private:
3945222Sksewell@umich.edu    static FaultName _name;
3955222Sksewell@umich.edu    static FaultVect _vect;
3965222Sksewell@umich.edu    static FaultStat _count;
3975222Sksewell@umich.edu  public:
3985222Sksewell@umich.edu    FaultName name() const {return _name;}
3995222Sksewell@umich.edu    FaultVect vect() {return _vect;}
4005222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
4015222Sksewell@umich.edu#if FULL_SYSTEM
4025222Sksewell@umich.edu    void invoke(ThreadContext * tc);
4035222Sksewell@umich.edu#endif
4045222Sksewell@umich.edu};
4055222Sksewell@umich.edu
4065222Sksewell@umich.educlass BreakpointFault : public MipsFault
4075222Sksewell@umich.edu{
4085222Sksewell@umich.edu  private:
4095222Sksewell@umich.edu    static FaultName _name;
4105222Sksewell@umich.edu    static FaultVect _vect;
4115222Sksewell@umich.edu    static FaultStat _count;
4125222Sksewell@umich.edu  public:
4135222Sksewell@umich.edu    FaultName name() const {return _name;}
4145222Sksewell@umich.edu    FaultVect vect() {return _vect;}
4155222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
4165222Sksewell@umich.edu#if FULL_SYSTEM
4175222Sksewell@umich.edu    void invoke(ThreadContext * tc);
4185222Sksewell@umich.edu#endif
4195222Sksewell@umich.edu};
4205222Sksewell@umich.edu
4215222Sksewell@umich.educlass ItbRefillFault : public MipsFault
4225222Sksewell@umich.edu{
4235222Sksewell@umich.edu  private:
4245222Sksewell@umich.edu    static FaultName _name;
4255222Sksewell@umich.edu    static FaultVect _vect;
4265222Sksewell@umich.edu    static FaultStat _count;
4275222Sksewell@umich.edu  public:
4285222Sksewell@umich.edu    FaultName name() const {return _name;}
4295222Sksewell@umich.edu    FaultVect vect() {return _vect;}
4305222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
4315222Sksewell@umich.edu#if FULL_SYSTEM
4325222Sksewell@umich.edu    void invoke(ThreadContext * tc);
4335222Sksewell@umich.edu#endif
4345222Sksewell@umich.edu};
4355222Sksewell@umich.educlass DtbRefillFault : public MipsFault
4365222Sksewell@umich.edu{
4375222Sksewell@umich.edu  private:
4385222Sksewell@umich.edu    static FaultName _name;
4395222Sksewell@umich.edu    static FaultVect _vect;
4405222Sksewell@umich.edu    static FaultStat _count;
4415222Sksewell@umich.edu  public:
4425222Sksewell@umich.edu    FaultName name() const {return _name;}
4435222Sksewell@umich.edu    FaultVect vect() {return _vect;}
4445222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
4455222Sksewell@umich.edu#if FULL_SYSTEM
4465222Sksewell@umich.edu    void invoke(ThreadContext * tc);
4475222Sksewell@umich.edu#endif
4485222Sksewell@umich.edu};
4495222Sksewell@umich.edu
4505222Sksewell@umich.educlass ItbPageFault : public MipsFault
4515222Sksewell@umich.edu{
4525222Sksewell@umich.edu  private:
4535222Sksewell@umich.edu    static FaultName _name;
4545222Sksewell@umich.edu    static FaultVect _vect;
4555222Sksewell@umich.edu    static FaultStat _count;
4565222Sksewell@umich.edu  public:
4575222Sksewell@umich.edu    FaultName name() const {return _name;}
4585222Sksewell@umich.edu    FaultVect vect() {return _vect;}
4595222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
4605222Sksewell@umich.edu#if FULL_SYSTEM
4615222Sksewell@umich.edu    void invoke(ThreadContext * tc);
4625222Sksewell@umich.edu#endif
4635222Sksewell@umich.edu};
4645222Sksewell@umich.edu
4655222Sksewell@umich.educlass ItbInvalidFault : public MipsFault
4665222Sksewell@umich.edu{
4675222Sksewell@umich.edu  private:
4685222Sksewell@umich.edu    static FaultName _name;
4695222Sksewell@umich.edu    static FaultVect _vect;
4705222Sksewell@umich.edu    static FaultStat _count;
4715222Sksewell@umich.edu  public:
4725222Sksewell@umich.edu    FaultName name() const {return _name;}
4735222Sksewell@umich.edu    FaultVect vect() {return _vect;}
4745222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
4755222Sksewell@umich.edu#if FULL_SYSTEM
4765222Sksewell@umich.edu    void invoke(ThreadContext * tc);
4775222Sksewell@umich.edu#endif
4785222Sksewell@umich.edu
4795222Sksewell@umich.edu};
4805222Sksewell@umich.educlass TLBModifiedFault : public MipsFault
4815222Sksewell@umich.edu{
4825222Sksewell@umich.edu  private:
4835222Sksewell@umich.edu    static FaultName _name;
4845222Sksewell@umich.edu    static FaultVect _vect;
4855222Sksewell@umich.edu    static FaultStat _count;
4865222Sksewell@umich.edu  public:
4875222Sksewell@umich.edu    FaultName name() const {return _name;}
4885222Sksewell@umich.edu    FaultVect vect() {return _vect;}
4895222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
4905222Sksewell@umich.edu#if FULL_SYSTEM
4915222Sksewell@umich.edu    void invoke(ThreadContext * tc);
4925222Sksewell@umich.edu#endif
4935222Sksewell@umich.edu
4945222Sksewell@umich.edu};
4955222Sksewell@umich.edu
4965222Sksewell@umich.educlass DtbInvalidFault : public MipsFault
4975222Sksewell@umich.edu{
4985222Sksewell@umich.edu  private:
4995222Sksewell@umich.edu    static FaultName _name;
5005222Sksewell@umich.edu    static FaultVect _vect;
5015222Sksewell@umich.edu    static FaultStat _count;
5025222Sksewell@umich.edu  public:
5035222Sksewell@umich.edu    FaultName name() const {return _name;}
5045222Sksewell@umich.edu    FaultVect vect() {return _vect;}
5055222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
5065222Sksewell@umich.edu#if FULL_SYSTEM
5075222Sksewell@umich.edu    void invoke(ThreadContext * tc);
5085222Sksewell@umich.edu#endif
5095222Sksewell@umich.edu
5105222Sksewell@umich.edu};
5115222Sksewell@umich.edu
5125222Sksewell@umich.educlass FloatEnableFault : public MipsFault
5135222Sksewell@umich.edu{
5145222Sksewell@umich.edu  private:
5155222Sksewell@umich.edu    static FaultName _name;
5165222Sksewell@umich.edu    static FaultVect _vect;
5175222Sksewell@umich.edu    static FaultStat _count;
5185222Sksewell@umich.edu  public:
5195222Sksewell@umich.edu    FaultName name() const {return _name;}
5205222Sksewell@umich.edu    FaultVect vect() {return _vect;}
5215222Sksewell@umich.edu    FaultStat & countStat() {return _count;}
5225222Sksewell@umich.edu};
5235222Sksewell@umich.edu
5242447SN/Aclass ItbMissFault : public MipsFault
5252131SN/A{
5262447SN/A  private:
5272447SN/A    static FaultName _name;
5282447SN/A    static FaultVect _vect;
5292447SN/A    static FaultStat _count;
5302131SN/A  public:
5314695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
5322447SN/A    FaultVect vect() {return _vect;}
5332447SN/A    FaultStat & countStat() {return _count;}
5342447SN/A};
5352131SN/A
5362447SN/Aclass ItbAcvFault : public MipsFault
5372131SN/A{
5382447SN/A  private:
5392447SN/A    static FaultName _name;
5402447SN/A    static FaultVect _vect;
5412447SN/A    static FaultStat _count;
5422131SN/A  public:
5434695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
5442447SN/A    FaultVect vect() {return _vect;}
5452447SN/A    FaultStat & countStat() {return _count;}
5462447SN/A};
5472131SN/A
5482447SN/Aclass IntegerOverflowFault : public MipsFault
5492447SN/A{
5502447SN/A  private:
5512447SN/A    static FaultName _name;
5522447SN/A    static FaultVect _vect;
5532447SN/A    static FaultStat _count;
5542447SN/A  public:
5554695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
5562447SN/A    FaultVect vect() {return _vect;}
5572447SN/A    FaultStat & countStat() {return _count;}
5582447SN/A};
5592447SN/A
5604661Sksewell@umich.educlass DspStateDisabledFault : public MipsFault
5614661Sksewell@umich.edu{
5624661Sksewell@umich.edu  private:
5634661Sksewell@umich.edu    static FaultName _name;
5644661Sksewell@umich.edu    static FaultVect _vect;
5654661Sksewell@umich.edu    static FaultStat _count;
5664661Sksewell@umich.edu  public:
5674695Sgblack@eecs.umich.edu    FaultName name() const {return _name;}
5684661Sksewell@umich.edu    FaultVect vect() {return _vect;}
5694661Sksewell@umich.edu    FaultStat & countStat() {return _count;}
5704661Sksewell@umich.edu    void invoke(ThreadContext * tc);
5714661Sksewell@umich.edu};
5724661Sksewell@umich.edu
5732447SN/A} // MipsISA namespace
5742131SN/A
5755222Sksewell@umich.edu#endif // __MIPS_FAULTS_HH__
576