From 2cc67358e7a6767f198cc946c57e882dfbbfefc5 Mon Sep 17 00:00:00 2001 From: Dmitry Selyutin Date: Tue, 28 Sep 2021 20:20:33 +0000 Subject: [PATCH] decoder/helpers: support XLCASTS --- src/openpower/decoder/helpers.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/openpower/decoder/helpers.py b/src/openpower/decoder/helpers.py index 3b142e1a..84300ba0 100644 --- a/src/openpower/decoder/helpers.py +++ b/src/openpower/decoder/helpers.py @@ -450,6 +450,9 @@ class ISACallerHelper: def XLEN(self): return self.__XLEN + def XLCASTS(self, value): + return SelectableInt(exts(value.value, self.XLEN), self.XLEN) + def XLCASTU(self, value): bits = min(value.bits, self.XLEN) return SelectableInt(value.value & ((1 << bits) - 1), self.XLEN) -- 2.30.2