Do we need 2 Memory managers?
Posted: Fri Mar 27, 2009 1:55 pm
Hello Geeks
Well after i learnt from James how to solve chicken and egg problem, by using placement address for allocating new available address until.....
UNTIL i have set bitmap ,Kernel directory and frame allocation and free properly, i am confused about this thing:
If i have already a mechanism to allocate frames and will develop a routine to map actual frames to pages for user processes (on the fly depending upon size of programs compiled to some virtual address say 0x100000) then my virtual memory manager is done
I think i am correct?
Secondly for example neither my kernel nor my user programs need dynamic allocation i mean all using static way like
char x[256];
int y[512];
then there is not need of heap, please correct me.
If above mentioned are correct then certainly no need of malloc() in user processes or malloc() will return address of newly allocated page.....
yeah wastage of memory i mean for allocation of a byte i will allocate 4kb....now i am trying to find a way to reuse that free space within allocated page, that is, each process will have its own mechanism to keep track of what part of last page allocated is free .... can be done using placement address mechanism.
Too long, i think i am not able to put it correctly.
Well after i learnt from James how to solve chicken and egg problem, by using placement address for allocating new available address until.....
UNTIL i have set bitmap ,Kernel directory and frame allocation and free properly, i am confused about this thing:
If i have already a mechanism to allocate frames and will develop a routine to map actual frames to pages for user processes (on the fly depending upon size of programs compiled to some virtual address say 0x100000) then my virtual memory manager is done
I think i am correct?
Secondly for example neither my kernel nor my user programs need dynamic allocation i mean all using static way like
char x[256];
int y[512];
then there is not need of heap, please correct me.
If above mentioned are correct then certainly no need of malloc() in user processes or malloc() will return address of newly allocated page.....
yeah wastage of memory i mean for allocation of a byte i will allocate 4kb....now i am trying to find a way to reuse that free space within allocated page, that is, each process will have its own mechanism to keep track of what part of last page allocated is free .... can be done using placement address mechanism.
Too long, i think i am not able to put it correctly.