Path: utzoo!attcan!uunet!spool.mu.edu!sdd.hp.com!usc!apple!snorkelwacker.mit.edu!bloom-beacon!eru!hagbard!sunic!mcsun!cernvax!chx400!bernina!neptune!inf.ethz.ch!brandis From: brandis@inf.ethz.ch (Marc Brandis) Newsgroups: comp.os.msdos.programmer Subject: Re: XMS vs EMS (performance) Message-ID: <23612@neptune.inf.ethz.ch> Date: 31 Jan 91 10:10:32 GMT References: <1991Jan30.134859.22160@linus.mitre.org> <2184@njitgw.njit.edu> Sender: news@neptune.inf.ethz.ch Reply-To: brandis@inf.ethz.ch (Marc Brandis) Organization: Departement Informatik, ETH, Zurich Lines: 39 In article <2184@njitgw.njit.edu> cd5340@mars.njit.edu (Charlap) writes: >I'd go with XMS, since EMS appears to be slowly on its way out. It seems >quite logical that the packet drivers will soon be available in full >protected mode, and when that happens, it will be much easier to convert >your program over to that format (which, I assume, would be the most >preferable in this situation) > >--- Dave (cd5340@mars.njit.edu) Although it is true that EMS is on its way out, I do not think that this advice really helps. As I understand the original question, the problem is to store multiple megabytes of data to memory at the rate they come from the driver, which is about 700 kBytes/s. Once the driver is running in protected mode, this is as simple as writing it continously to a large block of memory, so there is no problem at all. But at the moment the problem is: how can that much data received in real mode be moved to some kind of additional memory in a simple way. And here I would say EMS is the simpler solution. Getting interrupts in protected mode and routing them to real mode within certain time limits is a messy business. Current DOS extenders are not great in time-critical interrupt handling stuff, so you probably would have to write your own. On the other hand, with EMS, the interrupt driven driver can just receive into a large circular buffer in conventional memory and this buffer can be copied to EMS in the background (speak: between interrupts). If the buffer is large enough you are much less likely to run into timing problems. If a compare the efforts required to implement the EMS solution to the ones required for a XMS solution, I would go for EMS. Once he has a driver running in protected mode he can get rid of all the code he has written for receiving the data and managing the buffer, no matter whether he goes for EMS or XMS. So, keep it as simple as possible. Marc-Michael Brandis Computer Systems Laboratory, ETH-Zentrum (Swiss Federal Institute of Technology) CH-8092 Zurich, Switzerland email: brandis@inf.ethz.ch