From: Florian Krohm Date: Thu, 31 Oct 2024 23:31:27 +0000 (+0100) Subject: gsl19test does not work properly when /bin/sh is /bin/dash X-Git-Tag: VALGRIND_3_24_0~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=849dca0b4bef48e1f3640751b24d9e3e7f2d4aaf;p=thirdparty%2Fvalgrind.git gsl19test does not work properly when /bin/sh is /bin/dash There were 2 issues: 1) The output redirect operators seem to be bash specific. All output went to the terminal..... 2) When invoking valgrind the 'eval' needs to precede GSL_TEST_VERBOSE=1. Otherwise that environment variable is not seen by valgrind. Two tweaks: 1) Determine the number of available processors and use that in make -j when building gsl-1.9 2) Replace -v with -q in the valgrind invocation. The file out-V is already quite large (approx 600 MB). It would be enormous with -v. https://bugs.kde.org/show_bug.cgi?id=494960 --- diff --git a/NEWS b/NEWS index 54229dc57..52c66c8f7 100644 --- a/NEWS +++ b/NEWS @@ -83,6 +83,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 493959 s390x: Fix regtest failure for none/tests/s390x/op00 493970 s390x: Store/restore FPC upon helper call causes slowdown 494252 s390x: incorrect disassembly for LOCHI and friends +494960 Fixes and tweaks for gsl19test 495278 PowerPC instruction dcbf should allow the L field values of 4, 6 on ISA 3.0 and earlier, just ignore the value 495469 aligned_alloc and posix_memalign missing MALLOC_TRACE with returned diff --git a/auxprogs/gsl19test b/auxprogs/gsl19test index b97738f50..d111d379a 100755 --- a/auxprogs/gsl19test +++ b/auxprogs/gsl19test @@ -38,6 +38,13 @@ then exit 1 fi +# nproc is part of coreutils so it's available on GNU/Linux. Not so on Mac OS X. +command -v nproc > /dev/null +if [ $? -eq 0 ]; then + num_cpu=`nproc` +else + num_cpu=1 +fi runcmd () { echo -n " $1 ... " @@ -95,18 +102,18 @@ runcmd "Configuring " \ "(cd gsl-1.9 && CC=$GSL_CC CFLAGS=\"$GSL_CFLAGS\" ./configure)" && \ \ runcmd "Building " \ - "(cd gsl-1.9 && make && make -k check)" + "(cd gsl-1.9 && make -j $num_cpu && make -j $num_cpu -k check)" echo -n " Collecting reference results " rm -f out-REF (cd gsl-1.9 && for f in $ALL_TESTS ; \ - do GSL_TEST_VERBOSE=1 ./$f ; done) &> out-REF + do GSL_TEST_VERBOSE=1 ./$f ; done) > out-REF 2>&1 echo " ... done" echo -n " Collecting valgrinded results " rm -f out-V (cd gsl-1.9 && for f in $ALL_TESTS ; \ - do GSL_TEST_VERBOSE=1 eval $GSL_VV -v --trace-children=yes "$GSL_VFLAGS" ./$f ; done) &> out-V + do eval GSL_TEST_VERBOSE=1 $GSL_VV -q --trace-children=yes "$GSL_VFLAGS" ./$f ; done) > out-V 2>&1 echo " ... done" echo -n " Native fails: " && (grep FAIL: out-REF | wc -l)