0 like 0 dislike
125 views
in Computer Science by (1.0m points)
Define the memory management function of operating system?

1 Answer

0 like 0 dislike
by (1.0m points)

Memory management is the functionality of an operating system which handles or manages primary memory and moves processes back and forth between main memory and disk during execution. Memory management keeps track of each and every memory location, regardless of either it is allocated to some process or it is free. It checks how much memory is to be allocated to processes. It decides which process will get memory at what time. It tracks whenever some memory gets freed or unallocated and correspondingly it updates the status.

This tutorial will teach you basic concepts related to Memory Management.

Process Address Space

The process address space is the set of logical addresses that a process references in its code. For example, when 32-bit addressing is in use, addresses can range from 0 to 0x7fffffff; that is, 2^31 possible numbers, for a total theoretical size of 2 gigabytes.

The operating system takes care of mapping the logical addresses to physical addresses at the time of memory allocation to the program. There are three types of addresses used in a program before and after memory is allocated 

Virtual and physical addresses are the same in compile-time and load-time address-binding schemes. Virtual and physical addresses differ in execution-time address-binding scheme.

The set of all logical addresses generated by a program is referred to as a logical address space. The set of all physical addresses corresponding to these logical addresses is referred to as a physical address space.

The runtime mapping from virtual to physical address is done by the memory management unit (MMU) which is a hardware device. MMU uses following mechanism to convert virtual address to physical address.

The value in the base register is added to every address generated by a user process, which is treated as offset at the time it is sent to memory. For example, if the base register value is 10000, then an attempt by the user to use address location 100 will be dynamically reallocated to location 10100.

The user program deals with virtual addresses; it never sees the real physical addresses.

Related questions

0 like 0 dislike
1 answer 501 views
0 like 0 dislike
1 answer 47 views
0 like 0 dislike
1 answer 81 views
asked Apr 1, 2019 in Computer Science by danish (1.0m points)
0 like 0 dislike
1 answer 148 views
asked Dec 22, 2018 in Computer Science by danish (1.0m points)
0 like 0 dislike
1 answer 64 views
0 like 0 dislike
1 answer 78 views
asked Apr 3, 2019 in Computer Science by danish (1.0m points)
0 like 0 dislike
1 answer 156 views
asked Dec 21, 2018 in Computer Science by danish (1.0m points)
0 like 0 dislike
1 answer 71 views
0 like 0 dislike
1 answer 78 views
0 like 0 dislike
1 answer 47 views
Welcome to Free Homework Help, where you can ask questions and receive answers from other members of the community. Anybody can ask a question. Anybody can answer. The best answers are voted up and rise to the top. Join them; it only takes a minute: School, College, University, Academy Free Homework Help

19.4k questions

18.3k answers

8.7k comments

6.2k users

Free Hit Counters
...