bit of a hack-job, a base class MRBaseRM - MapReduce RM - was confused
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sun, 18 Sep 2022 20:32:14 +0000 (21:32 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sun, 18 Sep 2022 20:32:14 +0000 (21:32 +0100)
there is no need to report "/mr" on a "Simple" mode, which was deriving
from MRBaseRM

src/openpower/decoder/power_insn.py

index 47ee25eb5bae46a71620c284f3c7bec9b17398f5..e9f172f9ae1cc8954535deffeca0802d7ab514d4 100644 (file)
@@ -1364,9 +1364,15 @@ class SZBaseRM(BaseRM):
 class MRBaseRM(BaseRM):
     def specifiers(self, record):
         if self.RG:
-            yield "mrr"
+            # reverse-gear but this is a mix-in class, different reports needed
+            if isinstance(self, CROpSimpleRM):
+                yield "rg" # simple CR Mode reports /rg
+            else:
+                yield "mrr" # all others assume "mapreduce+reverse"
         else:
-            yield "mr"
+            # in CR-Simple just don't report anything
+            if not isinstance(self, CROpSimpleRM):
+                yield "mr" # all but CR-Simple report "mapreduce"
 
         yield from super().specifiers(record=record)