Merge zizzer.eecs.umich.edu:/z/m5/Bitkeeper/newmem
[gem5.git] / src / python / m5 / objects / FuncUnit.py
1 from m5.SimObject import SimObject
2 from m5.params import *
3
4 class OpType(Enum):
5 vals = ['(null)', 'IntAlu', 'IntMult', 'IntDiv', 'FloatAdd',
6 'FloatCmp', 'FloatCvt', 'FloatMult', 'FloatDiv', 'FloatSqrt',
7 'MemRead', 'MemWrite', 'IprAccess', 'InstPrefetch']
8
9 class OpDesc(SimObject):
10 type = 'OpDesc'
11 issueLat = Param.Int(1, "cycles until another can be issued")
12 opClass = Param.OpType("type of operation")
13 opLat = Param.Int(1, "cycles until result is available")
14
15 class FUDesc(SimObject):
16 type = 'FUDesc'
17 count = Param.Int("number of these FU's available")
18 opList = VectorParam.OpDesc("operation classes for this FU type")