www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1994/08/04/21:12:43

Date: Thu, 4 Aug 94 18:43:26 -0400
From: dj AT ctron DOT com (DJ Delorie)
To: OKRA AT max DOT tiac DOT net
Cc: djgpp AT sun DOT soe DOT clarkson DOT edu
Subject: Re: program sizes solved

>   I have had about five letters all telling me the same thing - coff2exe 
> padds the program so it is on a 1k boundary to make it easier to load 
> into memory.  I'm not sure I believe loading x number of 1k segments and 
> then a few trailing bytes is that hard to do, but I guess it makes sense, 
> since my magic number was 27 * 1024.

Actually, it pads it to a 512 byte boundary - the disk sector size.
The reason why is because go32 *pages* the executable, which means
it's constantly reading *random* blocks.  Aligning these reads saved
10% of the total run time for small programs.


- Raw text -


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