Memory allocation algorithms

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
Senaus

Memory allocation algorithms

Post by Senaus »

Hi, I've just finished writing a new memory allocation system for my kernel, and I am about to begin testing. Basically it consists of two bitmap allocators (one for DMA and another for the buddy allocators to use), two buddy allocators (for physical pages and virtual pages), and a cache allocator (for splitting up virtual pages).

I'd just like to know the amount of CPU clocks per allocation your memory allocators use (if you have recorded it), that way I have a target to work towards ;)

Thanks,
The Senaus
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:Memory allocation algorithms

Post by Pype.Clicker »

i shall admit that i haven't the slightest idea. i certainly stressed my implementation when i wrote it, but since then ...

btw, if i were you i would be running tests to ensure that it works properly (e.g. only cleaning bits its supposed to clean, keeping lists flats, etc.) first. Hopefully enough, that's a thing you can (quite) easily do in user-mode of another OS, so take advantage of it so that you got a full-proof implementation when you'll be integrating the whole stuff into your OS.
Senaus

Re:Memory allocation algorithms

Post by Senaus »

Pype.Clicker wrote: btw, if i were you i would be running tests to ensure that it works properly
Yeah, thats what I'm doing now. I hate debugging >:(
Pype.Clicker wrote: Hopefully enough, that's a thing you can (quite) easily do in user-mode of another OS
I never thought of that, that is an excellent idea. That way I can use VC++'s debugger (the only thing it is good for) :D

Thanks,
The Senaus
Post Reply