From: R Veera Kumar Date: Sun, 21 Nov 2021 15:32:41 +0000 (+0530) Subject: Add expected state to case_cmp2 in alu_cases unit test X-Git-Tag: sv_maxu_works-initial~726 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=117995ae403fe37225512cf85b02d38223161567;p=openpower-isa.git Add expected state to case_cmp2 in alu_cases unit test --- diff --git a/src/openpower/test/alu/alu_cases.py b/src/openpower/test/alu/alu_cases.py index f3695e0b..dedfcd53 100644 --- a/src/openpower/test/alu/alu_cases.py +++ b/src/openpower/test/alu/alu_cases.py @@ -227,13 +227,21 @@ class ALUTestCase(TestAccumulatorBase): initial_regs = [0] * 32 initial_regs[2] = 0xffffffffaaaaaaaa initial_regs[3] = 0x00000000aaaaaaaa - self.add_case(Program(lst, bigendian), initial_regs, {}) + e = ExpectedState(pc=4) + e.intregs[2] = 0xffffffffaaaaaaaa + e.intregs[3] = 0xaaaaaaaa + e.crregs[2] = 0x2 + self.add_case(Program(lst, bigendian), initial_regs, expected=e) lst = ["cmp cr2, 0, 4, 5"] initial_regs = [0] * 32 initial_regs[4] = 0x00000000aaaaaaaa initial_regs[5] = 0xffffffffaaaaaaaa - self.add_case(Program(lst, bigendian), initial_regs, {}) + e = ExpectedState(pc=4) + e.intregs[4] = 0xaaaaaaaa + e.intregs[5] = 0xffffffffaaaaaaaa + e.crregs[2] = 0x2 + self.add_case(Program(lst, bigendian), initial_regs, expected=e) def case_cmp3(self): lst = ["cmp cr2, 1, 2, 3"]