From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 22 07:40:45 2003 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D0E4A16A4B3 for ; Wed, 22 Oct 2003 07:40:45 -0700 (PDT) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by mx1.FreeBSD.org (Postfix) with ESMTP id E90F743F85 for ; Wed, 22 Oct 2003 07:40:44 -0700 (PDT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.12.9/8.12.9) id h9MEeild021914; Wed, 22 Oct 2003 09:40:44 -0500 (CDT) (envelope-from dan) Date: Wed, 22 Oct 2003 09:40:44 -0500 From: Dan Nelson To: Q Message-ID: <20031022144043.GI55642@dan.emsphone.com> References: <1066789354.21430.39.camel@boxster.onthenet.com.au> <20031022082953.GA69506@rot13.obsecurity.org> <1066816287.25609.34.camel@boxster.onthenet.com.au> <20031022095754.GA70026@rot13.obsecurity.org> <1066820436.25609.93.camel@boxster.onthenet.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1066820436.25609.93.camel@boxster.onthenet.com.au> X-OS: FreeBSD 5.1-CURRENT X-message-flag: Outlook Error User-Agent: Mutt/1.5.4i cc: freebsd-hackers@freebsd.org cc: Kris Kennaway Subject: Re: Some mmap observations compared to Linux 2.6/OpenBSD X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Oct 2003 14:40:46 -0000 In the last episode (Oct 22), Q said: > Yes, it would appear this is a legacy thing that existed in the > original 1994 import of the BSD 4.4 Lite source. Both FreeBSD and > NetBSD still use this technique, but OpenBSD changed to using > Red-Black trees back in Feb 2002. > > The actual commit quote reads: > > "use a red-black tree to find entries in the vm_map. augment the > red-black tree to find free space between entries. speeds up memory > allocation, etc..." > > I am wondering if there is a compelling reason why the technique used > by OpenBSD could not be adapted to FreeBSD's VM system. Probably just a case of "too much to do and not enough people to do it". FreeBSD already has sys/tree.h, which provides the red-black tree macros. -- Dan Nelson dnelson@allantgroup.com