comp.lang.ada
 help / color / mirror / Atom feed
From: bobduff@world.std.com (Robert A Duff)
Subject: Re: Garbage Collection in Ada
Date: 1996/10/20
Date: 1996-10-20T00:00:00+00:00	[thread overview]
Message-ID: <DzL7Bv.1CK@world.std.com> (raw)
In-Reply-To: dewar.845732059@merv


In article <dewar.845732059@merv>, Robert Dewar <dewar@merv.cs.nyu.edu> wrote:
>...As has been
>pointed out, this is not strictly correct code, but in the absence
>of a conservative garbage collector running around and deleting
>unrefrenced blocks (:-) will in fact work on any imaginable C
>compiler, ...

Not *quite* true -- there *are* C compilers that try to detect
non-ANSI-compliant use of pointers (for debugging purposes only, since
it's extremely inefficient), and you presumably would not be able to run
GIGI on such a compiler.  Of course GIGI is a special case -- when one
is committed to doing a bootstrapped compiler, one has a lot of freedom
to play games.  For example, I'm sure the GNAT front end would not
compile on any Ada compiler other than GNAT.  In fact, in some cases,
one version of the GNAT compiler won't compile under a different
(earlier or later) version of GNAT.

>The second answer is that in optimizing code, all sorts of transformations
>can occur, especially if you start doing high level optimization that
>can cause non-zero based arrays to appear as part of the transformations.
>This is the situation in which a compiler may end up fiddling with pointers
>in a way that is incompatible with a conservative GC. 

Oh, OK.  I didn't think that's exactly what "virtual origins" meant -- I
would call that "using algebraic transformations to represent pointers",
or "virtual-origin-like optimizations".  I guess it amounts to the same
thing.

>The use of a conservative GC system is, like the virtual origin coding
>in Gigi, something that probably works OK, even though it is requires
>some dubious fiddling (in particular the assumption that type casts
>from integer to pointer leave bits unchanged, something that the ANSI
>C specification could not require even if it wanted to).

They could have required that type casts of that nature don't lose
information, so they're reversible.  If they had wanted to, which they
didn't.

- Bob




  parent reply	other threads:[~1996-10-20  0:00 UTC|newest]

Thread overview: 126+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-10-13  0:00 Garbage Collection in Ada Jonas Nygren
1996-10-13  0:00 ` Robert Dewar
1996-10-13  0:00 ` Lars Farm
1996-10-13  0:00   ` Robert Dewar
     [not found]     ` <19961014115513529729@dialup105-2-16.swipnet.se>
1996-10-16  0:00       ` Robert Dewar
1996-10-16  0:00         ` Lars Farm
1996-10-16  0:00           ` Robert Dewar
1996-10-16  0:00             ` Hans-Juergen Boehm
1996-10-17  0:00               ` Robert A Duff
1996-10-17  0:00                 ` Larry Kilgallen
1996-10-17  0:00                 ` Hans-Juergen Boehm
1996-10-17  0:00               ` Robert Dewar
1996-10-17  0:00                 ` Hans-Juergen Boehm
1996-10-17  0:00             ` Lars Farm
1996-10-23  0:00               ` Robert Dewar
1996-10-16  0:00         ` Hans-Juergen Boehm
1996-10-16  0:00           ` Robert Dewar
1996-10-16  0:00             ` Hans-Juergen Boehm
1996-10-17  0:00               ` Robert Dewar
1996-10-17  0:00                 ` Hans-Juergen Boehm
1996-10-17  0:00                   ` Robert Dewar
1996-10-13  0:00   ` Larry Kilgallen
1996-10-14  0:00   ` John Howard
1996-10-15  0:00     ` Lars Farm
1996-10-15  0:00       ` Robert Dewar
1996-10-15  0:00         ` Lars Farm
1996-10-15  0:00         ` Hans-Juergen Boehm
1996-10-17  0:00         ` Thomas Kendelbacher
1996-10-17  0:00           ` Robert Dewar
1996-10-23  0:00         ` Richard A. O'Keefe
1996-10-23  0:00           ` Larry Kilgallen
1996-10-15  0:00       ` Robert A Duff
1996-10-14  0:00   ` Robert A Duff
1996-10-14  0:00     ` Lars Farm
1996-10-15  0:00       ` Robert A Duff
1996-10-16  0:00         ` Lars Farm
1996-10-16  0:00           ` Robert Dewar
1996-10-17  0:00             ` Robert A Duff
1996-10-19  0:00               ` Richard Kenner
1996-10-19  0:00               ` Robert Dewar
1996-10-19  0:00                 ` Lars Farm
1996-10-20  0:00                   ` Robert Dewar
1996-10-20  0:00                     ` Robert A Duff
1996-10-20  0:00                       ` Robert Dewar
1996-10-21  0:00                     ` Lars Farm
1996-10-21  0:00                       ` Robert Dewar
1996-10-21  0:00                         ` Lars Farm
1996-10-21  0:00                     ` Geert Bosch
1996-10-21  0:00                       ` Hans-Juergen Boehm
1996-10-23  0:00                     ` Fergus Henderson
1996-10-24  0:00                     ` Richard A. O'Keefe
1996-10-20  0:00                 ` Robert A Duff [this message]
1996-10-20  0:00                   ` Robert Dewar
1996-10-21  0:00                     ` Hans-Juergen Boehm
1996-10-21  0:00                       ` Robert Dewar
1996-10-15  0:00     ` Hans-Juergen Boehm
1996-10-15  0:00   ` Keith Thompson
1996-10-14  0:00 ` Jon S Anthony
1996-10-15  0:00   ` Robert Dewar
1996-10-15  0:00 ` Robert I. Eachus
1996-10-15  0:00   ` Robert Dewar
1996-10-16  0:00   ` whiting_ms@corning.com (Matt Whiting)
1996-10-16  0:00     ` Robert Dewar
1996-10-17  0:00   ` John Howard
1996-10-17  0:00     ` Robert Dewar
1996-10-18  0:00       ` Lars Farm
1996-10-20  0:00         ` Robert A Duff
1996-10-18  0:00       ` Hans-Juergen Boehm
1996-10-18  0:00       ` Lars Farm
1996-10-19  0:00         ` Robert Dewar
1996-10-20  0:00           ` Lars Farm
1996-10-21  0:00             ` Nicolay Belofastow
1996-10-21  0:00               ` Robert Dewar
1996-10-21  0:00             ` Robert Dewar
1996-10-22  0:00               ` Lars Farm
1996-10-20  0:00         ` Robert A Duff
1996-10-20  0:00           ` Robert Dewar
1996-10-22  0:00         ` Mitch Gart
1996-10-23  0:00           ` Fergus Henderson
1996-10-23  0:00           ` Hans-Juergen Boehm
1996-10-27  0:00             ` Richard Riehle
1996-10-29  0:00         ` Jon S Anthony
1996-10-30  0:00         ` Brian Rogoff
1996-10-30  0:00         ` Jonas Nygren
1996-10-30  0:00         ` Jon S Anthony
1996-10-30  0:00         ` James Rogers
1996-10-15  0:00 ` Hannes Haug
1996-10-16  0:00 ` Jon S Anthony
1996-10-17  0:00   ` Robert Dewar
1996-10-16  0:00 ` Jon S Anthony
1996-10-16  0:00 ` Ole-Hjalmar Kristensen FOU.TD/DELAB
1996-10-16  0:00   ` Robert Dewar
1996-10-16  0:00 ` Jon S Anthony
1996-10-16  0:00 ` Jon S Anthony
1996-10-17  0:00 ` Robert I. Eachus
1996-10-17  0:00   ` Robert Dewar
1996-10-17  0:00     ` Richard Kenner
1996-10-17  0:00 ` Rick Hudson
1996-10-17  0:00 ` Hans-Juergen Boehm
1996-10-18  0:00 ` Jon S Anthony
1996-10-23  0:00   ` Robert Dewar
1996-10-18  0:00 ` Rick Hudson
1996-10-18  0:00 ` Jon S Anthony
1996-10-18  0:00   ` Robert Dewar
1996-10-21  0:00 ` Laurent Pautet
1996-10-21  0:00 ` Jon S Anthony
1996-10-22  0:00 ` Jon S Anthony
1996-10-22  0:00 ` Tapani Rundgren
1996-10-23  0:00 ` Jon S Anthony
1996-10-24  0:00   ` Mitch Gart
1996-10-24  0:00 ` Robert I. Eachus
1996-10-24  0:00 ` Hans-Juergen Boehm
1996-10-25  0:00 ` Jon S Anthony
1996-10-28  0:00 ` Robert I. Eachus
1996-10-29  0:00 ` Hans-Juergen Boehm
  -- strict thread matches above, loose matches on Subject: below --
1996-11-02  0:00 Jon S Anthony
     [not found] <01bbc6a3$4cf03480$829d6482@joy.ericsson.se>
1996-10-31  0:00 ` Mitch Gart
1996-10-31  0:00   ` Jonas Nygren
1996-11-03  0:00   ` Matthew Heaney
1996-11-06  0:00     ` Robert A Duff
1996-11-06  0:00       ` Norman H. Cohen
1996-11-01  0:00 ` Jon S Anthony
1996-11-06  0:00 ` Brian Rogoff
1996-11-07  0:00   ` Tucker Taft
1996-10-22  0:00 Brian Rogoff
1996-10-11  0:00 C++ Standardization (was: Once again, Ada absent from DoD SBIR solicitation) Dave Wood
1996-10-17  0:00 ` Garbage Collection in Ada Thomas Kendelbacher
replies disabled

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