From: Dmitry Selyutin Date: Sun, 3 Sep 2023 06:38:10 +0000 (+0300) Subject: insndb/core: walk over opcode value and mask X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0cf19c7f07f652a4d17019ff9dd2690b512e6c3d;p=openpower-isa.git insndb/core: walk over opcode value and mask --- diff --git a/src/openpower/insndb/core.py b/src/openpower/insndb/core.py index 1850def6..867f9c4b 100644 --- a/src/openpower/insndb/core.py +++ b/src/openpower/insndb/core.py @@ -3738,6 +3738,12 @@ class Walker(mdis.walker.Walker): def dispatch_database(self, node): yield from self(tuple(node)) + @mdis.dispatcher.Hook(Opcode) + def dispatch_opcode(self, node): + for key in ("value", "mask"): + value = getattr(node, key) + yield (value, node, key, mdis.walker.AttributePath) + @mdis.dispatcher.Hook(Record) def dispatch_record(self, node): self.__record = node