From: Luke Kenneth Casson Leighton Date: Wed, 27 May 2020 02:45:40 +0000 (+0100) Subject: make power function unit enum bitmasked X-Git-Tag: div_pipeline~803 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=07ff6ec3c24aae29716519771c38eb09c1c2a774;p=soc.git make power function unit enum bitmasked --- diff --git a/src/soc/decoder/power_enums.py b/src/soc/decoder/power_enums.py index 05e23f8e..b294324e 100644 --- a/src/soc/decoder/power_enums.py +++ b/src/soc/decoder/power_enums.py @@ -46,15 +46,15 @@ def get_signal_name(name): @unique class Function(Enum): NONE = 0 - ALU = 1 - LDST = 2 - SHIFT_ROT = 3 - LOGICAL = 4 - BRANCH = 5 - CR = 6 - TRAP = 7 - MUL = 8 - DIV = 9 + ALU = 1<<1 + LDST = 1<<2 + SHIFT_ROT = 1<<3 + LOGICAL = 1<<4 + BRANCH = 1<<5 + CR = 1<<6 + TRAP = 1<<7 + MUL = 1<<8 + DIV = 1<<9 @unique