cvs.gedasymbols.org/archives/browse.cgi   search  
Mail Archives: djgpp/1997/01/11/02:33:40

From: "John M. Aldrich" <fighteer AT cs DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Memory map file output for DJGPP?
Date: Fri, 10 Jan 1997 18:45:32 -0800
Organization: Two pounds of chaos and a pinch of salt
Lines: 28
Message-ID: <32D6FECC.694C@cs.com>
References: <32D6733D DOT A34 AT shoreland DOT com>
Reply-To: fighteer AT cs DOT com
NNTP-Posting-Host: ppp101.cs.com
Mime-Version: 1.0
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

Ray Ratelis wrote:
> 
> What is the coomand-line parameter for outputting a memory map of my
> prog?
> I just compiled a seemingly tiny prog and the executable is over 100k!
> I want to know where all toe space is being used up.

There is a fair bit of overhead involved in compiling 32-bit programs. 
A large part of the compiled code of small programs is taken up by the
DJGPP startup code, and by debugging information.  See the DJGPP FAQ
(v2/faq202b.zip) section 8.15 for a precise explanation, and
instructions on how to reduce the compiled size.

BTW, if you use any <conio.h> functions in your code, that adds about
40k to the compiled size.  Why?  Because all the conio functions come in
one source module, so they all get linked in when you compile.  Don't
fly off the handle - they are so interrelated that you can't easily
separate them.

Hope this helps!

-- 
---------------------------------------------------------------------
| John M. Aldrich, aka Fighteer I  |        fighteer AT cs DOT com         |
| Call me for your free AOL disk!  |   http://www.cs.com/fighteer   |
|  Chain letters, work-at-home schemes, free long distance, etc.,   |
|    are ILLEGAL!  Keep the Internet litter-free... don't SPAM.     |
---------------------------------------------------------------------

- Raw text -


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