1# Copyright (c) 2016 ARM Limited 2# All rights reserved. 3# 4# The license below extends only to copyright in the software and shall 5# not be construed as granting a license to any other intellectual 6# property including but not limited to intellectual property relating 7# to a hardware implementation of the functionality of the software 8# licensed hereunder. You may use the software subject to the license --- 65 unchanged lines hidden (view full) --- 74 def __init__(self, system, num_cpus, cpu_clock, 75 cpu_voltage="1.0V"): 76 cpu_config = [ CpuConfig.get("minor"), devices.L1I, devices.L1D, 77 devices.WalkCache, devices.L2 ] 78 super(LittleCluster, self).__init__(system, num_cpus, cpu_clock, 79 cpu_voltage, *cpu_config) 80 81 |
82def createSystem(caches, kernel, bootscript, disks=[]): 83 sys = devices.SimpleSystem(caches, default_mem_size, 84 kernel=SysPaths.binary(kernel), |
85 readfile=bootscript, 86 machine_type="DTOnly") 87 |
88 sys.mem_ctrls = SimpleMemory(range=sys._mem_range) |
89 sys.mem_ctrls.port = sys.membus.master 90 91 sys.connect() 92 93 # Attach disk images 94 if disks: 95 def cow_disk(image_file): 96 image = CowDiskImage() --- 56 unchanged lines hidden (view full) --- 153 "root=/dev/vda1", 154 "rw", 155 "init=%s" % options.kernel_init, 156 "vmalloc=768MB", 157 ] 158 159 root = Root(full_system=True) 160 |
161 disks = [default_disk] if len(options.disk) == 0 else options.disk 162 system = createSystem(options.caches, 163 options.kernel, 164 options.bootscript, 165 disks=disks) |
166 167 root.system = system 168 system.boot_osflags = " ".join(kernel_cmd) 169 170 AtomicCluster = devices.AtomicCluster 171 172 if options.big_cpus + options.little_cpus == 0: 173 m5.util.panic("Empty CPU clusters") --- 61 unchanged lines hidden --- |