From: Per Sandberg <per.sandberg@bredband.net>
To: comp.lang.ada@ada-france.org
Subject: Re: binary size (gnat+win console)
Date: Mon, 02 Aug 2004 06:21:38 +0200
Date: 2004-08-02T06:21:38+02:00 [thread overview]
Message-ID: <mailman.55.1091420516.416.comp.lang.ada@ada-france.org> (raw)
In-Reply-To: <ceja7o$2mc0$1@ulysses.news.tiscali.de>
Hi,
I sounds like you are building with static runtimes and have debug
symbols in the executable.
Some months ago i did a test with code sizes for hello_world and using
Ada compiled with GNAT
C compiled with GCC and MS VC++ 6.0
and the size of the executables was about 10K bytes.
I did not looke any further since the sizes from all three compilers was
about the same when doing the same thing.
* Building with full opimization.
* Use dynamic linked runtimes.
* Dont include debug symbols in the executable.
(This is using GNATPro 5.03w) and i dont remember when dynamic runtimes
was introduced in GNAT.
From my experience:
Most compilers produces executables of comparable sizes (+/- 15%)
when doing the same thing
* Linking the same way (Dynamic or static runtimes),
* Having the same set of runtime checks enabled (Suppress all
checks when copmparing Ada and C/C++).
* With or without debug symbols,
* Same optimsztion settings.
/Per
Andi wrote:
> hello,
>
> a simple "hello-world" binary takes 219kb after building !?
> there are ways for optimizations ??
>
> best regards
>
>
> ---
> with Ada.Text_Io;
> use Ada.Text_Io;
>
> procedure Hello is
> begin
> Put_Line("Hello World");
> end Hello;
> ---
>
> _______________________________________________
> comp.lang.ada mailing list
> comp.lang.ada@ada-france.org
> http://www.ada-france.org/mailman/listinfo/comp.lang.ada
>
next prev parent reply other threads:[~2004-08-02 4:21 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-08-01 17:45 binary size (gnat+win console) Andi
2004-08-01 21:48 ` alwa
2004-08-01 23:27 ` Andi
2004-08-01 22:39 ` Adrian Knoth
2004-08-02 5:16 ` Ludovic Brenta
2004-08-02 4:21 ` Per Sandberg [this message]
2004-08-02 13:04 ` Georg Bauhaus
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox