Re: [PATCH 10/23] mkfs: don't hardcode log size

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]



On Tue, Jan 21, 2025 at 02:58:25PM +1100, Dave Chinner wrote:
> On Thu, Jan 16, 2025 at 03:27:46PM -0800, Darrick J. Wong wrote:
> > From: Darrick J. Wong <djwong@xxxxxxxxxx>
> > 
> > Commit 000813899afb46 hardcoded a log size of 256MB into xfs/501,
> > xfs/502, and generic/530.  This seems to be an attempt to reduce test
> > run times by increasing the log size so that more background threads can
> > run in parallel.  Unfortunately, this breaks a couple of my test
> > configurations:
> > 
> >  - External logs smaller than 256MB
> >  - Internal logs where the AG size is less than 256MB
> ....
> 
> > diff --git a/common/rc b/common/rc
> > index 9e34c301b0deb0..885669beeb5e26 100644
> > --- a/common/rc
> > +++ b/common/rc
> > @@ -689,6 +689,33 @@ _test_cycle_mount()
> >      _test_mount
> >  }
> >  
> > +# Are there mkfs options to try to improve concurrency?
> > +_scratch_mkfs_concurrency_options()
> > +{
> > +	local nr_cpus="$(( $1 * LOAD_FACTOR ))"
> 
> caller does not need to pass a number of CPUs. This function can
> simply do:
> 
> 	local nr_cpus=$(getconf _NPROCESSORS_CONF)
> 
> And that will set concurrency to be "optimal" for the number of CPUs
> in the machine the test is going to run on. That way tests don't
> need to hard code some number that is going to be too large for
> small systems and to small for large systems...

Sounds good to me.

--D

> -Dave.
> -- 
> Dave Chinner
> david@xxxxxxxxxxxxx
> 




[Index of Archives]     [Linux Filesystems Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux