field of computer science, the fragmentation is an important factor concerning
the performance of the system. It has a great role to play in bringing the
performance of the computers.
What is Fragmentation?
- It can be defined as a
phenomenon involving the inefficient use of the storage space that in turn
reduces the capacity of the system and also brings down its performance.
- This phenomenon leads to the wastage of the
memory and the term itself means the ‘wasted space’.
is of three different forms as mentioned below:
The external fragmentation
Internal fragmentation and
- All these
forms of fragmentation might be present in conjunction with each other or in
- In some cases, the fragmentation might be accepted in exchange of
simplicity and speed of the system.
Basic principle behind
the fragmentation concept.
- The CPU allocates the memory in form of blocks or
chunks whenever requested by some computer program.
- When this program has
finished executing, the allocated chunk can be returned back to the system
- The size of memory chunk required by every program varies.
- In its
lifetime, a program may request any number of memory chunks and free them after
- When a program begins with its execution, the memory areas that are free
to allocated, are contiguous and long.
- After prolonged usage, these contiguous
memory locations get fragmented in to smaller parts.
- Later, a stage comes when
it becomes almost impossible to serve the large memory demands of the program.
Types of Fragmentation
- This type
of fragmentation occurs when the available memory is divided in to smaller
blocks and then interspersed.
- Certain memory allocation algorithms have a minus
point that they are at times unable to order the memory used by the programs in
such a way that its wastage is minimized.
- This leads to an undesired situation
where even though we have free memory, it cannot be used effectively since
being divided in to very small parts that alone cannot satisfy the memory
demands of the programs.
- Since here, the
unusable storage lies outside the allocated memory regions, this type of
fragmentation is called external fragmentation.
- This type of fragmentation is
also very common in file systems since here many files with different sizes are
created as well as deleted.
- This has a worse effect if the file deleted was in
many small pieces.
- This is so because this leaves similar small free memory
chunks which might be of no use.
- There are
certain rules that govern the process of memory allocation.
- This leads to the
allocation of more computer memory what is required.
- For example, as the
rule memory that is allocated to programs should be divisible by 4, 8 or 16. So
if some program actually requires 19 bytes, it gets 20 bytes.
- This leads to the
wastage of extra 1 byte of memory.
- In this case, this memory becomes unusable
and is contained in the allocated region itself and therefore this type of
fragmentation is called as the internal fragmentation.
- In computer forensic
investigation, the slack space is the most useful source for evidence.
- However, it is often difficult to reclaim the internal fragmentation.
- Making a change in
the design is the most effective way for preventing it.
- Memory pools in dynamic
memory allocation are the most effective methods for cutting down the internal
- In this the space overhead is spread by a large number of
because of breaking up of the data in many pieces that lie far enough from each