start adding bitmanip FU
[soc.git] / src / soc / fu / bitmanip / input_record.py
1 from soc.fu.base_input_record import CompOpSubsetBase
2 from nmigen.hdl.rec import Layout
3
4 from openpower.decoder.power_enums import MicrOp, Function, CryIn
5
6
7 class CompBitManipOpSubset(CompOpSubsetBase):
8 """CompBitManipOpSubset
9
10 a copy of the relevant subset information from Decode2Execute1Type
11 needed for ALU operations. use with eq_from_execute1 (below) to
12 grab subsets.
13 """
14
15 def __init__(self, name=None):
16 layout = (('insn_type', MicrOp),
17 ('fn_unit', Function),
18 ('imm_data', Layout((("data", 64), ("ok", 1)))),
19 ('rc', Layout((("rc", 1), ("ok", 1)))), # Data
20 ('oe', Layout((("oe", 1), ("ok", 1)))), # Data
21 ('write_cr0', 1),
22 ('is_32bit', 1),
23 ('is_signed', 1),
24 ('insn', 32),
25 )
26
27 super().__init__(layout, name=name)