To: opendos AT delorie DOT com Date: Sat, 2 Dec 2000 05:11:47 -0800 Subject: Re: BASIC & EMS (was: Optimizing CONFIG.SYS...) Message-ID: <20001202.051149.-616891.0.domanspc@juno.com> X-Mailer: Juno 4.0.11 MIME-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Juno-Line-Breaks: 0-5,8,13-14,24-27,38-41,46-47,58-59,69-72,78-79,81-85,88-89,96-97,107-110,123-124,131-132,134-138,140-141 X-Juno-Att: 0 X-Juno-RefParts: 0 From: Robert W Moss Reply-To: opendos AT delorie DOT com Blood Pressure Pat, Blood Pressure. From my Novell Dos 7 unleashed Book, by Jonathan Kamin, Sams Publishing: Extended Memory: "If you have an 80286-or-higher CPU, you can have extended memory in addition to conventional memory. Extended memory, from the point of view of the CPU, simply is additional memory with addresses that begin at the one megabyte boundary. What makes this memory "extended" (insted of just memory) is DOS. Other operating systems, which don't have DOS's limitations, simply regard that memory as contiguous with conventional memory, and don't require the electronic aacrobatics that DOS does to get at it. Because you are using DOS, unless you manage this memory properly there's not a whole lot you can do with it. You have to use an extended-memory manager conforming to the Extended Memory Specification (XMS) if you want to use this memory for anything other than a RAM disk or some types of disk cache. (It follows that you need an XMS memory Manager to access the High Memory Area, or HMA. Without a memory manager, a program that attempts to use extended memory won't be aware of other programs using it. As a result, the programs may stomp all over each other's data, causing massive problems. Fortunately, Novell DOS 7 can take care of that problem for you. The HMA: The high memory area, or HMA, is the first 64K just above the first megabyte - that is, the first 64K of extended memory. What makes this area special is that, due to a quirk in the way 80286-and -higher CPUs address memory, DOS can see what's in it as though it were the first 64K of conventional memory. Because of this quirk, various programs can use the HMA to store chunks of code that otherwise would have to be in conventional memory. DOS can store part of its code in this area (with your assistance). Certain other programs also can make use of this area, including MS Windows, DESQview, and the Framework programs. The catch is that only one program can have access to the HMA at a time, even if it uses only part of that area. Expanded Memory: Expanded memory is no different in kind from other types of memory already discussed, but what you can do with it is. Expanded memory is memory that is managed according to the Lotus-Intel-Microsoft Expanded Memory Specification (called LIM-EMS for short). The current version is generally referred to as LIM-EMS 4.0, or just LIM 4.0 or EMS 4.0. If you have an 80386-or-higher CPU, you can use a memory manager to emulate expanded memory using the extended memory that's already installed in your system. If you have an 8088 or 80286, you can add an expanded-memory board, and gain access to that expanded memory by using the device driver that came with the board. Unless you have an 80386-or-higher CPU or a special memory-management chip set (such as NeAT, SCAT, or LeAP), you must use an expanded memory board to get expanded memory. You can't get it from extended memory. This is because managing expanded memory requires some additional circuitry not found on the 80286. This circuitry, which is built into the 80386 and into the memory-management chip sets, is not otherwise available on XTs or ATs. Expanded memory, like extended memory managed with an XMS memory driver, is memory that can be made accessible to DOS. However, the method for doing so is different from the one used for XMS memory. Ideally, you set aside a 64K block of addresses in upper memory to be used as a page frame. Y ou might think of this as a sort of viewing screen that can be made to focus on anything that's in expanded memory. It looks at expanded memory in upmto four 16K chunks, thereby making up to 64K at a time of whatever's in expanded memory available to DOS. (If you don't have a 64K block of upper -memory addresses, you can sometimes use four 16K pages instead of a page frame." Protected Mode: "The 80286 introduced a new operating mode called protected mode. In protected mode , the 80286 could address up to 16M of memory. However, most PC users used AT-class computers in reak mode, in which the processor essentially emulated an 8088. To take advantage of the additional (extended) memory that the 80286 couls address, DOS extenders were developed. These allowed programs to access extended memory "behind the back" of DOS. Two standards developed for accessing protected mode: * VCPI (the Virtual Control Program Interface) * DPMI (the DOS Protected Mode Interface) Because the latter had the marketing clout of MS behind it , it has become the more common standard. It is used by MS Windows, among other programs. Novell DOS 7 includes a DPMI interface (technically, a DPMI host) to manage the use of extended memory by programs that use it . On a PC with an 80386-or-higher CPU, the DPMI host gives DPMI client programs access to extended memory, and switches between real and protected modes as needed. Programs that require DPMI services generly comprise programmers' tools, but Borlands's Paradox database program is one application that also makes use of these services. Novell DOS 7 also invludes a new feature called DOS Protected Mode Services (DPMS). This allows TSR programs - if they're designed to use these services = to operate almost entirely outside of conventional memory. They merely have to leave a few bytes of code in upper memory to tell DOS where to find the rest of the program. This frees additi;onal upper memory for programs that can't use the new seravices. The Stacker compressed drive management program, NWCache, DELWATCH, and the NetWare Desktop Server all make use of DPMS, and can therefore run in protected mode. This means not only that they run outside of conventional memory, but that they run while you're using your foreground program. Virtual 8086 Mode: The 80386 -or-higher CPUs introduced yet another operating mode: virtual 8086 mode. In this mode, the processor is, in effect, divided into a series of seperate 8086-based computers, each operating in real mode, each with its own screen, keyboard, and segment of memory. How does this work? Well, noter the word virtual. You have lnly one program active on your screen at a time , and the keyboard is attached to that program. The other 8086 computers have virtual screens and keyboards, and run in the background while you're working in the foreground program. This is what's known as multitasking, another feature built into Novell DOS 7. To use this feature , you need a control program to manage the multitasking. MS Windows in 80386 Enhanced Mode is one such progaram: DESQview is another. And Novell DOS 7 includes a third: the Task Manager. What does this have t;o do with memory? Well, you can multitask programs only as long as they are in memory... somewhere. The number of programs you can multitask depends on how much memory you have , how large your programs are, and how you allocate the memory for multitasking. Among other things, you must load the DPMI host in order to use the Task Manager for multitasking, and you must leave certain areas of memory free for it to function properly. " Hope this does not confuse to many people lurking out there in the shadows while this great big hairy conflict rushes on & on & on....... BOB "DOMAN" MOSS 'Chocolate is a vitamin, it is, it is....' On Fri, 1 Dec 2000 03:57:12 -0700 "Patrick Moran" writes: > Okay, what the hello is XMS meory? ________________________________________________________________ GET INTERNET ACCESS FROM JUNO! Juno offers FREE or PREMIUM Internet access for less! Join Juno today! For your FREE software, visit: http://dl.www.juno.com/get/tagj.