Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!killer!texbell!bigtex!milano!cs.utexas.edu!rutgers!mailrus!ncar!noao!amethyst!spock!chris From: chris@spock (Chris Ott) Newsgroups: comp.os.misc Subject: Re: a very naive Question??? Message-ID: <837@amethyst.ma.arizona.edu> Date: 12 Oct 88 02:30:36 GMT Sender: news@amethyst.ma.arizona.edu Reply-To: chris@spock.ame.arizona.edu (Chris Ott) Organization: Computer-Aided Engr. Lab (CAEL), University of Arizona, Tucson Lines: 86 mark@hubcap.UUCP (Mark Smotherman) writes: > > In article <835@amethyst.ma.arizona.edu>, chris@spock (Chris Ott) writes: > > Close, but not quite. Demand paging involves only the code portion of > ^^^^^^^^^^^^^^^^^^^^^ > > the program. > > > Page only the code portion? News to me! I didn't mean that only the code portion is paged, I meant that only the code portion is _demand paged_. Here, I made a slight mistake. It's not just the code portion, it's the _text_ portion. This includes code _and_ initialized (usually read-only) data. Sorry. Anyway, as in the Sun Commands Reference manual, under ld(1): -z Arrange for the process to be loaded on demand from the resulting executable file rather than preloaded. i.e. Rather than loading the entire file into memory at once, like some systems do, load the pages as they are needed. This only applies to the text portion of the program, not data, like local variables of subroutines and such. By the way, I also have a Data General manual that describes demand paging, and it says almost the same thing. If you want me to dig it up and post what it says, let me know. > To say that virtual memory requires demand _paging_, I would have to > reclassify all the segmented machines (also the B5500). I didn't say that. I said that demand paging requires virtual memory. I also said that I'm not sure this is true, although I can't imagine right off the top of my head how a system could do it without virtual memory. > If segmentation > is not a virtual memory technique, then what is it? It depends on what kind of segmentation it is and the capabilities of your processor. Simple mapping from a logical address to a physical address (making the process think it's in one place in memory when it's really in a totally different place) is _not_ virtual memory, as was asserted by Ron Heiby in his article. If the segmentation allows your process to think it's using 50 megabytes of memory when there are only 4 megabytes of main memory in your computer, then yes, that's virtual memory. There are many architectures that use a 68000 with hardware memory management (usually base-limit style) that are not virtual memory systems. Here, we have an Exormacs chassis with an 8Mhz 68000 and hardware memory management (logical to physical address mapping). To the best of my knowledge, this system has _never_ been advertised as a virtual memory system. According to Ron's definition, it _is_ a virtual memory system. If you correctly remember, the big deal about the 68010 was that it could continue an instruction after it was interrupted by a bus error, thus giving it _virtual memory_ capability. When the 68010 tries to access a page that isn't currently in memory, the external hardware gives it a bus error signal. Then, the 68010 can stop what it was doing, go to the disk, bring in the page that it tried to access, and restart the instruction right where it left off. If all the pages in main memory are used, it finds another page, puts it on the disk, and "pages in" the page it needs. The 68000 could never do this, because it cannot restart an instruction that was interrupted by a bus error. Yet, there are many 68000 systems that can do what Ron said a virtual memory system does. > These authors state "Virtual memory is a technique that allows the execution > of processes that may not be completely in memory. The main visible > advantage of this scheme is that user programs can be larger than physical > memory." Basically this definition of virtual memory is correct, and I'm pretty sure I would consider any system that can do this a virtual memory system. If you still don't believe me, let's take this to comp.arch and ask them what they think. Chris ------------------------------------------------------------------------------- Chris Ott Computational Fluid Mechanics Lab Just say "Whoa!!" and University of Arizona vote for Randee!! Internet: chris@spock.ame.arizona.edu UUCP: {allegra,cmcl2,hao!noao}!arizona!amethyst!spock!chris -------------------------------------------------------------------------------