Add expected state to case_1_regression for extsb in alu_cases unit test
authorR Veera Kumar <vklr@vkten.in>
Thu, 11 Nov 2021 02:55:54 +0000 (08:25 +0530)
committerR Veera Kumar <vklr@vkten.in>
Thu, 11 Nov 2021 02:55:54 +0000 (08:25 +0530)
src/openpower/test/alu/alu_cases.py

index c023ee062a489a986a2c3d2a1fb422067e433da1..bd43ecc39135f99a40a6b544431fa837faf33aef 100644 (file)
@@ -40,7 +40,10 @@ class ALUTestCase(TestAccumulatorBase):
         lst = [f"extsb 3, 1"]
         initial_regs = [0] * 32
         initial_regs[1] = 0x7f9497aaff900ea0
-        self.add_case(Program(lst, bigendian), initial_regs)
+        e = ExpectedState(pc=4)
+        e.intregs[1] = 0x7f9497aaff900ea0
+        e.intregs[3] = 0xffffffffffffffa0
+        self.add_case(Program(lst, bigendian), initial_regs, expected=e)
         lst = [f"add. 3, 1, 2"]
         initial_regs = [0] * 32
         initial_regs[1] = 0xc523e996a8ff6215