From 724dd71c06647255580200298ccb48c819391d69 Mon Sep 17 00:00:00 2001 From: "Bobby R. Bruce" Date: Wed, 9 Sep 2020 17:24:05 -0700 Subject: [PATCH] arch-mips: Replaced `BigEndianByteOrder` in MIPS The following change removed the `BigEndianByteOrder` enum and replaced it with `ByteOrder:big`: https://gem5-review.googlesource.com/c/public/gem5/+/33174 This change was not propogated to `src/arch/mips/isa/decoder.isa` and `src/arch/mips/isa/formats/mem.isa`, and therefore caused compilation errors. This caused the Nightly Build to fail: https://www.mail-archive.com/gem5-dev@gem5.org/msg35900.html This commit fixes this error. Change-Id: I3967eb9e9236a7a95318c17ca410b613b8473eed Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34255 Reviewed-by: Jason Lowe-Power Reviewed-by: Gabe Black Maintainer: Jason Lowe-Power Tested-by: kokoro --- src/arch/mips/isa/decoder.isa | 2 +- src/arch/mips/isa/formats/mem.isa | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/arch/mips/isa/decoder.isa b/src/arch/mips/isa/decoder.isa index d35fc1865..f62000ebe 100644 --- a/src/arch/mips/isa/decoder.isa +++ b/src/arch/mips/isa/decoder.isa @@ -1532,7 +1532,7 @@ decode OPCODE_HI default Unknown::unknown() { if (Rs<2:0> == 0) { Fd_ud = Fs_ud; } else if (Rs<2:0> == 4) { - if (GuestByteOrder == BigEndianByteOrder) + if (GuestByteOrder == ByteOrder::big) Fd_ud = Fs_ud<31:0> << 32 | Ft_ud<63:32>; else Fd_ud = Ft_ud<31:0> << 32 | Fs_ud<63:32>; diff --git a/src/arch/mips/isa/formats/mem.isa b/src/arch/mips/isa/formats/mem.isa index 4f6f2eea6..491dd0cc1 100644 --- a/src/arch/mips/isa/formats/mem.isa +++ b/src/arch/mips/isa/formats/mem.isa @@ -497,7 +497,7 @@ def format LoadUnalignedMemory(memacc_code, ea_code = {{ EA = (Rs + disp) & ~3; uint32_t mem_word = Mem_uw; uint32_t unalign_addr = Rs + disp; uint32_t byte_offset = unalign_addr & 3; - if (GuestByteOrder == BigEndianByteOrder) + if (GuestByteOrder == ByteOrder::big) byte_offset ^= 3; ''' @@ -515,7 +515,7 @@ def format StoreUnalignedMemory(memacc_code, ea_code = {{ EA = (Rs + disp) & ~3; uint32_t mem_word = 0; uint32_t unaligned_addr = Rs + disp; uint32_t byte_offset = unaligned_addr & 3; - if (GuestByteOrder == BigEndianByteOrder) + if (GuestByteOrder == ByteOrder::big) byte_offset ^= 3; fault = readMemAtomicLE(xc, traceData, EA, mem_word, memAccessFlags); ''' -- 2.30.2