From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: From: presotto@closedmind.org To: 9fans@cse.psu.edu Subject: Re: [9fans] Virtual memory & paging MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Date: Sun, 3 Feb 2002 16:53:06 -0500 Topicbox-Message-UUID: 4aecdb24-eaca-11e9-9e20-41e7f4b1d025 Virtual memory covers any memory that isn't laid out exactly as it seems to an executing program, i.e., that there exists some mapping between addresses as seen by the execution unit and those on the bus to physical memory. The mapping can happen a number of ways. The two more popular are via paging hardware or segmentation hardware. Pages are typically fixed size and segments variable size. From the PDP-11 to the MIPS there have been enough flavors that the distinction is a bit blurred. If one is willing to move data between a backing store and main memory in addition to chaging the mappings, one can make the main memory appear larger than it really is. This is usually termed demand paging or demand segmentation. An earlier technique, still in use in addition to demand paging/ segmentation is swapping. If many processes are running on a particular system, it may desirable to swap in main memory one for another to give the illusion of a main memory that can hold all of them. And of course there is the even earlier technique of overlays. Here one figures out the execution tree of routines in a program. One might note that routine A will never be an ancestor of routine B or vice versa. THerefore, there's no requirement that they live in memory simultaneously and can occupy the same memory locations, just at different times.