Date: Thu, 17 Dec 2009 19:28:08 +1100 (EST) From: Bruce Evans <brde@optusnet.com.au> To: Bruce Evans <brde@optusnet.com.au> Cc: Harti Brandt <harti@FreeBSD.org>, John Baldwin <jhb@FreeBSD.org>, freebsd-arch@FreeBSD.org Subject: Re: network statistics in SMP Message-ID: <20091217191535.U36525@delplex.bde.org> In-Reply-To: <20091217181553.Q36492@delplex.bde.org> References: <20091215103759.P97203@beagle.kn.op.dlr.de> <200912150812.35521.jhb@freebsd.org> <20091215183859.S53283@beagle.kn.op.dlr.de> <200912151313.28326.jhb@freebsd.org> <20091217021211.O35780@delplex.bde.org> <20091217181553.Q36492@delplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 17 Dec 2009, Bruce Evans wrote: > On Thu, 17 Dec 2009, Bruce Evans wrote: > >> ... > Actually3, the generation count can be per-CPU and accessed without atomic > ops (provided reads of it on other CPUs return a consistent possibly-stale > value). > >> Simple version: > > Better version: > ... Duh, this is far too complicated and bloated. Counters can be their own generation counts -- you just read them again to see if they are quiescent. A heavyweight sync before each of the (sets of) reads is still necessary. Self-generation counters give a separate generation counter for each normal counter, so quiescence can be easily be checked for and/or enforced per-counter. Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20091217191535.U36525>