Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Sep 1997 09:58:54 -0600
From:      "Justin T. Gibbs" <gibbs@plutotech.com>
To:        Terry Lambert <tlambert@primenet.com>
Cc:        gibbs@plutotech.com (Justin T. Gibbs), nate@mt.sri.com, current@FreeBSD.ORG
Subject:   Re: cvs commit: src/sys/conf files src/sys/dev/vx if_vx.c if_vxreg.h src/sys/i386/apm apm.c src/sys/i386/conf GENERIC files.i386 
Message-ID:  <199709221559.JAA17865@pluto.plutotech.com>
In-Reply-To: Your message of "Mon, 22 Sep 1997 06:47:44 -0000." <199709220647.XAA16869@usr07.primenet.com> 

next in thread | previous in thread | raw e-mail | index | archive | help
>A more deterministic implementation would associate an absolute tick
>value (rather than a count) with each entry, and insert entries in
>sorted order.

More deterministic for who?  This trades O(1) insertion for O(hash chain
length) insertion so that softclock will become O(timeouts for the current 
tick).  As timeout often is called from an interrupt context
it is not so clear where it is better to pay the price of non-determinism.
Softclock has the luxury of lowering it's spl at deterministic intervals
(see the implementation) while a caller from an interrupt context doesn't.
the current implementation always blocks interrupts for a deterministic
amount of time.  What you propose doesn't.

Even so, it is probably better to store an absolute tick value regardless
so that you don't have to perform the subtraction.

If and when we decide that we need higher resolution timer facilities, we can 
decide if a non-deterministic timeout() is an acceptable cost for that 
feature.

>					Terry Lambert
>					terry@lambert.org
>---
>Any opinions in this posting are my own and not those of my present
>or previous employers.

--
Justin T. Gibbs
===========================================
  FreeBSD: Turning PCs into workstations
===========================================





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199709221559.JAA17865>