From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,63bbc3281a2f80ea X-Google-Attributes: gid103376,public From: dewar@cs.nyu.edu (Robert Dewar) Subject: Re: Ada vs. C Date: 1996/08/09 Message-ID: #1/1 X-Deja-AN: 173138118 references: <3208F2BA.E34@freenet.scri.fsu.edu> organization: Courant Institute of Mathematical Sciences newsgroups: comp.lang.ada Date: 1996-08-09T00:00:00+00:00 List-Id: The Quelisher says "I have found one thing that C has an advantage over Ada : executable file sizes. Everything I have programmed in Ada is HUGE compared to a program thta does the same thing but written in C." That's bogus, comparable programs in Ada and C will generate executables of the same size, at least using a technology like GNAT. You have however to be careful about that "comparable". Note for example that in GNAT, by default the executable files contain debugging information which is typically much more voluminous than the code itself -- so make sure you are comparing stripped file sizes. Second, in some version of GNAT, the default is to link statically, and in others to link dynamically. Be careful you are not comparing a statically linked Ada program to a dynamically linked C program. It's true that in the default configuration on some ports of GNAT, the exe files will be bigger, due in particular to the inclusion by default of debugging information. This choice of defaults is deliberate and reflects the fact that disk prices have dropped dramatically, so the gain from having the debugging information around seems worth the space (after all a 300K file these days is occupying 5 cents worth of disk space). Note also that it is ONLY a space issue, the debugging information is not loaded if you are not debugging. But anyway, if you don't want the debugging information, just make sure it is stripped.