Khalique Ahmed has uploaded this change for review. (
https://gem5-review.googlesource.com/8581
Change subject: sparc: Fix FS Checkpoint loading
......................................................................
sparc: Fix FS Checkpoint loading
Proposed changes to SPARC FS simulation, testing indicates that checkpoints
are now loaded correctly with the following command: build/SPARC/gem5.opt
configs/example/fs.py -r 1
Change-Id: Icd44f01a74c41a78828ef6fd7b661e584bdb6966
---
M src/arch/sparc/isa.cc
M src/arch/sparc/tlb.cc
M src/dev/sparc/mm_disk.cc
M src/dev/sparc/mm_disk.hh
4 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/src/arch/sparc/isa.cc b/src/arch/sparc/isa.cc
index b8906e9..f6b941e 100644
--- a/src/arch/sparc/isa.cc
+++ b/src/arch/sparc/isa.cc
@@ -654,12 +654,12 @@
SERIALIZE_ARRAY(tstate,MaxTL);
SERIALIZE_ARRAY(tt,MaxTL);
SERIALIZE_SCALAR(tba);
- SERIALIZE_SCALAR((uint16_t)pstate);
+ SERIALIZE_SCALAR(pstate);
SERIALIZE_SCALAR(tl);
SERIALIZE_SCALAR(pil);
SERIALIZE_SCALAR(cwp);
SERIALIZE_SCALAR(gl);
- SERIALIZE_SCALAR((uint64_t)hpstate);
+ SERIALIZE_SCALAR(hpstate);
SERIALIZE_ARRAY(htstate,MaxTL);
SERIALIZE_SCALAR(hintp);
SERIALIZE_SCALAR(htba);
diff --git a/src/arch/sparc/tlb.cc b/src/arch/sparc/tlb.cc
index 997bfe9..f4564c6 100644
--- a/src/arch/sparc/tlb.cc
+++ b/src/arch/sparc/tlb.cc
@@ -1367,12 +1367,12 @@
SERIALIZE_SCALAR(cx_config);
SERIALIZE_SCALAR(sfsr);
SERIALIZE_SCALAR(tag_access);
+ SERIALIZE_SCALAR(sfar);
for (int x = 0; x < size; x++) {
ScopedCheckpointSection sec(cp, csprintf("PTE%d", x));
tlb[x].serialize(cp);
}
- SERIALIZE_SCALAR(sfar);
}
void
diff --git a/src/dev/sparc/mm_disk.cc b/src/dev/sparc/mm_disk.cc
index a6ce1d0..acf1b78 100644
--- a/src/dev/sparc/mm_disk.cc
+++ b/src/dev/sparc/mm_disk.cc
@@ -184,6 +184,13 @@
}
}
+void
+MmDisk::unserialize(CheckpointIn &cp)
+{
+ // default function overriden in order to prevent unserialization of
+ // ClockedObject's params
+}
+
MmDisk *
MmDiskParams::create()
{
diff --git a/src/dev/sparc/mm_disk.hh b/src/dev/sparc/mm_disk.hh
index 8572d53..3453f2a 100644
--- a/src/dev/sparc/mm_disk.hh
+++ b/src/dev/sparc/mm_disk.hh
@@ -62,6 +62,7 @@
Tick write(PacketPtr pkt) override;
void serialize(CheckpointOut &cp) const override;
+ void unserialize(CheckpointIn &cp) override;
};
#endif //__DEV_SPARC_MM_DISK_HH__
--
To view, visit https://gem5-review.googlesource.com/8581
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-Change-Id: Icd44f01a74c41a78828ef6fd7b661e584bdb6966
Gerrit-Change-Number: 8581
Gerrit-PatchSet: 1
Gerrit-Owner: Khalique Ahmed <khalique...@gmail.com>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev