From owner-freebsd-hackers Thu Jul 26 10:17:37 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from falcon.mail.pas.earthlink.net (falcon.mail.pas.earthlink.net [207.217.120.74]) by hub.freebsd.org (Postfix) with ESMTP id 271B037B407 for ; Thu, 26 Jul 2001 10:17:35 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.245.129.59.Dial1.SanJose1.Level3.net [209.245.129.59]) by falcon.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id KAA07432; Thu, 26 Jul 2001 10:17:30 -0700 (PDT) Message-ID: <3B6050D1.9DCCD23@mindspring.com> Date: Thu, 26 Jul 2001 10:18:09 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bosko Milekic Cc: Zhihui Zhang , vishwanath pargaonkar , freebsd-hackers@FreeBSD.ORG Subject: Re: cluster size References: <20010725140737.A25132@technokratis.com> <20010725143649.A25300@technokratis.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bosko Milekic wrote: > > On Wed, Jul 25, 2001 at 02:17:38PM -0400, Zhihui Zhang wrote: > > > > I see. It has something to do with the power-of-two allocator we are > > using inside the kernel. > > No, it has nothing to do with the power-of-two allocation strategy > used in some cases inside the kernel. 2K is just the most convenient size > for a cluster as it fits the maximum MTU size while at the same time fitting > nicely into a page, reducing allocation complexity. Specifically, it saves a lot of housekeeping, which isn't really a lot, if it's done correctly. Actually, we would be well serverd by permitting odd-sized mbufs, particularly for use a mbuf cluster containers, since they waste an incredible amount of space. The real reason behind all this is to make the input and output routines symmetric, since mbuf's can be allocated at interrupt, and clusters can't (or couldn't, last time I looked at 4.3). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message