home *** CD-ROM | disk | FTP | other *** search
- Path: globe.indirect.com!fnf
- From: fnf@fishpond.ninemoons.com (Fred Fish)
- Newsgroups: comp.sys.amiga.programmer
- Subject: Re: GCC C++ questions
- Date: 26 Mar 1996 06:52:36 GMT
- Organization: Cronus
- Message-ID: <4j847r$omc@globe.indirect.com>
- References: <314c6829@usura.metropolis.nl> <4il6kv$3tc@news6.erols.com> <4iupvp$131e@baggins.cc.flinders.edu.au>
- NNTP-Posting-Host: amigalib.com
-
- In article <4iupvp$131e@baggins.cc.flinders.edu.au>,
- Daniel J. O'Connor <doconnor@sybil.ist.flinders.edu.au> wrote:
-
- >Try Storm C, it compiles the abovve program to, uhh, 2840 bytes :)
- >This was with the default settings too =)
-
- All this proves is that it's libraries have been organized to minimize
- the amount of runtime support code pulled into the executable, or
- perhaps it uses a shared library for the C++ runtime. Gcc compilers
- this code to 40 bytes, though the object file wrapper placed around
- those 40 bytes is about 1Kb and certainly adding runtime support pulls
- in even more stuff:
-
- fishpond [83] g++ -c -O2 j.c
- fishpond [84] size j.o
- text data bss dec hex filename
- 33 7 0 40 28 j.o
- fishpond [85] ls -l j.o
- -rw-r--r-- 1 fnf cronus 984 Mar 25 23:49 j.o
-
- Looking for ways to build a minimum sized executable is interesting
- and entertaining, but seldom a useful metric for the usability of a
- compiler when applied to real programming projects.
-
- -Fred
- --
- CRONUS -- 1840 E. Warner Road #105-265 -- Tempe, AZ 85284 -- USA
- Voice: (800) 804-0833 or (602) 491-0442 FAX: (602) 491-0048
- Email: info@ninemoons.com
- Ftp site: ftp.ninemoons.com
-