From owner-freebsd-arch Thu Apr 19 9:47:48 2001 Delivered-To: freebsd-arch@freebsd.org Received: from smtp02.primenet.com (smtp02.primenet.com [206.165.6.132]) by hub.freebsd.org (Postfix) with ESMTP id 7B76E37B423 for ; Thu, 19 Apr 2001 09:47:38 -0700 (PDT) (envelope-from tlambert@usr08.primenet.com) Received: (from daemon@localhost) by smtp02.primenet.com (8.9.3/8.9.3) id JAA27197; Thu, 19 Apr 2001 09:40:22 -0700 (MST) Received: from usr08.primenet.com(206.165.6.208) via SMTP by smtp02.primenet.com, id smtpdAAAQ5aye1; Thu Apr 19 09:40:17 2001 Received: (from tlambert@localhost) by usr08.primenet.com (8.8.5/8.8.5) id JAA02940; Thu, 19 Apr 2001 09:47:52 -0700 (MST) From: Terry Lambert Message-Id: <200104191647.JAA02940@usr08.primenet.com> Subject: Re: Found BAD BUG: squashed To: dillon@earth.backplane.com (Matt Dillon) Date: Thu, 19 Apr 2001 16:47:52 +0000 (GMT) Cc: bde@zeta.org.au (Bruce Evans), tlambert@primenet.com (Terry Lambert), arch@FreeBSD.ORG In-Reply-To: <200104190755.f3J7taQ51976@earth.backplane.com> from "Matt Dillon" at Apr 19, 2001 12:55:36 AM X-Mailer: ELM [version 2.5 PL2] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > Ok. Since -current went from u_short to u_int, we should simply MFC > that change to stable after 4.3 is out the door. Now, I know you have > your heart set on your fancy overflow check Terry but I really think > going to a 32 bit counter is the best solution, especially as Bruce > pointed out it will not bloat the structure. We've been moving all our > other ref counts to 32 bits over the years... Note that Bruce's fix doesn't addres the invariant stomping the reference count, which makes checking for multiple frees impossible. The only way to fix that is to move the cr_ref out of the first two bytes. I would still like a general reference counting mechanism, so I could turn on overflow checking at runtime. As I said before, this is independent of whether the cred is duplicated near overflow, or the count pushes the overflow off to 4 billion (without preventing it). Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message