What is paging and explain also the conversion of virtual address to physical address in paging with example ?
What is paging and explain also the conversion of virtual address to physical address in paging with example ?
In Operating Systems, Paging is a storage mechanism used to retrieve processes from the secondary storage into the main memory in the form of pages.
The main idea behind the paging is to divide each process in the form of pages. The main memory will also be divided in the form of frames.
One page of the process is to be stored in one of the frames of the memory. The pages can be stored at the different locations of the memory but the priority is always to find the contiguous frames or holes.
Pages of the process are brought into the main memory only when they are required, otherwise they reside in the secondary storage.
Different operating system defines different frame sizes. The sizes of each frame must be equal. Considering the fact that the pages are mapped to the frames in Paging, page size needs to be as same as frame size.
Example :
Let us consider the main memory size 16 Kb and Frame size is 1 KB therefore the main memory divided collection frames of 1 KB each. There are 4 processes in the system that is P1, P2, P3 and P4 of 4 KB each. Each process is divided into pages of 1 KB each so that one page can be stored in one frame.
Initially, all the frames are empty therefore pages of the processes will get stored in the contiguous way.
Frames, pages and the mapping between the two is shown in the image below.
Let us consider that, P2 and P4 are moved to a waiting state after some time. Now, 8 frames become empty and therefore other pages can be loaded in that empty place. The process P5 of size 8 KB (8 pages) is waiting inside the ready queue.
Given the fact that, we have 8 non-contiguous frames available in the memory and paging provides the flexibility of storing the process at the different places. Therefore, we can load the pages of process P5 in the place of P2 and P4.
Topics Covered :
- what is operating system and its types
- operating system in computer
- operating system responsibilities
- operating system definition
- operating system kya hai
- operating system in hindi
- operating system pdf
- operating system ppt
- operating system full course
- types of operating system
- functions of operating system
- operating system in detail
- what is operating system full information
- use of operating system
- operating system
- why operating system
- what is operating system
- high performance computer architecture
- physical address
- logical address
- operting system
- computer science
- multi-cores
- andrew tanenbaum
- paging,page table
- georgia tech
- udacity
- page
Thanks for reading this blog. Hope you get satisfied with the blog and definitely this blog must have valued your time and effort of reading.
Take a time to connect our other digital creations such as Instagram , Facebook and Youtube.
Β Social MediaΒ LinksΒ ofΒ Tech DCodeΒ :
Β YouTube :Β https://www.youtube.com/channel/UCjJnEdeugftBwQ3yMuD4B_A
Β Instagram :Β https://www.instagram.com/thetechdcode/
Β Facebook Page :Β https://www.facebook.com/thetechdcode
Β Twitter :Β https://twitter.com/thetechdcode
Β Telegram Channel :Β https://t.me/thetechdcode
Β Tech DCode Linktree :Β https://linktr.ee/thetechdcode
Β My Personal Handles :Β https://linktr.ee/virtualshivamin
Β Social Media LinksΒ ofΒ SHIVAM SINGHΒ (OWNER) :
Β Instagram :Β https://www.instagram.com/virtualshivamin/
Β Facebook Page :Β https://www.facebook.com/virtualshivamin/
Β Twitter :Β https://twitter.com/virtualshivamin/
Β Personal Linktree :Β https://linktr.ee/virtualshivaminΒ