# make sure target files are all gone
for t in target:
if os.path.exists(t.abspath):
- Execute(Delete(t.abspath))
+ env.Execute(Delete(t.abspath))
tgt_dir = os.path.dirname(str(target[0]))
if env['BATCH']:
cmd = '%s -t %d %s' % (env['BATCH_CMD'], timeout, cmd)
- status = Execute(env.subst(cmd, target=target, source=source))
+ status = env.Execute(env.subst(cmd, target=target, source=source))
if status == 0:
# M5 terminated normally.
# Run diff on output & ref directories to find differences.
outdiff = os.path.join(tgt_dir, 'outdiff')
diffcmd = 'diff -ubr %s ${SOURCES[2].dir} %s > %s' \
% (output_ignore_args, tgt_dir, outdiff)
- Execute(env.subst(diffcmd, target=target, source=source))
+ env.Execute(env.subst(diffcmd, target=target, source=source))
print "===== Output differences ====="
print contents(outdiff)
# Run diff-out on stats.txt file
diffcmd = '$DIFFOUT ${SOURCES[2]} %s > %s' \
% (os.path.join(tgt_dir, 'stats.txt'), statsdiff)
diffcmd = env.subst(diffcmd, target=target, source=source)
- status = Execute(diffcmd, strfunction=None)
+ status = env.Execute(diffcmd, strfunction=None)
print "===== Statistics differences ====="
print contents(statsdiff)
else: # m5 exit status != 0
# M5 did not terminate properly, so no need to check the output
- if signaled(status) and signum(status) in retry_signals:
- # Consider the test incomplete; don't create a 'status' output.
- # Hand the return status to scons and let scons decide what
- # to do about it (typically terminate unless run with -k).
+ if signaled(status):
print 'M5 terminated with signal', signum(status)
- return status
+ if signum(status) in retry_signals:
+ # Consider the test incomplete; don't create a 'status' output.
+ # Hand the return status to scons and let scons decide what
+ # to do about it (typically terminate unless run with -k).
+ return status
+ else:
+ print 'M5 exited with non-zero status', status
# complete but failed execution (call to exit() with non-zero
# status, SIGABORT due to assertion failure, etc.)... fall through
# and generate FAILED status as if output comparison had failed
- print 'M5 exited with non-zero status', status
# Generate status file contents based on exit status of m5 or diff-out
if status == 0:
print " Creating new file", f
copyAction = Copy(os.path.join(dest_dir, f), os.path.join(src_dir, f))
copyAction.strfunction = None
- Execute(copyAction)
+ env.Execute(copyAction)
return 0
def update_test_string(target, source, env):
configs = []
if env['FULL_SYSTEM']:
if env['TARGET_ISA'] == 'alpha':
- if not env['ALPHA_TLASER']:
- configs += ['tsunami-simple-atomic',
- 'tsunami-simple-timing',
- 'tsunami-simple-atomic-dual',
- 'tsunami-simple-timing-dual',
- 'twosys-tsunami-simple-atomic',
- 'tsunami-o3', 'tsunami-o3-dual']
+ configs += ['tsunami-simple-atomic',
+ 'tsunami-simple-timing',
+ 'tsunami-simple-atomic-dual',
+ 'tsunami-simple-timing-dual',
+ 'twosys-tsunami-simple-atomic',
+ 'tsunami-o3', 'tsunami-o3-dual']
if env['TARGET_ISA'] == 'sparc':
configs += ['t1000-simple-atomic',
't1000-simple-timing']
else:
configs += ['simple-atomic', 'simple-timing', 'o3-timing', 'memtest',
- 'simple-atomic-mp', 'simple-timing-mp']
+ 'simple-atomic-mp', 'simple-timing-mp', 'o3-timing-mp',
+ 'inorder-timing']
+
+if env['RUBY']:
+ # Hack for Ruby
+ configs += [c + '-ruby' for c in configs]
cwd = os.getcwd()
os.chdir(str(Dir('.').srcdir))
for config in configs:
dirs = glob.glob('*/*/ref/%s/*/%s' % (env['TARGET_ISA'], config))
for d in dirs:
- test_builder(env, d)
+ if not os.path.exists(os.path.join(d, 'skip')):
+ test_builder(env, d)
os.chdir(cwd)