comp.lang.ada
 help / color / mirror / Atom feed
From: stt@houdini.camb.inmet.com (Tucker Taft)
Subject: Re: C's register keyword
Date: 1997/09/08
Date: 1997-09-08T00:00:00+00:00	[thread overview]
Message-ID: <EG71Ex.4D6.0.-s@inmet.camb.inmet.com> (raw)
In-Reply-To: 5uqhm2$t48$1@goanna.cs.rmit.edu.au


Tristan Ludowyk (ludowyk@yallara.cs.rmit.edu.au) wrote:
: is there an ada equivelent to 'register' in C/C++?

In Ada 95, any local variable not declared "aliased" is a candidate
for living in a machine register.  The compiler decides based
on usage.

For global variables, some C compilers support the use of
the "register" keyword, but normally there is also some kind
of pragma to identify which register should be devoted to
the variable.  The same kind of pragma could certainly be
implemented in Ada (and may already be so in some compilers) for 
assigning a global variable to a machine register.

: Tristan.
: -- 
:     _/                 Tristan Ludowyk                               \_\_\_\_
:    _/_/     RMIT Comp.Sys.Eng/Comp.Sci - 1st year   ____TTTc____/|    \_\_\_
:   _/_/_/    Email: ludowyk@yallara.cs.rmit.edu.au    (_u|||_o_) \|     \_\_
:  _/_/_/_/        "Donkeys live a long time"             ^^^             \_

--
-Tucker Taft   stt@inmet.com   http://www.inmet.com/~stt/
Intermetrics, Inc.  Burlington, MA  USA




  parent reply	other threads:[~1997-09-08  0:00 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1997-09-06  0:00 C's register keyword Tristan Ludowyk
1997-09-06  0:00 ` Tarjei T. Jensen
1997-09-10  0:00   ` Richard Kenner
1997-09-08  0:00 ` Tucker Taft [this message]
1997-09-08  0:00   ` David Weller
1997-09-09  0:00     ` Fergus Henderson
1997-09-11  0:00       ` Robert Dewar
replies disabled

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