URL
https://opencores.org/ocsvn/tv80/tv80/trunk
[/] [tv80/] [trunk/] [scripts/] [run] - Diff between revs 38 and 44
Go to most recent revision |
Show entire file |
Details |
Blame |
View Log
Rev 38 |
Rev 44 |
Line 20... |
Line 20... |
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
|
import sys, os, getopt
|
import sys, os, getopt
|
|
|
def print_help ():
|
def print_help ():
|
print "Usage: run [-dh] "
|
print "Usage: run [-th] [-d ###] "
|
print " -d : instruction decode"
|
print " -t : instruction decode (trace)"
|
|
print " -d : enable dumping start at time ###"
|
print " -h : option help (this list)"
|
print " -h : option help (this list)"
|
sys.exit(0)
|
sys.exit(0)
|
|
|
# parse command line options
|
# parse command line options
|
# d : instruction trace
|
# t : instruction trace
|
|
# d : dump starting at
|
# h : help
|
# h : help
|
(options, args) = getopt.getopt (sys.argv[1:], "dh")
|
(options, args) = getopt.getopt (sys.argv[1:], "thd:")
|
if len(args) == 0:
|
if len(args) == 0:
|
print_help()
|
print_help()
|
testname = args[0]
|
testname = args[0]
|
simulator = "cver"
|
simulator = "cver"
|
|
|
filelist = " -f env/tb.vf"
|
filelist = " -f env/tb.vf"
|
testdef = " +incdir+env -l logs/%s.log +define+DUMPFILE_NAME=\\\"logs/%s.dump\\\" +define+PROGRAM_FILE=\\\"tests/%s.vmem\\\"" % (testname, testname, testname)
|
testdef = " +incdir+env -l logs/%s.log +define+DUMPFILE_NAME=\\\"logs/%s.dump\\\" +define+PROGRAM_FILE=\\\"tests/%s.vmem\\\"" % (testname, testname, testname)
|
|
|
for option in options:
|
for option in options:
|
if option[0] == "-d":
|
if option[0] == "-t":
|
print "Adding TV80_INSTRUCTION_DECODE"
|
print "Adding TV80_INSTRUCTION_DECODE"
|
testdef += " +define+TV80_INSTRUCTION_DECODE=1"
|
testdef += " +define+TV80_INSTRUCTION_DECODE=1"
|
|
elif option[0] == "-d":
|
|
testdef += " +define+DUMP_START=%s" % option[1]
|
elif option[0] == "-h":
|
elif option[0] == "-h":
|
print_help()
|
print_help()
|
else:
|
else:
|
print_help()
|
print_help()
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.