delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1996/12/05/15:06:01

From: sandrof AT microsoft DOT com (Alessandro Forin)
Subject: RE: Smallest program
5 Dec 1996 15:06:01 -0800 :
Sender: daemon AT cygnus DOT com
Approved: cygnus DOT gnu-win32 AT cygnus DOT com
Distribution: cygnus
Message-ID: <c=US%a=_%p=msft%l=RED-77-MSG-961205214906Z-75513.cygnus.gnu-win32@INET-01-IMC.microsoft.com>
Original-To: "'gnu-win32 AT cygnus DOT com'" <gnu-win32 AT cygnus DOT com>
X-Mailer: Microsoft Exchange Server Internet Mail Connector Version 4.0.994.63
Encoding: 63 TEXT
Original-Sender: owner-gnu-win32 AT cygnus DOT com

I merely forwarded the reply from the VC++ guys.
Since it seems to have caught some attention, here it is for all

>----------
>
>Sent: 	Wednesday, December 04, 1996 2:30 PM
>To: 	Alessandro Forin; Visual C++ Special Interest Group
>Subject: 	RE: Size of smallest program
>
>[ Thanks to <> for reminding me of the linker options - I knew they existed I
>just couldn't remember what they were ]
>
>	cl /O2 /MD /GF hello.c /link /optidata /merge:.rdata=.text
>
>Gives an .exe size of 2048 bytes
>
>-----Original Message-----
>
>Sent:	Wednesday, December 04, 1996 2:14 PM
>To:	Alessandro Forin; Visual C++ Special Interest Group
>Subject:	RE: Size of smallest program
>
>Compiling the same program with VC++ 5.0 with the following options
>	
>	cl /O2 /MD /GF hello.c
>
>generates a program of 3072 bytes - 1 page of .data, 1 page of .idata, 1 page
>of .rdata and 1 page of .text.
>


>----------
>From: 	root AT jacob DOT remcomp DOT fr[SMTP:root AT jacob DOT remcomp DOT fr]
>Sent: 	Thursday, December 05, 1996 3:33 AM
>To: 	gnu-win32 AT cygnus DOT com
>Subject: 	Re: Smallest program
>
>Thanks to all that replied.
>It seems, that MSVC wins again. What was very interesting is the option that
>allows the linker to MERGE two sections into one (sent by
>sandrof AT microsoft DOT com)
>
>I was considering modifying my linker to do that, but the huge number of bugs
>that I could introduce, and the sheer difficulty of assuring a 100% correct
>result made me leave that for later... 
>
>As the size of the 'hello.exe' from MSVC, it seems that I was linking the
>MSVC
>library statically, so the size of the executable generated was much bigger
>than it should have been.
>
>gcc then, (using the minimalist version), achieves the same result (if I can
>find the 32 bytes I'm adding somwhere... :-)
>
>-- 
>Jacob Navia	Logiciels/Informatique
>41 rue Maurice Ravel			Tel 01 48.23.51.44
>93430 Villetaneuse 			Fax 01 48.23.95.39
>France
>-
>For help on using this list, send a message to
>"gnu-win32-request AT cygnus DOT com" with one line of text: "help".
>
-
For help on using this list, send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


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