From 51abaefe2d567791d3c052ca8976dea0b7917c90 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Sat, 15 May 2021 17:05:26 +0100 Subject: [PATCH] missed an assignment-copy for simple expressions --- src/openpower/decoder/pseudo/parser.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/openpower/decoder/pseudo/parser.py b/src/openpower/decoder/pseudo/parser.py index b6eba3e2..b24baeac 100644 --- a/src/openpower/decoder/pseudo/parser.py +++ b/src/openpower/decoder/pseudo/parser.py @@ -429,7 +429,11 @@ class PowerParser: else: print("help, help") print(astor.dump_tree(p[1])) - print("expr assign", name, p[1]) + print("expr assign", name, p[1], "to", p[3]) + if isinstance(p[3], ast.Name): + toname = p[3].id + if toname in self.gprs: + self.read_regs.add(toname) if name and name in self.gprs: self.write_regs.add(name) # add to list of regs to write p[0] = Assign(autoassign, name, p[1], p[3], iea_mode) -- 2.30.2