Page 1 of 1

Memory allocation algorithms

Posted: Mon Jan 30, 2006 12:49 pm
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

Re:Memory allocation algorithms

Posted: Tue Jan 31, 2006 2:11 am
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.

Re:Memory allocation algorithms

Posted: Tue Jan 31, 2006 9:05 am
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