From 3c7022079f5a3a78abd5b5be838c42b7fe4121ac Mon Sep 17 00:00:00 2001 From: Adrian Pop Date: Thu, 8 Jul 2021 09:29:25 +0200 Subject: [PATCH] attempt to fix perl hangs and print some info (#7673) --- .CI/common.groovy | 2 +- testsuite/partest/runtests.pl | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.CI/common.groovy b/.CI/common.groovy index 6389eb98c84..d5e3d5d7166 100644 --- a/.CI/common.groovy +++ b/.CI/common.groovy @@ -79,7 +79,7 @@ void partest(cache=true, extraArgs='') { echo export OPENMODELICAHOME="\${MSYS_WORKSPACE}/build" echo export OPENMODELICALIBRARY="${MSYS_WORKSPACE}\\build\\lib\\omlibrary" echo cd ${MSYS_WORKSPACE}/testsuite/partest - echo time perl ./runtests.pl -j8 -nocolour -with-xml + echo time perl ./runtests.pl -nocolour -with-xml echo CODE=\$? echo if test "\$CODE\" = 0 -o "\$CODE" = 7; then echo cp -f ../runtest.db.* "${env.RUNTESTDB}/" diff --git a/testsuite/partest/runtests.pl b/testsuite/partest/runtests.pl index dbe3a0a32aa..dd6899d9c7f 100755 --- a/testsuite/partest/runtests.pl +++ b/testsuite/partest/runtests.pl @@ -323,6 +323,9 @@ sub run_tests { $test_queue->enqueue($_); } +# Signal that there is no more work to be sent +$test_queue->end(); + # Check if we can open /proc/cpuinfo to see how many cores are available, and # use that many threads instead. if ($check_proc_cpu) { @@ -361,8 +364,10 @@ sub run_tests { # Wait for the tests to finish. foreach my $thr (threads->list()) { $thr->join(); + print "{joined thread: " . $thr->tid() . "}" } + # Print out the list of tests that failed, and a summary of how many failed. print color 'reset'; print "\n";