From: Gabe Black Date: Mon, 27 Feb 2006 21:46:00 +0000 (-0500) Subject: Moved the _stat for MachineCheckFault and AlignmentFault into the isa specific classe... X-Git-Tag: m5_2.0_beta1~87^2~60 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=36b2d9815e32781aba1f51acb0b89cdd4f3e2da9;p=gem5.git Moved the _stat for MachineCheckFault and AlignmentFault into the isa specific classes to prevent instantiation of the generic classes. --HG-- extra : convert_revision : 0378261342df008c2bf6d260295ef21b15f119a8 --- diff --git a/arch/alpha/faults.cc b/arch/alpha/faults.cc index 5033f9fcd..99365f8d2 100644 --- a/arch/alpha/faults.cc +++ b/arch/alpha/faults.cc @@ -36,8 +36,10 @@ FaultVect AlphaFault::_vect = 0x0000; FaultStat AlphaFault::_stat; FaultVect AlphaMachineCheckFault::_vect = 0x0401; +FaultStat AlphaMachineCheckFault::_stat; FaultVect AlphaAlignmentFault::_vect = 0x0301; +FaultStat AlphaAlignmentFault::_stat; FaultName ResetFault::_name = "reset"; FaultVect ResetFault::_vect = 0x0001; diff --git a/arch/alpha/faults.hh b/arch/alpha/faults.hh index fedbadd4d..f8cb44017 100644 --- a/arch/alpha/faults.hh +++ b/arch/alpha/faults.hh @@ -54,16 +54,20 @@ class AlphaMachineCheckFault : public MachineCheckFault { private: static FaultVect _vect; + static FaultStat _stat; public: FaultVect vect() {return _vect;} + FaultStat & stat() {return _stat;} }; class AlphaAlignmentFault : public AlignmentFault { private: static FaultVect _vect; + static FaultStat _stat; public: FaultVect vect() {return _vect;} + FaultStat & stat() {return _stat;} }; static inline Fault genMachineCheckFault() diff --git a/sim/faults.cc b/sim/faults.cc index 17efaf1c4..78bfc8092 100644 --- a/sim/faults.cc +++ b/sim/faults.cc @@ -29,7 +29,5 @@ #include "sim/faults.hh" FaultName MachineCheckFault::_name = "mchk"; -FaultStat MachineCheckFault::_stat; FaultName AlignmentFault::_name = "unalign"; -FaultStat AlignmentFault::_stat; diff --git a/sim/faults.hh b/sim/faults.hh index e4880f820..d0bf78815 100644 --- a/sim/faults.hh +++ b/sim/faults.hh @@ -71,10 +71,8 @@ class MachineCheckFault : public FaultBase { private: static FaultName _name; - static FaultStat _stat; public: FaultName name() {return _name;} - FaultStat & stat() {return _stat;} bool isMachineCheckFault() {return true;} }; @@ -82,10 +80,8 @@ class AlignmentFault : public FaultBase { private: static FaultName _name; - static FaultStat _stat; public: FaultName name() {return _name;} - FaultStat & stat() {return _stat;} bool isAlignmentFault() {return true;} };