Match CR size on ISACaller mtcrf test case
authorCesar Strauss <cestrauss@gmail.com>
Sun, 25 Apr 2021 13:50:39 +0000 (10:50 -0300)
committerCesar Strauss <cestrauss@gmail.com>
Sun, 25 Apr 2021 13:57:41 +0000 (10:57 -0300)
The underlying register for CR seems to be 64 bits for some reason. See:
https://git.libre-soc.org/?p=openpower-isa.git;a=blob;f=src/openpower/decoder/isa/caller.py;h=2f9dfa8746625f74fccaf9cd8a86f5503837009d;hb=HEAD#l495

src/openpower/decoder/isa/test_caller.py

index 00856352cef7f93b49c11f34264c3c162a8b5e37..ce934609b23be8199a010d9eb51ac3c2564ce8be 100644 (file)
@@ -317,7 +317,7 @@ class DecoderTestCase(FHDLTestCase):
             print("cr%d", sim.crl[i])
             self.assertTrue(SelectableInt(expected, 4) == sim.crl[i])
             # check CR itself
-            self.assertEqual(sim.cr, SelectableInt(expected << ((7-i)*4), 32))
+            self.assertEqual(sim.cr, SelectableInt(expected << ((7-i)*4), 64))
 
     def run_tst_program(self, prog, initial_regs=[0] * 32):
         simulator = run_tst(prog, initial_regs)