From a0cff8b9458d22ab8123ab32ccc09da3d7ce0082 Mon Sep 17 00:00:00 2001 From: Ciro Santilli Date: Thu, 15 Oct 2020 10:04:05 +0100 Subject: [PATCH] arch-arm: move serialize and unserialize definition to cpp file Change-Id: I9ac64184d3fe36617f474a714b228b55b9a90976 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/36115 Reviewed-by: Giacomo Travaglini Maintainer: Giacomo Travaglini Tested-by: kokoro --- src/arch/arm/isa.cc | 16 ++++++++++++++++ src/arch/arm/isa.hh | 17 ++--------------- 2 files changed, 18 insertions(+), 15 deletions(-) diff --git a/src/arch/arm/isa.cc b/src/arch/arm/isa.cc index 217f432ac..9b1cde31f 100644 --- a/src/arch/arm/isa.cc +++ b/src/arch/arm/isa.cc @@ -2350,6 +2350,22 @@ ISA::zeroSveVecRegUpperPart(VecRegContainer &vc, unsigned eCount) } } +void +ISA::serialize(CheckpointOut &cp) const +{ + DPRINTF(Checkpoint, "Serializing Arm Misc Registers\n"); + SERIALIZE_ARRAY(miscRegs, NUM_PHYS_MISCREGS); +} + +void +ISA::unserialize(CheckpointIn &cp) +{ + DPRINTF(Checkpoint, "Unserializing Arm Misc Registers\n"); + UNSERIALIZE_ARRAY(miscRegs, NUM_PHYS_MISCREGS); + CPSR tmp_cpsr = miscRegs[MISCREG_CPSR]; + updateRegMap(tmp_cpsr); +} + void ISA::addressTranslation64(TLB::ArmTranslationType tran_type, BaseTLB::Mode mode, Request::Flags flags, RegVal val) diff --git a/src/arch/arm/isa.hh b/src/arch/arm/isa.hh index 4a824edce..6b9dd3c70 100644 --- a/src/arch/arm/isa.hh +++ b/src/arch/arm/isa.hh @@ -810,21 +810,8 @@ namespace ArmISA static void zeroSveVecRegUpperPart(VecRegContainer &vc, unsigned eCount); - void - serialize(CheckpointOut &cp) const override - { - DPRINTF(Checkpoint, "Serializing Arm Misc Registers\n"); - SERIALIZE_ARRAY(miscRegs, NUM_PHYS_MISCREGS); - } - - void - unserialize(CheckpointIn &cp) override - { - DPRINTF(Checkpoint, "Unserializing Arm Misc Registers\n"); - UNSERIALIZE_ARRAY(miscRegs, NUM_PHYS_MISCREGS); - CPSR tmp_cpsr = miscRegs[MISCREG_CPSR]; - updateRegMap(tmp_cpsr); - } + void serialize(CheckpointOut &cp) const override; + void unserialize(CheckpointIn &cp) override; void startup() override; -- 2.30.2