whoops inverted logic on qemu endian set
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Thu, 27 May 2021 10:30:37 +0000 (11:30 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Thu, 27 May 2021 10:30:37 +0000 (11:30 +0100)
src/openpower/decoder/isa/pypowersim.py

index 9bdec27b07e6e0dc429c722025760e6b86ce89f4..52074b8bcf0cc27423df3b0c5bad2bad98160195 100644 (file)
@@ -219,8 +219,8 @@ def run_tst(args, generator, qemu,
             except KeyError:  # indicates instruction not in imem: stop
                 _pc, _insn = (None, None)
             qemu.step()
-            if _pc and not simulator.halted:
-                qemu.set_endian(True)
+            if not _pc or simulator.halted:
+                qemu.set_endian(False)
             qemu_register_compare(simulator, qemu, range(32), range(32))
             if _pc is None:
                 break