arch: Explicitly specify the endianness in the generic mem helpers.
This avoids using the accessors which automatically assume an endianness, requiring the memory system to know what the guest ISA is. Change-Id: I863fa4116f00e77b801a2f8ea2fbe34e7f55fd5f Reviewed-on: https://gem5-review.googlesource.com/c/13461 Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com> Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
This commit is contained in:
@@ -66,7 +66,7 @@ template <class MemT>
|
||||
void
|
||||
getMem(PacketPtr pkt, MemT &mem, Trace::InstRecord *traceData)
|
||||
{
|
||||
mem = pkt->get<MemT>();
|
||||
mem = pkt->get<MemT>(TheISA::GuestByteOrder);
|
||||
if (traceData)
|
||||
traceData->setData(mem);
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ handlePseudoInst(ThreadContext *xc, Packet *pkt)
|
||||
assert((offset >> 16) == 0);
|
||||
ret = PseudoInst::pseudoInst(xc, func, subfunc);
|
||||
if (pkt->isRead())
|
||||
pkt->set(ret);
|
||||
pkt->set(ret, TheISA::GuestByteOrder);
|
||||
}
|
||||
|
||||
Cycles
|
||||
|
||||
Reference in New Issue
Block a user