projects
/
openpower-isa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5a6cdbc
)
insndb/core: walk over opcode value and mask
author
Dmitry Selyutin
<ghostmansd@gmail.com>
Sun, 3 Sep 2023 06:38:10 +0000
(09:38 +0300)
committer
Dmitry Selyutin
<ghostmansd@gmail.com>
Wed, 6 Sep 2023 18:56:09 +0000
(21:56 +0300)
src/openpower/insndb/core.py
patch
|
blob
|
history
diff --git
a/src/openpower/insndb/core.py
b/src/openpower/insndb/core.py
index 1850def6d11ee7ad716956c2e48decc462189f93..867f9c4b76c7c3c498cda18c1a3c5b9e484fed44 100644
(file)
--- 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