delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1994/05/15/00:14:43

From: sandmann AT clio DOT rice DOT edu (Charles Sandmann)
Subject: Re: Disk Paging question and Windows Dos Box
To: meetze AT charlie DOT ece DOT scarolina DOT edu (Murle C. Meetze III)
Date: Sat, 14 May 1994 22:43:07 -0600 (CDT)
Cc: djgpp AT sun DOT soe DOT clarkson DOT edu

> I am just wondering I know that gcc compiled programs can page to disk,
> but I have just one question.  I was testing this on my 486SLC2 66MHz,
> using a dos box in windows (ver. 3.1) and by just using dos (ver. 5.0)
> and was wondering why that by running it under windows in a dos box it
> takes so long to run, and makes such a big page file where under dos it is
> fast and doesn't make a huge page file.

Under DOS, GO32 provides the paging services.  It is smart enough to know
when a page has been modified.  In your example, you allocate the memory
but don't touch it, so GO32 does not allocate it yet.  Under DPMI the
memory is allocated at malloc time, so it all appears in the page file.
Try zeroing all the memory you malloc'ed and you should see very similar
results.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019