summaryrefslogtreecommitdiff
path: root/src/python/m5
diff options
context:
space:
mode:
authorKorey Sewell <ksewell@umich.edu>2006-06-14 14:43:45 -0400
committerKorey Sewell <ksewell@umich.edu>2006-06-14 14:43:45 -0400
commit2a9becba44f1d70b05100c04b95d475c43099fa9 (patch)
tree46ef0e871f3329698feeee25d0d6935f21661b78 /src/python/m5
parente715e298e044af3727423b27d08327d72b2d74fa (diff)
parent7709e6ba93be4b67b22e2f3f9c853a3e1ab4458b (diff)
downloadgem5-2a9becba44f1d70b05100c04b95d475c43099fa9.tar.xz
Merge zizzer:/bk/newmem
into zazzer.eecs.umich.edu:/.automount/zooks/y/ksewell/research/m5-sim/newmem-release --HG-- extra : convert_revision : 9b5b1419e8e22bce16ed97fc02c2008ca0181afc
Diffstat (limited to 'src/python/m5')
-rw-r--r--src/python/m5/__init__.py25
1 files changed, 24 insertions, 1 deletions
diff --git a/src/python/m5/__init__.py b/src/python/m5/__init__.py
index 60a61d66e..2d4825b0e 100644
--- a/src/python/m5/__init__.py
+++ b/src/python/m5/__init__.py
@@ -64,11 +64,34 @@ def AddToPath(path):
def setTraceFlags(option, opt_str, value, parser):
objects.Trace.flags = value
+def setTraceStart(option, opt_str, value, parser):
+ objects.Trace.start = value
+
+def clearPCSymbol(option, opt_str, value, parser):
+ objects.ExecutionTrace.pc_symbol = False
+
+def clearPrintCycle(option, opt_str, value, parser):
+ objects.ExecutionTrace.print_cycle = False
+
+def statsTextFile(option, opt_str, value, parser):
+ objects.Statistics.text_file = value
+
# Standard optparse options. Need to be explicitly included by the
# user script when it calls optparse.OptionParser().
standardOptions = [
optparse.make_option("--traceflags", type="string", action="callback",
- callback=setTraceFlags)
+ callback=setTraceFlags),
+ optparse.make_option("--tracestart", type="int", action="callback",
+ callback=setTraceStart),
+ optparse.make_option("--nopcsymbol", action="callback",
+ callback=clearPCSymbol,
+ help="Turn off printing PC symbols in trace output"),
+ optparse.make_option("--noprintcycle", action="callback",
+ callback=clearPrintCycle,
+ help="Turn off printing cycles in trace output"),
+ optparse.make_option("--statsfile", type="string", action="callback",
+ callback=statsTextFile, metavar="FILE",
+ help="Sets the output file for the statistics")
]
# make a SmartDict out of the build options for our local use