sim: Use the system and OS to get endianness.
authorGabe Black <gabeblack@google.com>
Tue, 29 Oct 2019 22:50:48 +0000 (15:50 -0700)
committerGabe Black <gabeblack@google.com>
Wed, 30 Oct 2019 22:29:23 +0000 (22:29 +0000)
commit75d496c6b2c65ada974be3f9445ae7fb94ccef10
tree9346fc434ef681bbeb5ddf1ed84e11c5f4920152
parent607df7e656304f0a2a4ca811acd758ee21b9642e
sim: Use the system and OS to get endianness.

This converts the syscall implementations to either use the
OS::byteOrder constant or, if that's not available, the system's
getGuestByteOrder() accessor, to determine the byte order, instead of
relying on TheISA to provide the correct accessor.

Change-Id: Idf7b02ee8d73990224ceac9a5efaec91a5ebf79f
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/22364
Reviewed-by: Brandon Potter <Brandon.Potter@amd.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/sim/syscall_emul.cc
src/sim/syscall_emul.hh