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:
1425cbc
)
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>
Sun, 10 Sep 2023 20:29:53 +0000
(23:29 +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