Swapping is a process of swapping a process temporarily to a secondary memory from main memory which is fast as compared to secondary memory. But as RAM is of less size so the process that is inactive is transferred to secondary memory. The main part of swapping is transferred time and the total time directly proportional to the amount of memory swapped.
Paging is the procedure of memory allocation where different non-contiguous blocks of memory are assigned a fixed size. The size is generally of 4KB. The paging is always performed between active pages.
Difference between Paging and Swapping :
|It is procedure of copying out the entire process.||It is a technique of memory allocation.|
|Swapping occurs when whole process is transferred to disk.||Paging occurs when some part of process is transferres to disk.|
|In this process is swapped temporarily from main memory to secondary memory.||In this the contiguous block of memory is made non-contiguous but of fixed size called frame or pages.|
|Swapping can be performed without any memory management.||Non-contiguous Memory Management.|
|Swapping is done by inactive processes.||Only active process can perform paging.|
|It provides the direction regarding the solution.||No suggestion is given regarding the solution in it.|
GeeksforGeeks has prepared a complete interview preparation course with premium videos, theory, practice problems, TA support and many more features. Please refer Placement 100 for details
- Difference Between Paging and Segmentation
- Difference between Demand Paging and Segmentation
- Two Level Paging and Multi Level Paging in OS
- Paging in Operating System
- Translation Lookaside Buffer (TLB) in Paging
- Multilevel Paging in Operating System
- Difference between 4G and 5G
- Difference between H.323 and SIP
- Difference between TCP and RTP
- Difference between T-SQL and PL-SQL
- Difference Between Blu-Ray and DVD
- Difference between CPU and GPU
- Difference between CRT and LCD
- Difference between 1G and 2G
- Difference between TDM and FDM
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.