*BSD News Article 69398


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!news.cs.su.oz.au!metro!metro!munnari.OZ.AU!news.hawaii.edu!ames!enews.sgi.com!news.mathworks.com!newsfeed.internetmci.com!newsxfer2.itd.umich.edu!agate!reason.cdrom.com!usenet
From: "Jordan K. Hubbard" <jkh@FreeBSD.org>
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: Linux vs. FreeBSD ... (FreeBSD extremely mem/swap hungry)
Date: Sat, 25 May 1996 13:54:49 -0700
Organization: Walnut Creek CDROM
Lines: 67
Message-ID: <31A77399.167EB0E7@FreeBSD.org>
References: <3188C1E2.45AE@onramp.net> <4n0dhd$cff@agate.berkeley.edu> <3194622D.41C67EA6@Ami-chan.res.cmu.edu> <31A52667.794BDF32@zeus.co.uk> <4o3ftc$4rc@zot.io.org> <31A5A8F6.15FB7483@zeus.co.uk> <31A5D0A8.59E2B600@zeus.co.uk>
NNTP-Posting-Host: time.cdrom.com
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Mailer: Mozilla 3.0b4 (X11; I; FreeBSD 2.2-CURRENT i386)
To: Damian Reeves <damian@zeus.co.uk>

Damian Reeves wrote:
> This was a mail response sent to me directly, but I thought I'd post it
> here as well for further discussion.

I rather wish you hadn't, actually.  This newsgroups is noisy enough as
it is! :-)

> "Our program is so old, no one who wrote the internals is even alive
>  anymore, we couldn't possibly alter them, let alone describe the
>  design decisions that contributed to this large chunk of code we
>  don't understand."

You must be ascribing this point of view to some fictional person, since
none of the people actually _responsible_ for the VM system in FreeBSD
feel this way.  I wonder just what it is you're trying to say.

> You obviously don't understand the workings of the BSD kernel memory
> manager, and how it compares with that under Linux.

No, he didn't, that was quite obvious.  Unfortunately, neither do you
since you describe an allocation scheme that has been out of fashion for
quite awhile in FreeBSD, nor do I think you truly understand enough of
both systems to make an informed comparison.  Don't assume that Linux
knowledge and a working familiarity with the 4.4Lite tape translates to
knowing what's really up with FreeBSD.

>Linux, no such pre-reservation occurs, malloc's() cannot fail.  The

By george, that's rather a neat trick! A malloc() that *cannot* fail!
Those clever Linux chappies, they're working wonders over there I tell
you! :-)

> Indeed I do.  If have ever got past writing hello world in C++ you
> would understand that polymorphic templates and exception support was

2.7.2 is truly an improvement for C++, that's no argument.  I just
wish it could compile a kernel and system (including XFree86, which
currently gets munched a bit) with the same accuracy as 2.6.3 - we'd
switch over in a moment.

> Ah, so this is the kind of in-depth analysis and discussion I can
> expect from FreeBSD developers is it.

He's not a FreeBSD developer.

> Do you understand that when a user-level process malloc()s memory from
> the kernel, a subsequent free() does not return the VM back for use by
> other processes?  Do you know if the mount_mfs() process invokes the

Bzzzzt.  Sorry, but you're wrong.  "negative sbrk()ing" has been a
feature of FreeBSD's system malloc for some time now.  It was a feature
of GNU malloc for even longer before that, and those folks who wanted it
(like emacs) always linked with -lgnumalloc under FreeBSD.

> No, let me see who is a fool.  I suggest you go out and read the
> excellent "The Design and Implementation of the 4.3BSD UNIX Operating
> System", then go and read some kernel source, then read libc, then

You're out of date.  Go get the 4.4BSD Operating System book, since it's
4.4 on which FreeBSD is now based (for a substantial set of changes),
and then study FreeBSD-current for awhile to see how the VM system has
been rather radically altered from what you'll see in the book.  At that
point, you'll be more than ready to compare FreeBSD against other
operating systems with authority.
-- 
- Jordan Hubbard
  President, FreeBSD Project