Memory mannagment

Garrett Cooper youshi10 at u.washington.edu
Thu Jun 14 07:55:15 UTC 2007


cadastrosonline cadastrosonline wrote:
> First of all,
>
>
>
> "Each process has its own private address space. The address space is initially divided
> into three logical segments: text,
> data, and stack. "
>
>
>
> But if the address is just something like 343556 then how does it
> really work? The memory is divided into segments is that what it means?
>
>
>
> "The data segment contains the initialized and uninitialized data portions of a program"
>
>
>
> Is it talking about multithreading? I COULDNT FIND anything talking
> about how freebsd deals with multithreading, just found out it does it
> by man pthread.
>
>
>
> Tell me anything else interesting to know about memory mannagment, does
> it use any algorithm to substitute a page when out of pages in memory?
> such as "second chance" "fifo" "lru" (last recently used) "nfu" (not
> frequently used) and so on? I am studying freebsd but sometimes I am
> out of ways to find out, yes I am reading the handbook about memory
> mannagment as you can see my quotes but sometimes I don't understand.
>
>
>
> Thanks in advance.
>   
    This question is better suited for the hackers@ list, and before 
doing that I suggest buying/checking out a copy of the book The Design 
and Implementation of the FreeBSD Operating System.

    Many of your questions can be possibly answered better by taking a 
computer architecture and/or operating systems course, as many of the 
questions and ideas you have most likely apply to real-time operating 
systems, including Linux, OSX, Solaris and even (gasp) Windows, not just 
FreeBSD.

    Some of my 2 cents:

Threading is known as LWP (Light-weight processes). Some differences are 
present, but the basic semantics of what one deems as non-threaded 
programs (processes), also applies to threads. Sharing, scheduling, and 
overall applied load are the overall big differences present in a 
threaded system, when compared to a procedural only system.

Cheers and happy learning,
-Garrett


More information about the freebsd-questions mailing list