From: Stephen Leake <stephen.a.leake.1@gsfc.nasa.gov>
Subject: Re: Expected bytes per sloc (semicolons) performance
Date: 24 Sep 2001 13:03:13 -0400
Date: 2001-09-24T17:04:41+00:00 [thread overview]
Message-ID: <ug09c4j3i.fsf@gsfc.nasa.gov> (raw)
In-Reply-To: 3BAB8028.18CCD530@yahoo.com
default <joel_seidman.NOESPAME@yahoo.com> writes:
> Mats Weber wrote:
> >
> > >Rules about n bytes per sloc are just too processor, compiler, and
> > >coding style dependent to be useful.
> >
> > I would put a big emphasis on coding style here. If you use a lot of
> > generics, the code will be generated once for each instance in most
> > implementations.
>
> I agree there is a relation between coding style and bytes/sloc.
>
> But I don't understand the specific denigration of generics, which I've
> heard occasionally. It seems to me the alternative to generics is
> nearly-duplicate packages and procedures, usually created by brute-force
> cut-and-paste in a text editor. You end up with the same amount of
> object code, but with the disadvantage that it is harder to maintain
> than if you had used generics.
>
> Is there a flaw in my reasoning?
I didn't get a "denigration of generics" from this. Mats is merely
pointing out that a style that uses generics will have a _much_ higher
number for bytes/sloc than a style that doesn't. This is neither bad
nor good; it's just a fact. It does argue that "bytes/sloc" is not a
useful measure.
It could also be that a particular application domain will lend itself
more to generics than some other domain, independent of programmer
style.
The one reason I have sometimes not used a generic was when the
debugger did not support them. This was true for Alsys Ada, and is
still true for Tartan Ada (both Ada 83). The GNAT debugger supports
generics; I'm not sure of other current compilers.
--
-- Stephe
next prev parent reply other threads:[~2001-09-24 17:03 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-09-18 22:03 Expected bytes per sloc (semicolons) performance Mike Harrison
2001-09-19 0:04 ` Jeff Creem
2001-09-19 10:13 ` Robert Dewar
2001-09-20 0:43 ` David B. Littell
2001-09-20 11:28 ` Steffen Huber
2001-09-20 13:10 ` Tarjei T. Jensen
2001-09-22 14:36 ` David B. Littell
2001-09-20 19:15 ` Mike Harrison
2001-09-21 14:02 ` Stephen Leake
2001-09-21 15:30 ` Mats Weber
2001-09-21 18:00 ` default
2001-09-24 17:03 ` Stephen Leake [this message]
2001-09-25 23:00 ` default
2001-09-25 16:08 ` tmoran
2001-09-25 16:44 ` Wes Groleau
2001-09-25 20:51 ` tmoran
2001-09-25 20:32 ` Stephen Leake
2001-09-25 21:04 ` Marin David Condic
2001-09-26 15:19 ` Stephen Leake
2001-09-26 16:58 ` Marin David Condic
2001-09-21 16:22 ` Ted Dennison
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox