comp.lang.ada
 help / color / mirror / Atom feed
* Conversion factor for Ada 95
@ 1997-02-11  0:00 James Squire
  1997-02-13  0:00 ` Robert Dewar
  0 siblings, 1 reply; 4+ messages in thread
From: James Squire @ 1997-02-11  0:00 UTC (permalink / raw)
  Cc: Team-Ada mailing list


I'm trying to estimate a conversion factor for a particular Ada 95
compiler on a particular target.  The conversion is from SLOC (loosely
translated:  number of semi-colons) to bytes of executable code.

Does anyone have any guidance on how I could do this, given that I have
little to no past history to base it on (Ada 95, that is)?  Is there any
research published on the WWW that speaks to this?
-- 
James Squire           mailto:m193884 no junk mail
allowed@csehp1.mdc.com
MDA Avionics Tools & Processes
McDonnell Douglas Aerospace              http://www.mdc.com/
Opinions expressed here are my own and NOT my company's
"Would you prefer to be conscious or unconscious during the mating? I
would
 prefer conscious, but I don't know what your...pleasure threshold is."
	-- G'Kar (to Lyta Alexander), "The Gathering"




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Conversion factor for Ada 95
  1997-02-11  0:00 Conversion factor for Ada 95 James Squire
@ 1997-02-13  0:00 ` Robert Dewar
  1997-02-14  0:00   ` David Emery
  1997-02-14  0:00   ` Erik Magnuson
  0 siblings, 2 replies; 4+ messages in thread
From: Robert Dewar @ 1997-02-13  0:00 UTC (permalink / raw)



James Squire asks

<<I'm trying to estimate a conversion factor for a particular Ada 95
compiler on a particular target.  The conversion is from SLOC (loosely
translated:  number of semi-colons) to bytes of executable code.>>

It is absolutely *essential* in a language like Ada to also factor 
coding style into this equation, otherwise you can get some very nasty
surprised. For instance, code using finalization heavily can generate
lots of extra code, as can heavy tasking code.





^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Conversion factor for Ada 95
  1997-02-13  0:00 ` Robert Dewar
@ 1997-02-14  0:00   ` David Emery
  1997-02-14  0:00   ` Erik Magnuson
  1 sibling, 0 replies; 4+ messages in thread
From: David Emery @ 1997-02-14  0:00 UTC (permalink / raw)



Perhaps more importantly, you need to factor in generics.  After all,
a generic instantiation (one line of source code) can generate
megabytes of machine code.  (I spent the last 3 months reworking a
generic where every instantiation produced about 350kb of machine
code, and we expected about 250 instantiations.   So that's 87.5mb.
If memory costs $100/16mb, that's $500 per workstation.  Multiply this
times 250 workstations, and you're talking some real money here...)

				dave
-- 
Note: if email to me bounces, use 'emery@grebyn.com'






^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Conversion factor for Ada 95
  1997-02-13  0:00 ` Robert Dewar
  1997-02-14  0:00   ` David Emery
@ 1997-02-14  0:00   ` Erik Magnuson
  1 sibling, 0 replies; 4+ messages in thread
From: Erik Magnuson @ 1997-02-14  0:00 UTC (permalink / raw)



dewar@merv.cs.nyu.edu (Robert Dewar) writes:

> <<I'm trying to estimate a conversion factor for a particular Ada 95
> compiler on a particular target.  The conversion is from SLOC (loosely
> translated:  number of semi-colons) to bytes of executable code.>>
> 
> It is absolutely *essential* in a language like Ada to also factor 
> coding style into this equation, otherwise you can get some very nasty
> surprised. For instance, code using finalization heavily can generate
> lots of extra code, as can heavy tasking code.

Amen to that. I was asked to do SLOC to byte measurements as part of some
compiler evaluations for Ada 83 some time back.  The code used was from 5
different sources, but the for the same applications domain (i.e. embedded
avionics.)  Using the same compiler and the same compile options, there was
a 5 to 1 difference between the largest and the smallest factors.  This was
greater than the both compiler and target architecture factors! This is
where I really learned to appreciate YMMV disclaimers.

-- 
Erik Magnuson, ENSCO    erik@fl.ensco.com
MARSS-REPL              (407) 783-7114




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~1997-02-14  0:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-02-11  0:00 Conversion factor for Ada 95 James Squire
1997-02-13  0:00 ` Robert Dewar
1997-02-14  0:00   ` David Emery
1997-02-14  0:00   ` Erik Magnuson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox