arch-arm: Add destRegIdxArr arrays to TME instructions

This is needed as the base StaticInst class is no longer holding the
index array and it is up to the derived class to allocate the
storage depending on the number of registers used

Change-Id: I389e39a7e09d31f370d63a6e61fe6ee3faaac7db
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/40375
Reviewed-by: Gabe Black <gabe.black@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
Giacomo Travaglini
2021-01-26 10:54:30 +00:00
parent fc4caa6ad0
commit cb437cf29f
2 changed files with 20 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2020 ARM Limited
* Copyright (c) 2020-2021 ARM Limited
* All rights reserved
*
* The license below extends only to copyright in the software and shall
@@ -116,6 +116,12 @@ MicroTfence64::completeAcc(PacketPtr pkt, ExecContext *xc,
Tstart64::Tstart64(ExtMachInst machInst, IntRegIndex _dest)
: TmeRegNone64("tstart", machInst, MemReadOp, _dest)
{
setRegIdxArrays(
nullptr,
reinterpret_cast<RegIdArrayPtr>(
&std::remove_pointer_t<decltype(this)>::destRegIdxArr));
;
_numSrcRegs = 0;
_numDestRegs = 0;
_numFPDestRegs = 0;
@@ -144,6 +150,12 @@ Tstart64::execute(
Ttest64::Ttest64(ExtMachInst machInst, IntRegIndex _dest)
: TmeRegNone64("ttest", machInst, MemReadOp, _dest)
{
setRegIdxArrays(
nullptr,
reinterpret_cast<RegIdArrayPtr>(
&std::remove_pointer_t<decltype(this)>::destRegIdxArr));
;
_numSrcRegs = 0;
_numDestRegs = 0;
_numFPDestRegs = 0;

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2020 ARM Limited
* Copyright (c) 2020-2021 ARM Limited
* All rights reserved
*
* The license below extends only to copyright in the software and shall
@@ -97,6 +97,9 @@ class TmeRegNone64 : public ArmISA::ArmStaticInst
class Tstart64 : public TmeRegNone64
{
private:
RegId destRegIdxArr[1];
public:
Tstart64(ArmISA::ExtMachInst, ArmISA::IntRegIndex);
@@ -107,6 +110,9 @@ class Tstart64 : public TmeRegNone64
class Ttest64 : public TmeRegNone64
{
private:
RegId destRegIdxArr[1];
public:
Ttest64(ArmISA::ExtMachInst, ArmISA::IntRegIndex);