[LNT] r292527 - Builds are not clean between repeated runs
A Bergen via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 19 14:34:50 PST 2017
Author: sudofortune
Date: Thu Jan 19 16:34:50 2017
New Revision: 292527
URL: http://llvm.org/viewvc/llvm-project?rev=292527&view=rev
Log:
Builds are not clean between repeated runs
Motivation:
When doing a compile multiple times in a row only the first build is actually happening.
All subsequent runs to build do nothing as make detects that none of the files have changed.
What changed:
This deletes the entire build directory before each compile happens, thereby ensuring that each run has a clean build.
Since the build directory is deleted before the compile, the "last" build directory is kept. In case there is a failure this build directory can be used to look at what happened.
To delete the build directory I am using the -p flag of runN to perform the cleaning before the timing run.
Differential Revision: https://reviews.llvm.org/D28882
Modified:
lnt/trunk/lnt/tests/compile.py
Modified: lnt/trunk/lnt/tests/compile.py
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/lnt/tests/compile.py?rev=292527&r1=292526&r2=292527&view=diff
==============================================================================
--- lnt/trunk/lnt/tests/compile.py (original)
+++ lnt/trunk/lnt/tests/compile.py Thu Jan 19 16:34:50 2017
@@ -53,6 +53,7 @@ def runN(args, N, cwd, preprocess_cmd=No
FIXME: Figure out a better way to deal with need to run as root. Maybe farm
memory sampling process out into something we can setuid? Eek.
"""
+ g_log.info("preprocess_cmd at top of runN: %s:", preprocess_cmd)
cmd = ['runN', '-a']
if sample_mem:
cmd = ['sudo'] + cmd + ['-m']
@@ -473,6 +474,9 @@ def test_build(base_name, run_info, vari
# Set build base to copied_src_dir so that if codesize_util
# is not None, we pass it the correct path.
build_base = copied_src_dir
+ preprocess_cmd = 'rm -rf "%s"/build' % (build_base,)
+ g_log.info('preprocess_cmd: %s' % preprocess_cmd)
+
else:
fatal("unknown build style in project: %r" % project)
More information about the llvm-commits
mailing list