Gabe Black has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/38382 )

Change subject: cpu: Remove the default, globally sized index arrays from StaticInst.
......................................................................

cpu: Remove the default, globally sized index arrays from StaticInst.

All ISAs now allocate their own arrays in all their instructions, making
these arrays unnecessary.

Change-Id: Ie2bc5d7a2903e07703dddd809505cdaaf6c578f5
---
M src/cpu/static_inst.hh
1 file changed, 1 insertion(+), 12 deletions(-)



diff --git a/src/cpu/static_inst.hh b/src/cpu/static_inst.hh
index e5d9753..25a49b3 100644
--- a/src/cpu/static_inst.hh
+++ b/src/cpu/static_inst.hh
@@ -88,20 +88,13 @@
     /// Binary extended machine instruction type.
     typedef TheISA::ExtMachInst ExtMachInst;

-    enum {
-        MaxInstSrcRegs = TheISA::MaxInstSrcRegs,        //< Max source regs
-        MaxInstDestRegs = TheISA::MaxInstDestRegs       //< Max dest regs
-    };
-
     using RegIdArrayPtr = RegId (StaticInst:: *)[];

   private:
     /// See srcRegIdx().
-    RegId _srcRegIdx[MaxInstSrcRegs];
     RegIdArrayPtr _srcRegIdxPtr = nullptr;

     /// See destRegIdx().
-    RegId _destRegIdx[MaxInstDestRegs];
     RegIdArrayPtr _destRegIdxPtr = nullptr;

   protected:
@@ -309,11 +302,7 @@
     /// the fields that are meaningful for the particular
     /// instruction.
StaticInst(const char *_mnemonic, ExtMachInst _machInst, OpClass __opClass)
-        : _srcRegIdxPtr(
-                reinterpret_cast<RegIdArrayPtr>(&StaticInst::_srcRegIdx)),
-          _destRegIdxPtr(
-                reinterpret_cast<RegIdArrayPtr>(&StaticInst::_destRegIdx)),
-          _opClass(__opClass),
+        : _opClass(__opClass),
           _numSrcRegs(0), _numDestRegs(0), _numFPDestRegs(0),
           _numIntDestRegs(0), _numCCDestRegs(0), _numVecDestRegs(0),
_numVecElemDestRegs(0), _numVecPredDestRegs(0), machInst(_machInst),

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/38382
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: Ie2bc5d7a2903e07703dddd809505cdaaf6c578f5
Gerrit-Change-Number: 38382
Gerrit-PatchSet: 1
Gerrit-Owner: Gabe Black <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to