17 January 2006

Virtual Memory

In the early years of mainframe computing, as computers evolved standardized architecture, demand arose for programs that took care of most of the routine system functionality, such as assigning storage capacity to a particular task. At the same time, data storage was a far greater concern; it was no longer acceptable to expect users to walk away with a bunch of freshly-punched cards. If the computer was going to be able to address a task routinely, then it was necessary for that computer to be able to store very large amounts of data in a stable manner.

But the most important concern of all was for the computer to be able to cope with multitasking. Multitasking meant multiple users running the same immense processor at the same time; or it meant one user running multiple programs concurrently—possibly in order to transfer data between the two. A strong incentive for developing multitasking computer software was the need to permit debugging of software. An early form of this was the time-share, in which computers would allocate time to specific tasks much the way they allocate disk space to the storage of specific blocks of data. An alternative form is "pipelining," in which the processor is simply running different steps to different instructions at the same time, much like an assembly line.

While the term "virtual memory" might sound esoteric, it was an immensely important innovation in the early years of computer science. Basically, early applications of virtual memory included the "virtual machine," an imaginary computer simulated by the operating system for allowing many virtual machines on a single tangible machine. For this reason, virtual memory was crucial to allowing engineers to realize the full potential of their hardware. In 1967, IBM developed a system software known as VM, for virtual machine, which was designed to allow multitasking in precisely this way. VM was a fairly rudimentary operating system—it was a software emulator of the hardware it ran on—but it excelled at what it did, so that an IBM 360/67 could run several instances of VM in a VM instance running in another VM instance, in yet another VM instance... with little hit on actual performance.*

VM essentially the task of addressing secondary memory, such as a tape drive, to host some of the data that is theoretically stored in RAM. The job of creating VM to enhance processor functionality is that of the operating system, which designates sectors of a computer storage unit (known as "pages"). Since many applications require access to more code (program instructions) than the computer can store in RAM, much of the less urgent code is stored on secondary memory. The art of VM programming lies in ensuring that this code is readily available when the processor needs it.

This aspect of memory management is made somewhat more tricky by the fact that computer applications, such as MS Word (as opposed to the operating system) have their own memory management, which can "resist" the decisions made by the memory management unit (MMU); as a result, modern operating systems, all of which have VM components, actually keep the identity of memory pages secret; only the MMU knows, and hence the efforts of applications to reside on the RAM whenever the computer is running them, are thwarted.

The introduction of VM to Windows 3.1 in 1990 is credited with giving that software the ability to run viably on the Intel 386 CPU; previous releases of Windows had been a failure.
*VM (the product) later became a component of VM/CMS, which—despite IBM indifference—has actually survived among users of the System/360. VM/CMS was the subject of a highly-acclaimed book-length history, VM and the VM Community: Past, Present, and Future (Melinda Varian).
ADDITIONAL READING & SOURCES: "Multics Virtual Memory - Tutorial and Reflections," by Paul Green. This is very arcane and includes a lot of recondite details such as the fact that the General Electric GE-645 computer at MIT for which Multics was developed used a 36-bit word instead of the 32-bit flaoting point word employed by the IBM System/360.



Post a Comment

<< Home