Date: Wed, 13 Dec 2000 10:21:41 -0800 (PST) From: John Baldwin <jhb@FreeBSD.ORG> To: "Justin T. Gibbs" <gibbs@scsiguy.com> Cc: arch@FreeBSD.ORG, Garrett Wollman <wollman@khavrinen.lcs.mit.edu> Subject: Re: An opaque refcount type Message-ID: <XFMail.001213102141.jhb@FreeBSD.org> In-Reply-To: <200012131539.eBDFdMs27981@aslan.scsiguy.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On 13-Dec-00 Justin T. Gibbs wrote: >>It's opaque in the sense that a user doesn't know what it is inside it. This >>means we can freely change around the implementation. For example, in the >>INVARIANTS case it adds in lots of extra checks, but to ensure correctness, >>it >>has to add in a mutex to use. > > My problem with it is that in the instances where you have to acquire > a mutex anyway to manage the data, you will not want to use this interface. > So, unlike say the LIST macros, there is no chance for our code to > standardize > on a single refcount API. Yes, I don't like that part of it either. In order to make it fast and lightweight it is not the swiss army knife of refcounts. If we don't use this, then probably we will just fall back to using a mutex for each refcount. -- John Baldwin <jhb@FreeBSD.org> -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.Baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.001213102141.jhb>