1 from soc
.fu
.base_input_record
import CompOpSubsetBase
2 from soc
.decoder
.power_enums
import (MicrOp
, Function
)
3 from soc
.consts
import TT
4 from soc
.experiment
.mem_types
import LDSTException
6 class CompTrapOpSubset(CompOpSubsetBase
):
9 a copy of the relevant subset information from Decode2Execute1Type
10 needed for TRAP operations. use with eq_from_execute1 (below) to
13 def __init__(self
, name
=None):
14 layout
= [('insn_type', MicrOp
),
15 ('fn_unit', Function
),
17 ('msr', 64), # TODO: "state" in separate Record
18 ('cia', 64), # likewise
20 ('traptype', TT
.size
), # see trap main_stage.py, PowerDecoder2
22 ('ldst_exc', len(LDSTException
._exc
_types
)),
25 super().__init
__(layout
, name
=name
)