lkml.org 
[lkml]   [1997]   [Aug]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectMemory Management - BSD vs Linux
Date
Hi,

I am looking to compare the Memory management in BSD systems against
linux. I have been muddling thru the linux and freebsd/netbsd code
and have some notes and questions. I was wondering if some of you,
who have been staring at the code longer than I have would share your
knowledge with me.

I'll jot down some of notes below. Please feel free to comment on
them (please CC me on your replies but keep the discussion on the
mailing list so that everybody can see the replies). Some of my
notes may indeed be wrong or outdated. Please don't flame me on
these. Just correct me instead!

[1] FreeBSD uses a "Zone allocator" for kernel memory allocation.
NetBSD - I am not so sure.
Linux - Buddy system.

[2] All of FreeBSD/NetBSD/Linux are demand paged. They all have a
memory overcommit architectures and swap if required. All can
have multiple swap partions.

[3] Can any of these systems have
a) swap files rather than partitions
b) dynamically growing swap space?
As far as I can make out, the answeris no!

[4] FreeBSD/NetBSD swap out complete processes when required.
Linux swaps out only some pages per process, upto the complete
process if required.

[5] All of FreeBSD/NetBSD/Linux write out only the dirty pages to
swap space, choosing to read in the read-only (code) pages from
the file system.

[6] In FreeBSD, the file system buffer cache is implemented on top of
the the memory management system using objects from the VM system
to compose the buffer cache.
NetBSD has separate fixed allocation of physical memory for the
buffer cache which is not available to the VM system.
Linux has a separate buffer cache like NetBSD, but the
buffer cache size is not fixed and can vary dynamically depending
on load (? not sure about this)

-dj

______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com

\
 
 \ /
  Last update: 2005-03-22 13:40    [W:3.569 / U:0.032 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site