speed up divmod shift-sub tests by removing most test cases
[openpower-isa.git] / src / openpower / test / branch / branch_cases.py
index 40a2452a9e351f958053ee7a9d980409e6fdf1fa..027be875a124e351450c47cb3752ffaa4d0e0ff3 100644 (file)
@@ -16,6 +16,11 @@ class BranchTestCase(TestAccumulatorBase):
             initial_regs = [0] * 32
             self.add_case(Program(lst, bigendian), initial_regs)
 
+    def cse_1_regression_negbranch(self):
+        lst = [f"bl -3377317"]
+        initial_regs = [0] * 32
+        self.add_case(Program(lst, bigendian), initial_regs)
+
     def case_unconditional(self):
         choices = ["b", "ba", "bl", "bla"]
         for i in range(20):
@@ -48,6 +53,18 @@ class BranchTestCase(TestAccumulatorBase):
                           initial_sprs=initial_sprs,
                           initial_cr=cr)
 
+    def case_bc_ctr_regression(self):
+        bc = 13116
+        bo = 8
+        bi = 6
+        cr = 0x100983
+        ctr = 0x420abd56
+        lst = [f"bc {bo}, {bi}, {bc}"]
+        initial_sprs = {9: SelectableInt(ctr, 64)}
+        self.add_case(Program(lst, bigendian),
+                      initial_sprs=initial_sprs,
+                      initial_cr=cr)
+
     def case_bc_reg(self):
         # XXX: bcctr and bcctrl time out (irony: they're counters)
         choices = ["bclr", "bclrl", "bcctr", "bcctrl", "bctar", "bctarl"]