Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Memory managment of kernel [solved]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Keruskerfuerst
Advocate
Advocate


Joined: 01 Feb 2006
Posts: 2289
Location: near Augsburg, Germany

PostPosted: Sat Apr 19, 2008 6:19 pm    Post subject: Memory managment of kernel [solved] Reply with quote

Does the kernel a preallocation of memory, when data is transfered into RAM?

Last edited by Keruskerfuerst on Tue Apr 22, 2008 3:23 am; edited 1 time in total
Back to top
View user's profile Send private message
jcat
Veteran
Veteran


Joined: 26 May 2006
Posts: 1337

PostPosted: Sat Apr 19, 2008 6:32 pm    Post subject: Reply with quote

Anything that is required to run the system! :wink:

Here's some reading for you :)

http://gentoo-wiki.com/FAQ_Linux_Memory_Management
https://forums.gentoo.org/viewtopic.php?t=175419



Cheers,
jcat
Back to top
View user's profile Send private message
Keruskerfuerst
Advocate
Advocate


Joined: 01 Feb 2006
Posts: 2289
Location: near Augsburg, Germany

PostPosted: Sat Apr 19, 2008 7:15 pm    Post subject: Reply with quote

The FAQ and the thread does not answer my question at all.
Back to top
View user's profile Send private message
kernelOfTruth
Watchman
Watchman


Joined: 20 Dec 2005
Posts: 6111
Location: Vienna, Austria; Germany; hello world :)

PostPosted: Sat Apr 19, 2008 7:30 pm    Post subject: Reply with quote

Keruskerfuerst wrote:
The FAQ and the thread does not answer my question at all.


it's a little old but it should answer your question at least partly (me thinks)

http://www.linuxsymposium.org/proceedings/reprints/Reprint-Hansen-OLS2004.pdf
_________________
https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa

Hardcore Gentoo Linux user since 2004 :D
Back to top
View user's profile Send private message
jcat
Veteran
Veteran


Joined: 26 May 2006
Posts: 1337

PostPosted: Sat Apr 19, 2008 7:58 pm    Post subject: Reply with quote

Keruskerfuerst wrote:
The FAQ and the thread does not answer my question at all.


Ok, I obviously misunderstood, from you first post I assumed you were after something more general. Apologies..



Cheers,
jcat
Back to top
View user's profile Send private message
DarKRaveR
Guru
Guru


Joined: 11 Oct 2003
Posts: 500
Location: Old Europe/G-Many

PostPosted: Sat Apr 19, 2008 10:09 pm    Post subject: Reply with quote

AFAIK Linux uses copy on write in many places.

Could you be a bit more specific as to what exatly you mean by transferring data and in what way the transfer is issued?
Back to top
View user's profile Send private message
Keruskerfuerst
Advocate
Advocate


Joined: 01 Feb 2006
Posts: 2289
Location: near Augsburg, Germany

PostPosted: Sun Apr 20, 2008 11:12 am    Post subject: Reply with quote

Memory pre allocation:

e.g.: data transfer from HDD to RAM.
pre allocation of RAM (size= size of file) to transfer data into RAM.
Back to top
View user's profile Send private message
DarKRaveR
Guru
Guru


Joined: 11 Oct 2003
Posts: 500
Location: Old Europe/G-Many

PostPosted: Sun Apr 20, 2008 9:13 pm    Post subject: Reply with quote

Keruskerfuerst wrote:
Memory pre allocation:

e.g.: data transfer from HDD to RAM.
pre allocation of RAM (size= size of file) to transfer data into RAM.


And how is this case (filedata to ram) related to the mem management itself? This strongly depends on what the application programmer does.
But let's see, assuming DMA is used, the DMA Buffer is obviously preallocated.
Now, the question is: Do we just mmap() the file? then the single pages are paged in as needed ...
Many of these things strongly depend on what the programm does, doesn't it? If I process a stream just using a ringbuffer, then most certainly the memory won't be 'preallocated' exept for the buffer size.

If a programmer allocates memory, it will depend on the way he does it.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum