Options.py (9357:94383c5124d2) | Options.py (9520:ea7c03ae2d5e) |
---|---|
1# Copyright (c) 2006-2008 The Regents of The University of Michigan 2# All rights reserved. 3# 4# Redistribution and use in source and binary forms, with or without 5# modification, are permitted provided that the following conditions are 6# met: redistributions of source code must retain the above copyright 7# notice, this list of conditions and the following disclaimer; 8# redistributions in binary form must reproduce the above copyright --- 17 unchanged lines hidden (view full) --- 26# 27# Authors: Lisa Hsu 28 29import m5 30from m5.defines import buildEnv 31from m5.objects import * 32from Benchmarks import * 33 | 1# Copyright (c) 2006-2008 The Regents of The University of Michigan 2# All rights reserved. 3# 4# Redistribution and use in source and binary forms, with or without 5# modification, are permitted provided that the following conditions are 6# met: redistributions of source code must retain the above copyright 7# notice, this list of conditions and the following disclaimer; 8# redistributions in binary form must reproduce the above copyright --- 17 unchanged lines hidden (view full) --- 26# 27# Authors: Lisa Hsu 28 29import m5 30from m5.defines import buildEnv 31from m5.objects import * 32from Benchmarks import * 33 |
34import CpuConfig 35 36def _listCpuTypes(option, opt, value, parser): 37 CpuConfig.print_cpu_list() 38 sys.exit(0) 39 |
|
34def addCommonOptions(parser): 35 # system options | 40def addCommonOptions(parser): 41 # system options |
42 parser.add_option("--list-cpu-types", 43 action="callback", callback=_listCpuTypes, 44 help="List available CPU types") |
|
36 parser.add_option("--cpu-type", type="choice", default="atomic", | 45 parser.add_option("--cpu-type", type="choice", default="atomic", |
37 choices = ["atomic", "timing", "detailed", "inorder", 38 "arm_detailed"], | 46 choices=CpuConfig.cpu_names(), |
39 help = "type of cpu to run with") 40 parser.add_option("--checker", action="store_true"); 41 parser.add_option("-n", "--num-cpus", type="int", default=1) 42 parser.add_option("--caches", action="store_true") 43 parser.add_option("--l2cache", action="store_true") 44 parser.add_option("--fastmem", action="store_true") 45 parser.add_option("--clock", action="store", type="string", default='2GHz') 46 parser.add_option("--num-dirs", type="int", default=1) --- 141 unchanged lines hidden --- | 47 help = "type of cpu to run with") 48 parser.add_option("--checker", action="store_true"); 49 parser.add_option("-n", "--num-cpus", type="int", default=1) 50 parser.add_option("--caches", action="store_true") 51 parser.add_option("--l2cache", action="store_true") 52 parser.add_option("--fastmem", action="store_true") 53 parser.add_option("--clock", action="store", type="string", default='2GHz') 54 parser.add_option("--num-dirs", type="int", default=1) --- 141 unchanged lines hidden --- |