From nobody Sat Aug 17 11:24:16 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WmGj157Ytz5SrCl; Sat, 17 Aug 2024 11:24:21 +0000 (UTC) (envelope-from pho@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WmGj14Fw4z4Tn9; Sat, 17 Aug 2024 11:24:21 +0000 (UTC) (envelope-from pho@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1723893861; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=5jQE4G3C1c0lrAhrFPEaR5E5VTVncBYw4S6Y54F7yvA=; b=IGFjfaVNDxNW9oELAddOjFsIZx1Vp3qVo2k/YmeOjgmgQrX++jWYRaUH7O2+qMYHfmkAYt fiahZV9roPPG4OgBHP2EyOqVp+VOKgfIfr13GEEXYAAVQ/zeIcGpEz6+euXIRSOUCN+zai K4r4vQIEtMa8BrkFnplWGSReyLsyJHTlmr9xERINtpcdumt66SFacq4uYCr3KaF3KuwkU8 b48vkyOF4220O95iCzYF1SkjaFT7V2SBVWmiDMbxI4D42qH+kbGu8G6rQfmr2I8p5qYaP9 F4E3jp0yLhgQ9Ekwlr+ow0bw2XTxaEh29JAyeRtbmYtuh3c++snaNz6qBsfwng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1723893861; a=rsa-sha256; cv=none; b=WNs3cdmExOCSQszYqTuWXncvwbxOKgLrJpX4SIZ2mwLKOfcAXQSU0fsEHFQjF5loM8Cj9s 7Gwjbfpv/8jvuHhNoV4aVvZQfraTaRpGCrMCsF7Jd3lnmT5ZlSf0GngWf7XiiRw5v4UmG/ pmZgBzrLfi8jChR/1Wocu4Ed+DgqjUcTju9x6CIDpx/QE2uMuKqQDzLCuccP2RDMxBh8al f7jyaSo8y6Hxj9zz95+jCSafb2X9ntPiDdCslcRcIGgIgba8xJE+b9Op3L31ruYrtV1gxg upICPThiNjvw7TeXu4wCMrs4ZBH6619hPTyeu0ScJZGHD8o4ZO8ftz1PVaehxg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1723893861; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=5jQE4G3C1c0lrAhrFPEaR5E5VTVncBYw4S6Y54F7yvA=; b=AdiLYyL5irvhodbfqTYGh+7T3XvWByB/9nU+Fb2fBoPO3p4AF7OpGrNcBEs+kzwmRc6L7H jUcdZDRwUwyg9ikdIp9qfltKlqcVXObuw9g7I/PzQTrDFbjyqY2RDBhN5qvzsdlXG7GXFv PuSa/rJ3oAD3Xv6DUMOMVUBCpyNKTKOU828n0IG/0WRedNORX8tRM6onIGcgAKB6nzNxQo FdAJf0h1huaOihGaVIkNMeX+1lw2zPM4XukqUSGiXWyy61+q7MdijGbr8+dTKB7W3wq7Q8 5fg7G7zVR/DOUB2tmcS5+sJN9AEAPBtS0YlApkM1o5U9xthx1mKGq4ALgSi0JQ== Received: from Peters-Air (c-x5996a268.customers.hiper-net.dk [89.150.162.104]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: pho) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WmGj05lX0zTy3; Sat, 17 Aug 2024 11:24:20 +0000 (UTC) (envelope-from pho@FreeBSD.org) Date: Sat, 17 Aug 2024 13:24:16 +0200 From: Peter Holm To: Ronald Klop Cc: Peter Holm , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: c7bc30c24f86 - main - stress2: Some tests use hw.ncpu to scale the load. Tests on a box with a large number of CPUs show that this number needs to be capped Message-ID: References: <202408170638.47H6cT60006976@gitrepo.freebsd.org> <1938701047.3129.1723883923856@localhost> List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1938701047.3129.1723883923856@localhost> On Sat, Aug 17, 2024 at 10:38:43AM +0200, Ronald Klop wrote: > Interesting. Why the cap? > Can you explain what happened in the tests? > The main reason was that the tests took too long to run. For the test using parallel make, I suspect disk saturation is the cause. - Peter > Regards, > Ronald. > > Van: Peter Holm > Datum: 17 augustus 2024 08:38 > Aan: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org > Onderwerp: git: c7bc30c24f86 - main - stress2: Some tests use hw.ncpu to scale the load. Tests on a box with a large number of CPUs show that this number needs to be capped > > > > > > > The branch main has been updated by pho: > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=c7bc30c24f8625c6e9ef41be427fa26c6eb3d2bf > > > > commit c7bc30c24f8625c6e9ef41be427fa26c6eb3d2bf > > Author: Peter Holm AuthorDate: 2024-08-17 06:37:34 +0000 > > Commit: Peter Holm CommitDate: 2024-08-17 06:37:34 +0000 > > > > stress2: Some tests use hw.ncpu to scale the load. Tests on a box with > > a large number of CPUs show that this number needs to be capped > > --- > > tools/test/stress2/misc/buildkernel.sh | 1 + > > tools/test/stress2/misc/buildworld.sh | 1 + > > tools/test/stress2/misc/buildworld2.sh | 1 + > > tools/test/stress2/misc/buildworld3.sh | 1 + > > tools/test/stress2/misc/buildworld4.sh | 1 + > > tools/test/stress2/misc/crossmp3.sh | 1 + > > tools/test/stress2/misc/crossmp4.sh | 1 + > > tools/test/stress2/misc/crossmp5.sh | 1 + > > tools/test/stress2/misc/crossmp8.sh | 1 + > > tools/test/stress2/misc/gnop4.sh | 3 +++ > > tools/test/stress2/misc/tmpfs13.sh | 1 + > > tools/test/stress2/misc/zzbuildworld.sh | 1 + > > 12 files changed, 14 insertions(+) > > > > diff --git a/tools/test/stress2/misc/buildkernel.sh b/tools/test/stress2/misc/buildkernel.sh > > index 849a09b81439..e0aa85617f9b 100755 > > --- a/tools/test/stress2/misc/buildkernel.sh > > +++ b/tools/test/stress2/misc/buildkernel.sh > > @@ -49,6 +49,7 @@ chmod 0777 $TMPDIR > > log=$mntpoint/log > > p=$((`sysctl -n hw.ncpu`+ 1)) > > +[ $p -gt 32 ] && p=32 # Arbitrary cap > > p=`jot -r 1 1 $p` > > echo "make -j $p buildkernel KERNCONF=GENERIC DESTDIR=$mntpoint" > > "TARGET=amd64 TARGET_ARCH=amd64" > > diff --git a/tools/test/stress2/misc/buildworld.sh b/tools/test/stress2/misc/buildworld.sh > > index 595b387c90ae..3b362ec7041a 100755 > > --- a/tools/test/stress2/misc/buildworld.sh > > +++ b/tools/test/stress2/misc/buildworld.sh > > @@ -55,6 +55,7 @@ mkdir $TMPDIR > > chmod 0777 $TMPDIR > > p=$((`sysctl -n hw.ncpu`+ 1)) > > +[ $p -gt 32 ] && p=32 # Arbitrary cap > > timeout 20m make -i -j $p buildworld DESTDIR=$mntpoint TARGET=amd64 > > TARGET_ARCH=amd64 > /dev/null > > diff --git a/tools/test/stress2/misc/buildworld2.sh b/tools/test/stress2/misc/buildworld2.sh > > index 9c1eed97b7ea..3653cb1db5b4 100755 > > --- a/tools/test/stress2/misc/buildworld2.sh > > +++ b/tools/test/stress2/misc/buildworld2.sh > > @@ -46,6 +46,7 @@ mkdir $TMPDIR > > chmod 0777 $TMPDIR > > p=$((`sysctl -n hw.ncpu`+ 1)) > > +[ $p -gt 32 ] && p=32 # Arbitrary cap > > make -j $p buildworld DESTDIR=$mntpoint TARGET=amd64 TARGET_ARCH=amd64 > > > /dev/null & > > sleep $((20 * 60)) > > diff --git a/tools/test/stress2/misc/buildworld3.sh b/tools/test/stress2/misc/buildworld3.sh > > index 0c660cae8eae..e3bce2764c0c 100755 > > --- a/tools/test/stress2/misc/buildworld3.sh > > +++ b/tools/test/stress2/misc/buildworld3.sh > > @@ -62,6 +62,7 @@ mkdir $TMPDIR $MAKEOBJDIRPREFIX > > chmod 0777 $TMPDIR $MAKEOBJDIRPREFIX > > p=$((`sysctl -n hw.ncpu`+ 1)) > > +[ $p -gt 32 ] && p=32 # Arbitrary cap > > su $testuser -c "make -i -j $p buildworld DESTDIR=$mntpoint > > TARGET=amd64 TARGET_ARCH=amd64 > /dev/null" & > > diff --git a/tools/test/stress2/misc/buildworld4.sh b/tools/test/stress2/misc/buildworld4.sh > > index 6c15a72a9dcb..d1d162120952 100755 > > --- a/tools/test/stress2/misc/buildworld4.sh > > +++ b/tools/test/stress2/misc/buildworld4.sh > > @@ -50,6 +50,7 @@ mkdir $TMPDIR > > chmod 0777 $TMPDIR > > p=$((`sysctl -n hw.ncpu`+ 1)) > > +[ $p -gt 16 ] && p=16 # Arbitrary cap > > [ `sysctl -n vm.swap_total` -gt 0 ] && p=$((p * 4)) > > p=`jot -r 1 1 $p` > > echo "make -i -j $p buildworld DESTDIR=$mntpoint TARGET=amd64 " > > diff --git a/tools/test/stress2/misc/crossmp3.sh b/tools/test/stress2/misc/crossmp3.sh > > index 5eecb936e900..32c625a1e4ad 100755 > > --- a/tools/test/stress2/misc/crossmp3.sh > > +++ b/tools/test/stress2/misc/crossmp3.sh > > @@ -41,6 +41,7 @@ > > CONT=/tmp/crossmp3.continue > > if [ $# -eq 0 ]; then > > N=`sysctl -n hw.ncpu` > > + [ $N -gt 32 ] && N=32 # Arbitrary cap > > usermem=`sysctl -n hw.usermem` > > [ `sysctl -n vm.swap_total` -eq 0 ] && usermem=$((usermem / 2)) > > size=$((usermem / 1024 / 1024 / N)) > > diff --git a/tools/test/stress2/misc/crossmp4.sh b/tools/test/stress2/misc/crossmp4.sh > > index e22f969b72bb..21d22bee69e5 100755 > > --- a/tools/test/stress2/misc/crossmp4.sh > > +++ b/tools/test/stress2/misc/crossmp4.sh > > @@ -40,6 +40,7 @@ > > . ../default.cfg > > N=`sysctl -n hw.ncpu` > > +[ $N -gt 32 ] && N=32 # Arbitrary cap > > usermem=`sysctl -n hw.usermem` > > [ `swapinfo | wc -l` -eq 1 ] && usermem=$((usermem/100*80)) > > size=$((usermem / 1024 / 1024 - 2)) > > diff --git a/tools/test/stress2/misc/crossmp5.sh b/tools/test/stress2/misc/crossmp5.sh > > index 038dea7ebe4f..6e504d9f20ad 100755 > > --- a/tools/test/stress2/misc/crossmp5.sh > > +++ b/tools/test/stress2/misc/crossmp5.sh > > @@ -33,6 +33,7 @@ > > . ../default.cfg > > N=`sysctl -n hw.ncpu` > > +[ $N -gt 32 ] && N=32 # Arbitrary cap > > usermem=`sysctl -n hw.usermem` > > [ `swapinfo | wc -l` -eq 1 ] && usermem=$((usermem/100*80)) > > size=$((usermem / 1024 / 1024 / N)) > > diff --git a/tools/test/stress2/misc/crossmp8.sh b/tools/test/stress2/misc/crossmp8.sh > > index e877dfaf6d1c..eec5ba9bc7c1 100755 > > --- a/tools/test/stress2/misc/crossmp8.sh > > +++ b/tools/test/stress2/misc/crossmp8.sh > > @@ -41,6 +41,7 @@ > > CONT=/tmp/crossmp8.continue > > N=`sysctl -n hw.ncpu` > > +[ $N -gt 32 ] && N=32 # Arbitrary cap > > usermem=`sysctl -n hw.usermem` > > [ `swapinfo | wc -l` -eq 1 ] && usermem=$((usermem/100*80)) > > size=$((usermem / 1024 / 1024 / N)) > > diff --git a/tools/test/stress2/misc/gnop4.sh b/tools/test/stress2/misc/gnop4.sh > > index f938dd3b790b..1b4da74266f6 100755 > > --- a/tools/test/stress2/misc/gnop4.sh > > +++ b/tools/test/stress2/misc/gnop4.sh > > @@ -34,6 +34,8 @@ > > # https://people.freebsd.org/~pho/stress/log/kostik1017.txt > > # Fixed by r322175 > > +# Seen with p=513: Threads stuck in "ffsrca" > > + > > . ../default.cfg > > gigs=9 > > @@ -62,6 +64,7 @@ cd $mntpoint/src > > export MAKEOBJDIRPREFIX=$mntpoint/obj > > p=$((`sysctl -n hw.ncpu`+ 1)) > > +[ $p -gt 32 ] && p=32 # Temporary work around > > timeout 10m make -i -j $p buildworld DESTDIR=$mntpoint > > TARGET=amd64 TARGET_ARCH=amd64 > /dev/null > > diff --git a/tools/test/stress2/misc/tmpfs13.sh b/tools/test/stress2/misc/tmpfs13.sh > > index 29b44cbc9ad4..231c42033f9d 100755 > > --- a/tools/test/stress2/misc/tmpfs13.sh > > +++ b/tools/test/stress2/misc/tmpfs13.sh > > @@ -40,6 +40,7 @@ > > . ../default.cfg > > N=`sysctl -n hw.ncpu` > > +[ $N -gt 32 ] && N=32 # Arbitrary cap > > usermem=`sysctl -n hw.usermem` > > [ `swapinfo | wc -l` -eq 1 ] && usermem=$((usermem/100*80)) > > size=$((usermem / 1024 / 1024 / 2)) > > diff --git a/tools/test/stress2/misc/zzbuildworld.sh b/tools/test/stress2/misc/zzbuildworld.sh > > index 2104eb156c86..e1bf867d8d5f 100755 > > --- a/tools/test/stress2/misc/zzbuildworld.sh > > +++ b/tools/test/stress2/misc/zzbuildworld.sh > > @@ -44,6 +44,7 @@ top=$mntpoint > > export MAKEOBJDIRPREFIX=$top/obj > > export log=$top/buildworld.`date +%Y%m%dT%H%M` > > n=$((`sysctl -n hw.ncpu` + 1)) > > +[ $n -gt 32 ] && n=32 # Arbitrary cap > > cd $src > > make -j$n buildworld > $log 2>&1 && s=0 ||s=1 > > grep '***' $log && s=2 > > > > > > > > > >