diff mbox series

[31/34] misc: don't put nr_cpus into the fsstress -n argument

Message ID 173870406579.546134.8370679231649475524.stgit@frogsfrogsfrogs (mailing list archive)
State New
Headers show
Series [01/34] generic/476: fix fsstress process management | expand

Commit Message

Darrick J. Wong Feb. 4, 2025, 9:30 p.m. UTC
From: Darrick J. Wong <djwong@kernel.org>

fsstress -n is the number of fs operations per process, not the total
number of operations.  There's no need to factor nr_cpus into the -n
argument because that causes excess runtime as core count increases.

Signed-off-by: "Darrick J. Wong" <djwong@kernel.org>
---
 tests/generic/476 |    2 +-
 tests/generic/642 |    2 +-
 tests/generic/750 |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

Comments

Dave Chinner Feb. 5, 2025, 1 a.m. UTC | #1
On Tue, Feb 04, 2025 at 01:30:23PM -0800, Darrick J. Wong wrote:
> From: Darrick J. Wong <djwong@kernel.org>
> 
> fsstress -n is the number of fs operations per process, not the total
> number of operations.  There's no need to factor nr_cpus into the -n
> argument because that causes excess runtime as core count increases.
> 
> Signed-off-by: "Darrick J. Wong" <djwong@kernel.org>
> ---
>  tests/generic/476 |    2 +-
>  tests/generic/642 |    2 +-
>  tests/generic/750 |    2 +-
>  3 files changed, 3 insertions(+), 3 deletions(-)

Looks good. That'll certainly help keep runtime down on large
machines.

Reviewed-by: Dave Chinner <dchinner@redhat.com>
diff mbox series

Patch

diff --git a/tests/generic/476 b/tests/generic/476
index 4537fcd77d2f07..13979127245c77 100755
--- a/tests/generic/476
+++ b/tests/generic/476
@@ -18,7 +18,7 @@  _scratch_mkfs > $seqres.full 2>&1
 _scratch_mount >> $seqres.full 2>&1
 
 nr_cpus=$((LOAD_FACTOR * 4))
-nr_ops=$((25000 * nr_cpus * TIME_FACTOR))
+nr_ops=$((25000 * TIME_FACTOR))
 fsstress_args=(-w -d $SCRATCH_MNT -n $nr_ops -p $nr_cpus)
 test -n "$SOAK_DURATION" && fsstress_args+=(--duration="$SOAK_DURATION")
 
diff --git a/tests/generic/642 b/tests/generic/642
index 4b92a9c181d49c..3c418aaa32bd23 100755
--- a/tests/generic/642
+++ b/tests/generic/642
@@ -20,7 +20,7 @@  _scratch_mkfs > $seqres.full 2>&1
 _scratch_mount >> $seqres.full 2>&1
 
 nr_cpus=$((LOAD_FACTOR * 4))
-nr_ops=$((70000 * nr_cpus * TIME_FACTOR))
+nr_ops=$((70000 * TIME_FACTOR))
 
 args=('-z' '-S' 'c')
 
diff --git a/tests/generic/750 b/tests/generic/750
index 5c54a5c7888f1d..a0828b50f3c7e4 100755
--- a/tests/generic/750
+++ b/tests/generic/750
@@ -37,7 +37,7 @@  _scratch_mkfs > $seqres.full 2>&1
 _scratch_mount >> $seqres.full 2>&1
 
 nr_cpus=$((LOAD_FACTOR * 4))
-nr_ops=$((25000 * nr_cpus * TIME_FACTOR))
+nr_ops=$((25000 * TIME_FACTOR))
 fsstress_args=(-w -d $SCRATCH_MNT -n $nr_ops -p $nr_cpus)
 test -n "$SOAK_DURATION" && fsstress_args+=(--duration="$SOAK_DURATION")