From: Dmitry Selyutin Date: Fri, 16 Sep 2022 14:39:51 +0000 (+0300) Subject: power_insn: postpone updating per-instruction operands X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=008d1d272f14aa7bd7dc7e71c20ab9f00ce06572;p=openpower-isa.git power_insn: postpone updating per-instruction operands --- diff --git a/src/openpower/decoder/power_insn.py b/src/openpower/decoder/power_insn.py index 2d36a17f..c3a72a2c 100644 --- a/src/openpower/decoder/power_insn.py +++ b/src/openpower/decoder/power_insn.py @@ -776,7 +776,7 @@ class TargetAddrOperandBD(TargetAddrOperand): verbosity=verbosity, indent=indent) -class DOperandDX(DynamicOperand): +class DOperandDX(SignedOperand): def span(self, record): operands = map(DynamicOperand, ("d0", "d1", "d2")) spans = map(lambda operand: operand.span(record=record), operands) @@ -862,10 +862,10 @@ class Operands(tuple): if immediate is not None: operands.append(ImmediateOperand(name=immediate)) - if insn in custom_insns and operand in custom_insns[insn]: - dynamic_cls = custom_insns[insn][operand] if operand in custom_fields: dynamic_cls = custom_fields[operand] + if insn in custom_insns and operand in custom_insns[insn]: + dynamic_cls = custom_insns[insn][operand] if operand in _RegType.__members__: regtype = _RegType[operand]