[llvm-commits] [test-suite] r151258 - in /test-suite/trunk: Makefile.programs instant.txt
Duncan Sands
baldrick at free.fr
Thu Feb 23 09:02:50 PST 2012
Author: baldrick
Date: Thu Feb 23 11:02:50 2012
New Revision: 151258
URL: http://llvm.org/viewvc/llvm-project?rev=151258&view=rev
Log:
The nightly test scripts get confused by tests like siod that make
use of reference output because there is no accompanying time info
for how long the native run took. Make such tools happy by creating
fake timing info for such tests.
Added:
test-suite/trunk/instant.txt
Modified:
test-suite/trunk/Makefile.programs
Modified: test-suite/trunk/Makefile.programs
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/Makefile.programs?rev=151258&r1=151257&r2=151258&view=diff
==============================================================================
--- test-suite/trunk/Makefile.programs (original)
+++ test-suite/trunk/Makefile.programs Thu Feb 23 11:02:50 2012
@@ -828,8 +828,10 @@
# Because we don't have source code, we cannot build a native version of the
# executable. Copy over pregenerated reference output.
$(PROGRAMS_TO_TEST:%=Output/%.out-nat): \
-Output/%.out-nat: $(SRCDIR)/%.reference_output Output/.dir
+Output/%.out-nat: $(SRCDIR)/%.reference_output Output/.dir $(PROJ_SRC_ROOT)/instant.txt
cp $< $@
+ # Pretend that the reference output was produced instantaneously.
+ cp $(PROJ_SRC_ROOT)/instant.txt $@.time
$(PROGRAMS_TO_TEST:%=Output/%.LOC.txt): \
Output/%.LOC.txt: $(SRCDIR)/%.LOC.txt Output/.dir
@@ -842,8 +844,10 @@
# If a reference output file is specified, use that.
ifdef REFERENCE_OUTPUT_FILE
-Output/%.out-nat: $(REFERENCE_OUTPUT_FILE) Output/.dir
+Output/%.out-nat: $(REFERENCE_OUTPUT_FILE) Output/.dir $(PROJ_SRC_ROOT)/instant.txt
cp $< $@
+ # Pretend that the reference output was produced instantaneously.
+ cp $(PROJ_SRC_ROOT)/instant.txt $@.time
else
@@ -851,7 +855,7 @@
# 'progamname.reference_output'.
#
# Note that this rule needs to be in both Makefile.programs and Makefile.spec.
-Output/%.out-nat: Output/.dir
+Output/%.out-nat: Output/.dir $(PROJ_SRC_ROOT)/instant.txt
-if [ -f "$(PROJ_SRC_DIR)/$*.reference_output.$(REFERENCE_OUTPUT_KEY)" ]; then \
cp $(PROJ_SRC_DIR)/$*.reference_output.$(REFERENCE_OUTPUT_KEY) $@; \
elif [ -f "$(PROJ_SRC_DIR)/$*.reference_output" ]; then \
@@ -861,6 +865,8 @@
cp $(PROJ_SRC_ROOT)/default.reference_output $@; \
cat $@; \
fi
+ # Pretend that the reference output was produced instantaneously.
+ cp $(PROJ_SRC_ROOT)/instant.txt $@.time
endif
Added: test-suite/trunk/instant.txt
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/instant.txt?rev=151258&view=auto
==============================================================================
--- test-suite/trunk/instant.txt (added)
+++ test-suite/trunk/instant.txt Thu Feb 23 11:02:50 2012
@@ -0,0 +1,5 @@
+exit 0
+real 0.00
+user 0.00
+sys 0.00
+program 0.000000
More information about the llvm-commits
mailing list