|
@@ -102,6 +102,9 @@ C_SUBDIR=$(TEST_OS_TARGET)/$(TEST_CPU_TARGET)
|
|
# Date and time the testsuite was run
|
|
# Date and time the testsuite was run
|
|
ifneq ($(DATE),__missing_command_DATE)
|
|
ifneq ($(DATE),__missing_command_DATE)
|
|
TEST_DATETIME:=$(shell $(DATE) +%Y%m%d%H%M)
|
|
TEST_DATETIME:=$(shell $(DATE) +%Y%m%d%H%M)
|
|
|
|
+else
|
|
|
|
+# Use a spaceless string, as it will be used for file names
|
|
|
|
+TEST_DATETIME="No-date"
|
|
endif
|
|
endif
|
|
|
|
|
|
ifndef TEST_USER
|
|
ifndef TEST_USER
|
|
@@ -464,7 +467,9 @@ allexectests: $(TEST_OUTPUTDIR)/log.testlog $(TEST_OUTPUTDIR)/log.tbslog $(TEST
|
|
# SINGLEDOTESTRUNS
|
|
# SINGLEDOTESTRUNS
|
|
else
|
|
else
|
|
|
|
|
|
-.PHONY: allexectests
|
|
|
|
|
|
+.PHONY: allexectests gparmake_allexectests
|
|
|
|
+
|
|
|
|
+MAKEINC=$(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc
|
|
|
|
|
|
$(GPARMAKE): $(COMPILER_UNITTARGETDIR) utils/gparmake.pp
|
|
$(GPARMAKE): $(COMPILER_UNITTARGETDIR) utils/gparmake.pp
|
|
$(FPC) $(FPCOPT) -FE. utils/gparmake.pp $(OPT)
|
|
$(FPC) $(FPCOPT) -FE. utils/gparmake.pp $(OPT)
|
|
@@ -481,28 +486,38 @@ $(GPARMAKE): $(COMPILER_UNITTARGETDIR) utils/gparmake.pp
|
|
# As a result, we list TEST_OUTPUTDIR as a dependency (that just creates
|
|
# As a result, we list TEST_OUTPUTDIR as a dependency (that just creates
|
|
# the directory) and have an explicit rule to build GPARMAKE rather than
|
|
# the directory) and have an explicit rule to build GPARMAKE rather than
|
|
# building it via the utils Makefile
|
|
# building it via the utils Makefile
|
|
-$(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc: $(GPARMAKE) $(TEST_OUTPUTDIR)
|
|
|
|
|
|
+$(MAKEINC): $(GPARMAKE) $(TEST_OUTPUTDIR)
|
|
# generate rules for parallel executions of dotest
|
|
# generate rules for parallel executions of dotest
|
|
- $(Q)$(GPARMAKE) $(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc 1 $(CHUNKSIZE) $(sort $(wildcard $(addsuffix /t*.pp,$(TESTDIRS))))
|
|
|
|
- $(Q)$(GPARMAKE) -a $(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc 100000 $(CHUNKSIZE) $(sort $(wildcard tbs/t*.pp))
|
|
|
|
- $(Q)$(GPARMAKE) -a $(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc 150000 $(CHUNKSIZE) $(sort $(wildcard tbf/t*.pp))
|
|
|
|
- $(Q)$(GPARMAKE) -a $(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc 200000 $(CHUNKSIZE) $(sort $(wildcard webtbs/t*.pp))
|
|
|
|
- $(Q)$(GPARMAKE) -a $(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc 300000 $(CHUNKSIZE) $(sort $(wildcard webtbf/t*.pp))
|
|
|
|
|
|
+# gparmake now also needs an additional parameter for the name of the
|
|
|
|
+# used subdirectory. Note also that the index must be increasing for each
|
|
|
|
+# new call with a gap insuring that all the previous files have lower index
|
|
|
|
+# even if CHUNKSIZE is equal to 1.
|
|
|
|
+ $(Q)$(GPARMAKE) $(MAKEINC) test 1 $(CHUNKSIZE) $(sort $(wildcard $(addsuffix /t*.pp,$(TESTDIRS))))
|
|
|
|
+ $(Q)$(GPARMAKE) -a $(MAKEINC) tbs 10000 $(CHUNKSIZE) $(sort $(wildcard tbs/t*.pp))
|
|
|
|
+ $(Q)$(GPARMAKE) -a $(MAKEINC) tbf 15000 $(CHUNKSIZE) $(sort $(wildcard tbf/t*.pp))
|
|
|
|
+ $(Q)$(GPARMAKE) -a $(MAKEINC) webtbs 20000 $(CHUNKSIZE) $(sort $(wildcard webtbs/t*.pp))
|
|
|
|
+ $(Q)$(GPARMAKE) -a $(MAKEINC) webtbf 30000 $(CHUNKSIZE) $(sort $(wildcard webtbf/t*.pp))
|
|
|
|
|
|
|
|
|
|
# only include the targets to compile/run the tests when we want to
|
|
# only include the targets to compile/run the tests when we want to
|
|
# run them (in particular: not when cleaning)
|
|
# run them (in particular: not when cleaning)
|
|
ifneq (,$(findstring all,$(MAKECMDGOALS)))
|
|
ifneq (,$(findstring all,$(MAKECMDGOALS)))
|
|
|
|
+ifneq (,$(wildcard $(MAKEINC)))
|
|
# incude the rules we just generated
|
|
# incude the rules we just generated
|
|
include $(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc
|
|
include $(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc
|
|
endif
|
|
endif
|
|
|
|
+endif
|
|
|
|
|
|
|
|
|
|
-
|
|
|
|
-# this is pretty cool: MakeChunks-$(TEST_TARGETSUFFIX).inc will contain additional prerequisites
|
|
|
|
-# for the allexectests target, and after it is generated it will be included by the above "include"
|
|
|
|
-# statement, and those additional prerquisites will be added on the fly and also be evaluated
|
|
|
|
-allexectests: $(TEST_OUTPUTDIR)/MakeChunks-$(TEST_TARGETSUFFIX).inc
|
|
|
|
|
|
+# this is pretty cool: MakeChunks-$(TEST_TARGETSUFFIX).inc will contain
|
|
|
|
+# additional prerequisites for the allexectests target, and after it is
|
|
|
|
+# generated it will be included by the above "include" statement, and those
|
|
|
|
+# additional prerequisites will be added on the fly and also be evaluated.
|
|
|
|
+# However, to avoid problems on some targets that seem to have problems
|
|
|
|
+# handling missing include files, we first create MAKEINC file
|
|
|
|
+# and rerun MAKE with gparmake_allexectests target.
|
|
|
|
+allexectests: $(MAKEINC)
|
|
|
|
+ $(MAKE) gparmake_allexectests
|
|
|
|
|
|
# SINGLEDOTESTRUNS
|
|
# SINGLEDOTESTRUNS
|
|
endif
|
|
endif
|