OpenCores
URL https://opencores.org/ocsvn/tv80/tv80/trunk

Subversion Repositories tv80

[/] [tv80/] [trunk/] [scripts/] [run] - Diff between revs 89 and 112

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 89 Rev 112
Line 23... Line 23...
 
 
def print_help ():
def print_help ():
    print "Usage: run [-th] [-d ###] "
    print "Usage: run [-th] [-d ###] "
    print "  -t : instruction decode (trace)"
    print "  -t : instruction decode (trace)"
    print "  -d : enable dumping start at time ###"
    print "  -d : enable dumping start at time ###"
 
    print "  -c : enable code coverage"
    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
# t : instruction trace
# t : instruction trace
# d : dump starting at
# d : dump starting at
# h : help
# h : help
(options, args) = getopt.getopt (sys.argv[1:], "thd:")
(options, args) = getopt.getopt (sys.argv[1:], "thcd:")
if len(args) == 0:
if len(args) == 0:
    print_help()
    print_help()
testname = args[0]
testname = args[0]
simulator = "vcs +v2k -full64 -R -I +define+VCS=1 "
simulator = "vcs +v2k -full64 -R -I +vcs+lic+wait "
 
 
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] == "-t":
    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":
    elif option[0] == "-d":
        testdef += " +define+DUMP_START=%s" % option[1]
        testdef += " +define+DUMP_START=%s" % option[1]
 
    elif option[0] == "-c":
 
        # enable VCS code coverage
 
        testdef += " -cm line+branch -cm_dir cov/"+testname+" -cm_hier env/cov.vf"
    elif option[0] == "-h":
    elif option[0] == "-h":
        print_help()
        print_help()
    else:
    else:
        print_help()
        print_help()
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.