comp.lang.ada
 help / color / mirror / Atom feed
From: Martin Krischik <krischik@users.sourceforge.net>
Subject: Re: Dynamically tagged expression required
Date: Thu, 15 Dec 2005 21:10:57 +0100
Date: 2005-12-15T21:10:57+01:00	[thread overview]
Message-ID: <24672866.sB0hhNGmCm@linux1.krischik.com> (raw)
In-Reply-To: dnoro8$er9$1@sunnews.cern.ch

Maciej Sobczak wrote:

> Martin Krischik wrote:
> 
>>>>Yes. But it only look like the parameter is initialized. Internally the
>>>>compiler likely to use a pointer to pass the paramer to speed up things.
>> 
>>>I don't care. :)
>>>I don't want to call something a "pointer" when it isn't in my program.
>> 
>> I don't care either. But we at c.l.a had to repeat the << "in" is not
>> slower then "access" >> mantra so often that we just say it automatily
>> now ;-) .
> 
> OK, I see. I think it's "normal" in some way - we (on other forums) are
> busy breaking myths about C++ as well. ;)
> 
> As for your mantra - depending on how compiler does its job, "in" might
> be actually *faster* than "access" for the following reason: "access"
> might imply indirection, whereas "in" might be just another (although
> const) name for the actual parameter, especially when the compiler
> inlines the whole call. I don't see anything that would forbid this and
> therefore I wouldn't be surprised to see such "inverse" effects in
> performance measurements. Is this reasoning correct for Ada?

"pass by register" is an option for Ada as well. Maybe not for Intel CPU due
to the limited amount of registers available.

Martin
-- 
mailto://krischik@users.sourceforge.net
Ada programming at: http://ada.krischik.com



      reply	other threads:[~2005-12-15 20:10 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-08 13:50 Dynamically tagged expression required Maciej Sobczak
2005-12-08 14:46 ` Georg Bauhaus
2005-12-08 14:52 ` Dmitry A. Kazakov
2005-12-08 19:17 ` Martin Krischik
2005-12-09  9:09   ` Maciej Sobczak
2005-12-09 12:05     ` Jean-Pierre Rosen
2005-12-09 16:41     ` Robert A Duff
2005-12-09 20:18       ` Martin Krischik
2005-12-11  0:43         ` Matthew Heaney
2005-12-11 11:45           ` Martin Krischik
2005-12-11 14:24             ` Matthew Heaney
2005-12-11 15:18               ` Martin Krischik
2005-12-11 18:07             ` Matthew Heaney
2005-12-12 19:16               ` Martin Krischik
2005-12-13 20:43                 ` Georg Bauhaus
2005-12-13 21:00                   ` Georg Bauhaus
2005-12-09 20:41       ` Randy Brukardt
2005-12-09 20:16     ` Martin Krischik
2005-12-11  0:46       ` Matthew Heaney
2005-12-12  9:44       ` Maciej Sobczak
2005-12-12 19:13         ` Martin Krischik
2005-12-14 10:22           ` Maciej Sobczak
2005-12-15 20:10             ` Martin Krischik [this message]
replies disabled

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