Dynamic memory management, Operating System

Usually memory is allocated from a large pool of unused memory area called the heap. In C++, dynamic allocation/deallocation must be manually performed using commands like malloc, free, new and delete. Malloc allocates space of a given size and gives a pointer back to the programmer. The programmer then can do whatever he or she wants with it. The new command, on the other hand, allocates a speci?c object of a given size. The general way in which dynamic allocation is done is that the program asks the memory manager to allocate or free objects (or multiple pages); then, the memory manager asks the OS to allocate/free pages (or multiple pages). Notice, how- ever, that the allocator does not give the whole allocated page back to the program; it just gives what it asked for. The rest of the page (i.e. the parts not given to the program) is saved for future memory requests.

Posted Date: 3/12/2013 6:03:44 AM | Location : United States







Related Discussions:- Dynamic memory management, Assignment Help, Ask Question on Dynamic memory management, Get Answer, Expert's Help, Dynamic memory management Discussions

Write discussion on Dynamic memory management
Your posts are moderated
Related Questions
What are the drawbacks of spiral model? I. It is based on customer communication. If the communication is not proper then the software product that gets developed will not be t

What are the characteristics of SRS? i. Correct - The SRS should be made up to date when appropriate requirements are identified. ii. Unambiguous - When the requirements are

List five services provided by an operating system. Explain how each provides convenience to the users. Explain also in which cases it would be impossible for user-level programs t

Processes have valid and invalid entries on their page tables. The valid entries all point to some where "real" (e.g. a physical page, or some portion of disk in case of non-reside

What is graceful degradation? In multiprocessor systems, failure of single processor will not halt the system, but only slow it down by sharing the work of failure system by ot

with the aid of diagrams describe the following os structures monolithic , layered, client server

socket based fortune teller sever.your program should create a server that listens to a specific port when a client receives a connection the server should respond with a random fo

What is Multitasking? Multitasking provides power to users by offering them to run multiple applications at once. The applications are loaded into memory and appear to the user

Now let us present an implementation of a producer-consumer system using condition variables. This implementation works. dequeue() lock(A) while (queue empty) { wait(A, C)

Write a short note on file organization and access. There are three methods to access files 1Record Access 2Sequential Access 3Random Access The record access