Realtime memory managment algoritms

Programming, for all ages and all languages.
Post Reply
psnix
Member
Member
Posts: 50
Joined: Fri Oct 24, 2008 12:34 pm

Realtime memory managment algoritms

Post by psnix »

are there any realtime memory managment algoritm (hard real time)?

and how can i test performance of memory algoritms againest each other? (any tool or ...)
gerryg400
Member
Member
Posts: 1801
Joined: Thu Mar 25, 2010 11:26 pm
Location: Melbourne, Australia

Re: Realtime memory managment algoritms

Post by gerryg400 »

What time of memory management do you mean ? kernel, os, userspace ?
If a trainstation is where trains stop, what is a workstation ?
psnix
Member
Member
Posts: 50
Joined: Fri Oct 24, 2008 12:34 pm

Re: Realtime memory managment algoritms

Post by psnix »

kernel
User avatar
Combuster
Member
Member
Posts: 9301
Joined: Wed Oct 18, 2006 3:45 am
Libera.chat IRC: [com]buster
Location: On the balcony, where I can actually keep 1½m distance
Contact:

Re: Realtime memory managment algoritms

Post by Combuster »

Did you realize that most simple allocators can be used as realtime ones - Things will only cause problems when you are dealing with concurrent accesses. But since you are making the kernel you can make sure there's no other access attempt at the same time. The IF flag and a lack of multiple cores can help you a lot with that.

I hope you can do algorithmic complexity analysis. Being real-time is by definition independent of being fast, and you'll need to know how much time can be spent to be able to establish performance guarantees.
Homework: how much work (count the number of statements executed) can be spent in a single iteration of a bitmap-based allocator; how much can be spent in a single iteration of a stack-based allocator?
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]
gerryg400
Member
Member
Posts: 1801
Joined: Thu Mar 25, 2010 11:26 pm
Location: Melbourne, Australia

Re: Realtime memory managment algoritms

Post by gerryg400 »

Slab allocators are very popular in kernels. They are easy to write and debug.
If a trainstation is where trains stop, what is a workstation ?
Post Reply