45d44
< import os
48d46
< from os.path import join as joinpath
57a56
> import Options
59d57
<
65,69d62
< # Get paths we might need. It's expected this file is in m5/configs/example.
< config_path = os.path.dirname(os.path.abspath(__file__))
< config_root = os.path.dirname(config_path)
< m5_root = os.path.dirname(config_root)
<
70a64,65
> Options.addCommonOptions(parser)
> Options.addSEOptions(parser)
72,84d66
< # Benchmark options
< parser.add_option("-c", "--cmd",
< default=joinpath(m5_root, "tests/test-progs/hello/bin/%s/linux/hello" % \
< buildEnv['TARGET_ISA']),
< help="The binary to run in syscall emulation mode.")
< parser.add_option("-o", "--options", default="",
< help='The options to pass to the binary, use " " around the entire string')
< parser.add_option("-i", "--input", default="", help="Read stdin from a file.")
< parser.add_option("--output", default="", help="Redirect stdout to a file.")
< parser.add_option("--errout", default="", help="Redirect stderr to a file.")
<
< execfile(os.path.join(config_root, "common", "Options.py"))
<
113c95
< else:
---
> elif options.cmd:
117a100,102
> else:
> print >> sys.stderr, "No workload specified. Exiting!\n"
> sys.exit(1)