Regression: Use addTwoLevelCacheHierarchy in configs
This patch unifies the full-system regression config scripts and uses the BaseCPU convenience method addTwoLevelCacheHierarchy to connect up the L1s and L2, and create the bus inbetween. The patch is a step on the way to use the clock period to express the cache latencies, as the CPU is now the parent of the L1, L2 and L1-L2 bus, and these modules thus use the CPU clock. The patch does not change the value of any stats, but plenty names, and a follow-up patch contains the update to the stats, chaning system.l2c to system.cpu.l2cache.
This commit is contained in:
parent
930db9257d
commit
3cf733bcc0
11 changed files with 118 additions and 155 deletions
|
@ -90,28 +90,25 @@ cpu = DerivO3CPU(cpu_id=0)
|
||||||
mdesc = SysConfig(disk = 'linux-x86.img')
|
mdesc = SysConfig(disk = 'linux-x86.img')
|
||||||
system = FSConfig.makeLinuxX86System('timing', mdesc=mdesc)
|
system = FSConfig.makeLinuxX86System('timing', mdesc=mdesc)
|
||||||
system.kernel = FSConfig.binary('x86_64-vmlinux-2.6.22.9')
|
system.kernel = FSConfig.binary('x86_64-vmlinux-2.6.22.9')
|
||||||
|
|
||||||
|
system.cpu = cpu
|
||||||
|
|
||||||
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
system.cpu = cpu
|
#connect up the cpu and caches
|
||||||
#create the l1/l2 bus
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.toL2Bus = CoherentBus()
|
|
||||||
|
|
||||||
#connect up the l2 cache
|
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4),
|
L1(size = '32kB', assoc = 4),
|
||||||
|
L2(size = '4MB', assoc = 8),
|
||||||
PageTableWalkerCache(),
|
PageTableWalkerCache(),
|
||||||
PageTableWalkerCache())
|
PageTableWalkerCache())
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -92,28 +92,25 @@ cpu = AtomicSimpleCPU(cpu_id=0)
|
||||||
mdesc = SysConfig(disk = 'linux-x86.img')
|
mdesc = SysConfig(disk = 'linux-x86.img')
|
||||||
system = FSConfig.makeLinuxX86System('atomic', mdesc=mdesc)
|
system = FSConfig.makeLinuxX86System('atomic', mdesc=mdesc)
|
||||||
system.kernel = FSConfig.binary('x86_64-vmlinux-2.6.22.9')
|
system.kernel = FSConfig.binary('x86_64-vmlinux-2.6.22.9')
|
||||||
|
|
||||||
|
system.cpu = cpu
|
||||||
|
|
||||||
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
system.cpu = cpu
|
#connect up the cpu and caches
|
||||||
#create the l1/l2 bus
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.toL2Bus = CoherentBus()
|
|
||||||
|
|
||||||
#connect up the l2 cache
|
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4),
|
L1(size = '32kB', assoc = 4),
|
||||||
|
L2(size = '4MB', assoc = 8),
|
||||||
PageTableWalkerCache(),
|
PageTableWalkerCache(),
|
||||||
PageTableWalkerCache())
|
PageTableWalkerCache())
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -93,27 +93,23 @@ system = FSConfig.makeLinuxX86System('timing', mdesc = mdesc)
|
||||||
system.kernel = FSConfig.binary('x86_64-vmlinux-2.6.22.9')
|
system.kernel = FSConfig.binary('x86_64-vmlinux-2.6.22.9')
|
||||||
|
|
||||||
system.cpu = cpu
|
system.cpu = cpu
|
||||||
#create the l1/l2 bus
|
|
||||||
system.toL2Bus = CoherentBus()
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
|
#connect up the cpu and caches
|
||||||
#connect up the l2 cache
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4),
|
L1(size = '32kB', assoc = 4),
|
||||||
|
L2(size = '4MB', assoc = 8),
|
||||||
PageTableWalkerCache(),
|
PageTableWalkerCache(),
|
||||||
PageTableWalkerCache())
|
PageTableWalkerCache())
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -85,26 +85,23 @@ cpu = DerivO3CPU(cpu_id=0)
|
||||||
system = FSConfig.makeArmSystem('timing', "RealView_PBX", None, False)
|
system = FSConfig.makeArmSystem('timing', "RealView_PBX", None, False)
|
||||||
|
|
||||||
system.cpu = cpu
|
system.cpu = cpu
|
||||||
#create the l1/l2 bus
|
#connect up the checker
|
||||||
system.toL2Bus = CoherentBus()
|
cpu.addCheckerCpu()
|
||||||
|
|
||||||
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
|
#connect up the cpu and caches
|
||||||
#connect up the l2 cache
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
L1(size = '32kB', assoc = 4),
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
L2(size = '4MB', assoc = 8))
|
||||||
system.l2c.mem_side = system.membus.slave
|
# create the interrupt controller
|
||||||
|
|
||||||
#connect up the checker
|
|
||||||
cpu.addCheckerCpu()
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
# connect cpu and caches to the rest of the system
|
||||||
L1(size = '32kB', assoc = 4))
|
cpu.connectAllPorts(system.membus)
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -76,25 +76,21 @@ cpu = DerivO3CPU(cpu_id=0)
|
||||||
system = FSConfig.makeArmSystem('timing', "RealView_PBX", None, False)
|
system = FSConfig.makeArmSystem('timing', "RealView_PBX", None, False)
|
||||||
|
|
||||||
system.cpu = cpu
|
system.cpu = cpu
|
||||||
#create the l1/l2 bus
|
|
||||||
system.toL2Bus = CoherentBus()
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
|
#connect up the cpu and caches
|
||||||
#connect up the l2 cache
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
L1(size = '32kB', assoc = 4),
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
L2(size = '4MB', assoc = 8))
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4))
|
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -73,26 +73,23 @@ class IOCache(BaseCache):
|
||||||
cpu = AtomicSimpleCPU(cpu_id=0)
|
cpu = AtomicSimpleCPU(cpu_id=0)
|
||||||
#the system
|
#the system
|
||||||
system = FSConfig.makeArmSystem('atomic', "RealView_PBX", None, False)
|
system = FSConfig.makeArmSystem('atomic', "RealView_PBX", None, False)
|
||||||
|
|
||||||
|
system.cpu = cpu
|
||||||
|
|
||||||
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
system.cpu = cpu
|
#connect up the cpu and caches
|
||||||
#create the l1/l2 bus
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.toL2Bus = CoherentBus()
|
L1(size = '32kB', assoc = 4),
|
||||||
|
L2(size = '4MB', assoc = 8))
|
||||||
#connect up the l2 cache
|
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4))
|
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -76,25 +76,21 @@ cpu = TimingSimpleCPU(cpu_id=0)
|
||||||
system = FSConfig.makeArmSystem('timing', "RealView_PBX", None, False)
|
system = FSConfig.makeArmSystem('timing', "RealView_PBX", None, False)
|
||||||
|
|
||||||
system.cpu = cpu
|
system.cpu = cpu
|
||||||
#create the l1/l2 bus
|
|
||||||
system.toL2Bus = CoherentBus()
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
|
#connect up the cpu and caches
|
||||||
#connect up the l2 cache
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
L1(size = '32kB', assoc = 4),
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
L2(size = '4MB', assoc = 8))
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4))
|
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -80,23 +80,21 @@ cpu.fetchBuffSize = 1
|
||||||
system = FSConfig.makeLinuxAlphaSystem('timing')
|
system = FSConfig.makeLinuxAlphaSystem('timing')
|
||||||
|
|
||||||
system.cpu = cpu
|
system.cpu = cpu
|
||||||
#create the l1/l2 bus
|
|
||||||
system.toL2Bus = CoherentBus()
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
|
#connect up the cpu and caches
|
||||||
#connect up the l2 cache
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
L1(size = '32kB', assoc = 4),
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
L2(size = '4MB', assoc = 8))
|
||||||
system.l2c.mem_side = system.membus.slave
|
# create the interrupt controller
|
||||||
|
cpu.createInterruptController()
|
||||||
#connect up the cpu and l1s
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
cpu.connectAllPorts(system.membus)
|
||||||
L1(size = '32kB', assoc = 4))
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -77,25 +77,21 @@ cpu = DerivO3CPU(cpu_id=0)
|
||||||
system = FSConfig.makeLinuxAlphaSystem('timing')
|
system = FSConfig.makeLinuxAlphaSystem('timing')
|
||||||
|
|
||||||
system.cpu = cpu
|
system.cpu = cpu
|
||||||
#create the l1/l2 bus
|
|
||||||
system.toL2Bus = CoherentBus()
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
|
#connect up the cpu and caches
|
||||||
#connect up the l2 cache
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
L1(size = '32kB', assoc = 4),
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
L2(size = '4MB', assoc = 8))
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4))
|
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -74,26 +74,23 @@ class IOCache(BaseCache):
|
||||||
cpu = AtomicSimpleCPU(cpu_id=0)
|
cpu = AtomicSimpleCPU(cpu_id=0)
|
||||||
#the system
|
#the system
|
||||||
system = FSConfig.makeLinuxAlphaSystem('atomic')
|
system = FSConfig.makeLinuxAlphaSystem('atomic')
|
||||||
|
|
||||||
|
system.cpu = cpu
|
||||||
|
|
||||||
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
system.cpu = cpu
|
#connect up the cpu and caches
|
||||||
#create the l1/l2 bus
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.toL2Bus = CoherentBus()
|
L1(size = '32kB', assoc = 4),
|
||||||
|
L2(size = '4MB', assoc = 8))
|
||||||
#connect up the l2 cache
|
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4))
|
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
|
@ -77,25 +77,21 @@ cpu = TimingSimpleCPU(cpu_id=0)
|
||||||
system = FSConfig.makeLinuxAlphaSystem('timing')
|
system = FSConfig.makeLinuxAlphaSystem('timing')
|
||||||
|
|
||||||
system.cpu = cpu
|
system.cpu = cpu
|
||||||
#create the l1/l2 bus
|
|
||||||
system.toL2Bus = CoherentBus()
|
#create the iocache
|
||||||
system.iocache = IOCache()
|
system.iocache = IOCache()
|
||||||
system.iocache.cpu_side = system.iobus.master
|
system.iocache.cpu_side = system.iobus.master
|
||||||
system.iocache.mem_side = system.membus.slave
|
system.iocache.mem_side = system.membus.slave
|
||||||
|
|
||||||
|
#connect up the cpu and caches
|
||||||
#connect up the l2 cache
|
cpu.addTwoLevelCacheHierarchy(L1(size = '32kB', assoc = 1),
|
||||||
system.l2c = L2(size='4MB', assoc=8)
|
L1(size = '32kB', assoc = 4),
|
||||||
system.l2c.cpu_side = system.toL2Bus.master
|
L2(size = '4MB', assoc = 8))
|
||||||
system.l2c.mem_side = system.membus.slave
|
|
||||||
|
|
||||||
#connect up the cpu and l1s
|
|
||||||
cpu.addPrivateSplitL1Caches(L1(size = '32kB', assoc = 1),
|
|
||||||
L1(size = '32kB', assoc = 4))
|
|
||||||
# create the interrupt controller
|
# create the interrupt controller
|
||||||
cpu.createInterruptController()
|
cpu.createInterruptController()
|
||||||
# connect cpu level-1 caches to shared level-2 cache
|
# connect cpu and caches to the rest of the system
|
||||||
cpu.connectAllPorts(system.toL2Bus, system.membus)
|
cpu.connectAllPorts(system.membus)
|
||||||
|
# set the cpu clock along with the caches and l1-l2 bus
|
||||||
cpu.clock = '2GHz'
|
cpu.clock = '2GHz'
|
||||||
|
|
||||||
root = Root(full_system=True, system=system)
|
root = Root(full_system=True, system=system)
|
||||||
|
|
Loading…
Reference in a new issue