Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Jul 2001 03:19:48 +1000 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        Ian Dowse <iedowse@maths.tcd.ie>
Cc:        freebsd-current@FreeBSD.ORG
Subject:   Re: Load average synchronisation and phantom loads
Message-ID:  <Pine.BSF.4.21.0107180242310.67803-100000@besplex.bde.org>
In-Reply-To: <200107152319.aa46183@salmon.maths.tcd.ie>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 15 Jul 2001, Ian Dowse wrote:

> The patch below causes the samples of running processes to be
> somewhat randomised; instead of being taken every 5 seconds, the
> gap now varies in the range 4 to 6 seconds, so that synchronisation
> should no longer occur. Would there be any objections to my committing
> this?

I think that is far too much variation.  5 seconds is hard-coded into
the computation of the load average (constants in cexp[]), so even a
variation of +-1 ticks breaks the computation slightly.

> Index: vm/vm_meter.c
> ===================================================================
> RCS file: /dump/FreeBSD-CVS/src/sys/vm/vm_meter.c,v
> retrieving revision 1.57
> diff -u -r1.57 vm_meter.c
> --- vm/vm_meter.c	2001/07/04 19:00:12	1.57
> +++ vm/vm_meter.c	2001/07/15 20:54:38
> ...
> +SYSINIT(loadav, SI_SUB_PSEUDO, SI_ORDER_ANY, loadav_init, NULL)

Not another SYSINIT (all SYSINITs are evil IMO).  SI_SUB_PSEUDO is
bogus here -- there are no pseudo ttys here.  sched_setup() is a
good place to do this initialization.

> +
>  

Extra blank line.

Bruce


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0107180242310.67803-100000>