System.py revision 4859
13938Ssaidi@eecs.umich.edu# Copyright (c) 2005-2007 The Regents of The University of Michigan 212701Snikos.nikoleris@arm.com# All rights reserved. 39419Sandreas.hansson@arm.com# 49419Sandreas.hansson@arm.com# Redistribution and use in source and binary forms, with or without 59419Sandreas.hansson@arm.com# modification, are permitted provided that the following conditions are 69419Sandreas.hansson@arm.com# met: redistributions of source code must retain the above copyright 79419Sandreas.hansson@arm.com# notice, this list of conditions and the following disclaimer; 89419Sandreas.hansson@arm.com# redistributions in binary form must reproduce the above copyright 99419Sandreas.hansson@arm.com# notice, this list of conditions and the following disclaimer in the 109419Sandreas.hansson@arm.com# documentation and/or other materials provided with the distribution; 119419Sandreas.hansson@arm.com# neither the name of the copyright holders nor the names of its 129419Sandreas.hansson@arm.com# contributors may be used to endorse or promote products derived from 139419Sandreas.hansson@arm.com# this software without specific prior written permission. 143938Ssaidi@eecs.umich.edu# 153938Ssaidi@eecs.umich.edu# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 163938Ssaidi@eecs.umich.edu# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 173938Ssaidi@eecs.umich.edu# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 183938Ssaidi@eecs.umich.edu# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 193938Ssaidi@eecs.umich.edu# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 203938Ssaidi@eecs.umich.edu# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 213938Ssaidi@eecs.umich.edu# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 223938Ssaidi@eecs.umich.edu# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 233938Ssaidi@eecs.umich.edu# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 243938Ssaidi@eecs.umich.edu# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 253938Ssaidi@eecs.umich.edu# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 263938Ssaidi@eecs.umich.edu# 273938Ssaidi@eecs.umich.edu# Authors: Nathan Binkert 283938Ssaidi@eecs.umich.edu 293938Ssaidi@eecs.umich.edufrom m5.SimObject import SimObject 303938Ssaidi@eecs.umich.edufrom m5.params import * 313938Ssaidi@eecs.umich.edufrom m5.proxy import * 323938Ssaidi@eecs.umich.edufrom m5 import build_env 333938Ssaidi@eecs.umich.edufrom PhysicalMemory import * 343938Ssaidi@eecs.umich.edu 353938Ssaidi@eecs.umich.educlass MemoryMode(Enum): vals = ['invalid', 'atomic', 'timing'] 363938Ssaidi@eecs.umich.edu 373938Ssaidi@eecs.umich.educlass System(SimObject): 383938Ssaidi@eecs.umich.edu type = 'System' 393938Ssaidi@eecs.umich.edu swig_objdecls = [ '%include "python/swig/system.i"' ] 403938Ssaidi@eecs.umich.edu 413938Ssaidi@eecs.umich.edu physmem = Param.PhysicalMemory(Parent.any, "phsyical memory") 423938Ssaidi@eecs.umich.edu mem_mode = Param.MemoryMode('atomic', "The mode the memory system is in") 433938Ssaidi@eecs.umich.edu if build_env['FULL_SYSTEM']: 443938Ssaidi@eecs.umich.edu abstract = True 453938Ssaidi@eecs.umich.edu boot_cpu_frequency = Param.Frequency(Self.cpu[0].clock.frequency, 4612225Sgiacomo.travaglini@arm.com "boot processor frequency") 4712225Sgiacomo.travaglini@arm.com init_param = Param.UInt64(0, "numerical value to pass into simulator") 489419Sandreas.hansson@arm.com boot_osflags = Param.String("a", "boot flags to pass to the kernel") 493938Ssaidi@eecs.umich.edu kernel = Param.String("", "file that contains the kernel code") 5010291SAndreas.Sandberg@ARM.com readfile = Param.String("", "file to read startup script from") 5110291SAndreas.Sandberg@ARM.com symbolfile = Param.String("", "file to get the symbols from") 5210291SAndreas.Sandberg@ARM.com