Virtual memory defines a type of hardware that allows system user to run many applications irrespective of the physical memory available to support required operations. On the same note, it has been described as simulated memory written into some files found on the hard drive (Singh, Goyal & Kaur, 2014). In order for facilitate efficient working of the system, it does simulation of the physical Read Access Memory (RAM) through implementation of available hard disk space. In order to free up memory space that can be used by RAM to load some other new applications, computers checks for unused RAM areas to copy them to hard disk. With virtual memory, computer create another non-existed space to load applications by making it work as if it has enough memory to load as many applications as possible. The main idea behind virtual memory is to deduce more space from hard disk and use it as if it was running on RAM. It is through virtual memory that computer application programming has been made easier by eliminating all physical memory fragmentations (Yang, Berger, Kaplan & Moss, 2006). It is only through virtual memory that other applications are excluded from managing any shared memory spaces in order to increase operational security through memory isolation.
Virtual memory concepts
It is through virtual memory in computer architecture that allows computer users run many sophisticated programs irrespective of the amount of RAM installed in a specific computer. Using virtual memory, computer jungles all demands of conflicting programs within a fixed physical memory at any given time. For a computer to address all content in the RAM, it must do so through use of system addresses (Sumant & Chawan, 2010). Important to note is that, it is only through virtual memory that compatibility issue of software are eliminated. This is eliminated by treating each software as if it was running on a different computer. It is the duty of the operating system to make sure there are enough set of virtual addresses to support each required application. In order to support these processes, Operating system translates all available virtual addresses to physical ones dynamically. Similarly, the concept of file paging supports virtual memory by writing program pages that have not been used in a hard disk. All data is saved by the files and if an application program needs to use it again, the OS reloads it again when RAM is available. At some instances, many programs might need to use RAM at the same time. To manage this, page swapping is called to facilitate memory management (Tripathy & Tripathy, 2014).
Additionally, virtual memory facilitates memory protection by preventing data from being changed by another program running concurrently (Sumant & Chawan, 2010).It is obvious that most of computer processes does not require all its running pages at once. The following are some of the reasons that makes computer processes request different pages at different times. First, some of the process pages such as error handling might not be required for the entire period of running a process. Error handling are only called by processes once an error has been encountered and if it does not occur, that specific space remains unused (Puaut & Hardy, 2007). Secondly, some of program features are rarely used and holding memory awaiting its use results to waste of resources and computing power. Instead of holding memory while awaiting its use by a sub-process that might not run for the entire life of the process, such memory can be allocated to another demanding process.
Application of virtual memory
The use and importance of virtual memory cannot be underrated as it provides an opportunity to all application programs to run concurrently on demand. It is quite impossible to assume computers have enough memory to satisfy all running applications (Bairavasundaram, Arpaci-Dusseau & Arpaci-Dusseau, 2006). At an instance, a computer runs many programs which require each other or are in use by system user at the same time. Without virtual memory, it would not be possible to have computers run faster as well as execute activities concurrently. Through use of virtual memory, computers are able to share available memory to several applications running at the same time. Sharing of available memory is usually done through a process known as paging. Memory paging involves distributing a piece of memory to many applications as possible. Operating system manages memory swapping in such a way that all applications are running in a use and release concept.
Any running process may request to use a resource held by another process. A good example can be deduced by having two processes, P1 and P2 sharing a common memory (Lee, Bahn & Shin, 2014). If process P1 has been initiated by either user or a system, it may request a resource in use by P2 or any other process. Depending on the nature of either processes, P1 can wait or preempt resource from P2 only if P2 is able to release required resource. If process P2 is non-preemptive, P1 might be forced to wait or get similar resource from another process. The exchange of a piece of memory from one process to the other is what facilitates running of many programs at the same time. According to Vaynberg & Shao (2012), paging process happens within a very short period of time in such a way that system user cannot realize if there is memory swapping. With memory swapping, computer is able to sustain user’s need by running as many applications as possible. Lastly, by creating a buffer, computer is able to execute process faster than if it was to fetch and move processes from RAM and hard disk. Therefore, it would be worthy to conclude that, virtual memory concept has been used to design almost all processes related to system resource maintenance.
Virtual memory trends
Virtual memory has resulted to development of new storage technologies which allows system users interact easily with other devices. Development and use of flash disks has been built entirely on virtual memory. The flash-tier works on basis of solid-state caching which is a flash device with ability to interface with other systems through caching. The other observable trend is on Flash meets virtual memory (FlashVM) which offers capability of developing flash which uses virtual memory paging instead of using actual disks (Ji & Zeng, 2015). Through use of virtual memory, it has been possible to increase flash performance, reduce the size of hardware as well as make it possible to have efficient garbage collection. FlashVM offers more than 94% of reduced execution time on application which is four times faster than disk swapping.
Implementation of virtual memory provides an opportunity to computers to have faster computers operations than before. Since it is impossible to have enough memory on computers, the best aspect would be to focus on how to actualize on virtual memory usage. Leveraging on virtual memory development would greatly help in coming up with small storage devices which have high performance capability. Through use of virtual memory, it has been possible to develop light weight and persistent memories such as SSD’s. Similarly, virtual memories helps come up with small but scalable devices.
Bairavasundaram, L. N., Arpaci-Dusseau, A. C., & Arpaci-Dusseau, R. H. (2006). Dependability analysis of virtual memory systems. In Dependable Systems and Networks, 2006. DSN 2006. International Conference on (pp. 355-364). IEEE.
Ji, X., & Zeng, F. (2015). Flash-aware Virtual Memory System for Consumer Electronics. International Journal of Multimedia and Ubiquitous Engineering, 10(8), 329-338.
Lee, H., Bahn, H., & Shin, K. G. (2014). Page replacement for write references in NAND flash based virtual memory systems. Journal of Computing Science and Engineering, 8(3), 157-172.
Puaut, I., & Hardy, D. (2007). Predictable paging in real-time systems: A compiler approach. In Real-Time Systems, 2007. ECRTS'07. 19th Euromicro Conference on (pp. 169-178). IEEE.
Singh, A., Goyal, G., & Kaur, J. (2014). Design of Swap Space in Virtual Memory management System. International journal of Current Engineering and technology, 4(3), 1982-1985.
Sumant, A. S., & Chawan, P. M. (2010). Virtual Memory Management Techniques in 2.6 Kernel and Challenges. International Journal of Engineering and Technology, 2(2), 157.
Tripathy, M., & Tripathy, C. R. (2014). A Comparative Analysis of Performance of Shared Memory Cluster Computing Interconnection Systems. Journal of Computer Networks and Communications, 2014.
Vaynberg, A., & Shao, Z. (2012). Compositional verification of a baby virtual memory manager. In International Conference on Certified Programs and Proofs (pp. 143-159). Springer, Berlin, Heidelberg.
Yang, T., Berger, E. D., Kaplan, S. F., & Moss, J. E. B. (2006). CRAMM: Virtual memory support for garbage-collected applications. In Proceedings of the 7th symposium on Operating systems design and implementation (pp. 103-116). USENIX Association.