remove unneeded imports
[soc.git] / src / soc / fu / ldst / pipe_data.py
1 from soc.fu.alu.alu_input_record import CompLDSTOpSubset
2 from soc.fu.pipe_data import IntegerData
3
4
5 class LDSTInputData(IntegerData):
6 regspec = [('INT', 'ra', '0:63'), # RA
7 ('INT', 'rb', '0:63'), # RB/immediate
8 ('INT', 'rc', '0:63'), # RC
9 ('XER', 'xer_so', '32')] # XER bit 32: SO
10 ]
11 def __init__(self, pspec):
12 super().__init__(pspec, False)
13 # convenience
14 self.rs = self.rc
15
16
17 class LDSTOutputData(IntegerData):
18 regspec = [('INT', 'o', '0:63'), # RT
19 ('INT', 'o1', '0:63'), # RA (effective address, update mode)
20 ('CR', 'cr_a', '0:3'),
21 ('XER', 'xer_so', '32')]
22 def __init__(self, pspec):
23 super().__init__(pspec, True)
24 # convenience
25 self.cr0, self.ea = self.cr_a, self.o1
26
27
28 class LDSTPipeSpec(CommonPipeSpec):
29 regspec = (LDSTInputData.regspec, LDSTOutputData.regspec)
30 opsubsetkls = CompLDSTOpSubset