Memory Management Report
Memory Management Report
On
BACHELOR OF TECHNOLOGY
in
Content
Abstract
List of Tables
1.1 Introduction
1.2 Objective
2 Literature Survey
Project Detail
Chapter 4
References
Abstract
Advantages:
o Simple to implement.
o Low overhead.
Disadvantages:
o External fragmentation (unused space between allocated
blocks).
o Fixed size for each process, which can lead to inefficient use of
memory.
Paged memory allocation divides the physical memory into small fixed-size
blocks called pages. The logical memory (processes) is divided into blocks of
the same size, called pages. This allows non-contiguous memory allocation,
which helps reduce fragmentation.
Advantages:
o Eliminates external fragmentation.
o Efficient use of memory.
Disadvantages:
o Overhead of managing page tables.
o Potential internal fragmentation (unused space in pages).
Advantages:
o Allows dynamic size allocation.
o More logical than paging for complex data structures.
Disadvantages:
o External fragmentation can occur.
o Complex to manage and requires maintaining multiple segment
tables.
Virtual memory allows the system to use secondary storage (such as a hard
drive or SSD) as an extension of RAM. This creates the illusion that the
system has more memory than it physically does. Virtual memory is
managed through paging and segmentation.
Advantages:
o Allows larger applications to run than the physical memory would
permit.
o Isolates process memory spaces.
Disadvantages:
o Slower than physical memory, as accessing secondary storage is
much slower than RAM.
The first-fit allocation policy allocates the first available block of memory that
is large enough to accommodate the process. This approach is efficient in
terms of speed but can lead to fragmentation over time.
Best-fit allocates the smallest available block that fits the process,
minimizing wasted space. However, this can lead to many small leftover
holes, increasing fragmentation in the long term.
The buddy system divides memory into blocks that are powers of two. When
a process requests memory, the system finds the smallest available block
that fits, and if necessary, splits a larger block into smaller "buddies" of equal
size.
Demand Paging: Pages are only loaded into memory when required,
reducing memory usage.
Memory Overcommitment: Systems like Linux use overcommit
policies, allowing more memory to be allocated than physically
available, relying on swapping or killing processes when memory runs
low.
NUMA (Non-Uniform Memory Access): A memory design where
processors have local memory but can also access memory from other
processors. Modern operating systems optimize memory allocation in
NUMA systems to reduce access time.
Chapter 4 – Results and Future Work
8. Conclusion
9. References