From: Dmitry Selyutin Date: Fri, 12 Jan 2024 19:33:05 +0000 (+0300) Subject: oppc/code: support XLEN X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7f03c750e3352e8d8c58a673dbc7809ac221f426;p=openpower-isa.git oppc/code: support XLEN --- diff --git a/src/openpower/oppc/pc_code.py b/src/openpower/oppc/pc_code.py index 0c64d40e..67d4f42f 100644 --- a/src/openpower/oppc/pc_code.py +++ b/src/openpower/oppc/pc_code.py @@ -148,6 +148,11 @@ class CodeVisitor(pc_util.Visitor): times = str(self[node.times]) self[node].emit(f"oppc_repeat({subject}, {times})") + @pc_util.Hook(pc_ast.XLEN) + def XLEN(self, node): + yield node + self[node].emit(f"ctx->XLEN") + @pc_util.Hook(pc_ast.Call.Name) def CallName(self, node): yield node