Definition: Virtual memory is the feature of an operating system (OS). It is responsible for memory management.In the Virtual Memory the Physical Memory (Hard Disk) will be treated as the Logical Memory (random access memory (RAM)). Means with the help of virtual Memory we can also temporarily increase the size of Logical Memory as from the Physical Memory. A user will see or feels that all the Programs are running into the Logical Memory of the Computer. With the help of virtual Memory all the Space of Hard Disk can be used as the Logical Memory So that a user can execute any Number of programs.
Benefits of Virtual Memory
1) Unused Address space: With the help of Unused Address Space a user can execute any number of programs because all the actual Addresses will be treated as the logical Addresses. All the Programs those are given by the user will be Stored into the Disk Space and all the Programs will be Stored into the Physical Address Space but they will treat as they are Stored into the Logical Address Space.
2) Increased degree of Multi-programming: With the help of Virtual Memory we can Execute Many Programs at a Time because Many Programs can be fit in the Physical Memory So that More Programs can be Stored into the Memory but this will not increase the Response Time of the CPU Means this will not affect on the Execution of the Programs.
3) Decrease Number of I/O Operations: There will be less Operations those are to be used for performing the Swapping of the Processes. All the Programs will be automatically will be loaded into the Memory when they are needed.
But always remember that the Whole Programs are never to be copied into the Memory Means all the Programs will be Copied into the Form of Pages Means the Parts of the Programs.