comp.lang.ada
 help / color / mirror / Atom feed
From: Mats Weber <matsw@mail.com>
Subject: Re: Y21C Bug
Date: 2000/01/13
Date: 2000-01-13T16:19:42+00:00	[thread overview]
Message-ID: <387DFB1E.CBBF14C7@mail.com> (raw)
In-Reply-To: 85irp9$11m$1@front3.grolier.fr

Thierry Lelegard wrote:

> Yes it does. If you had left the variable uninitialized (on an Ada
> perspective), then the variable would have been allocated in
> a "demand zero" section (no allocation in executable). Since
> you provided an explicit initial value, the compiler/linker placed
> it into a "copy on reference" section which contains the initial
> values. Of course, the compiler could make a special optimization
> which consists in inspecting every single byte of this initial
> value and if they are all zeroes then place the variable into
> a "demand zero" section. But, it appears that this optimization
> is not made.

You generally cannot guarantee that the variable is allocated in a
demand-zero region. For instance, when allocated on the stack, the stack
may have previously grown higher than where you allocate and you get the
content left there from a previous call (unless the stack is zeroed or
unmapped from the address space when it shrinks, but I doubt any system
is doing that).




  reply	other threads:[~2000-01-13  0:00 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-01-02  0:00 Y21C Bug reason67
2000-01-02  0:00 ` Robert Dewar
2000-01-03  0:00   ` Tarjei T. Jensen
2000-01-03  0:00     ` Jeff Creem
2000-01-03  0:00       ` Tarjei T. Jensen
2000-01-03  0:00     ` Robert A Duff
2000-01-04  0:00       ` Tarjei T. Jensen
2000-01-04  0:00         ` Samuel Tardieu
2000-01-04  0:00         ` Robert A Duff
2000-01-04  0:00         ` Robert Dewar
2000-01-05  0:00           ` Tarjei T. Jensen
2000-01-05  0:00             ` Robert Dewar
2000-01-06  0:00               ` Richard D Riehle
2000-01-06  0:00               ` Tarjei T. Jensen
2000-01-06  0:00                 ` Larry Kilgallen
2000-01-06  0:00               ` Georg Bauhaus
2000-01-06  0:00                 ` Tarjei T. Jensen
2000-01-05  0:00             ` Al Christians
2000-01-06  0:00               ` Tarjei T. Jensen
2000-01-06  0:00                 ` Robert Dewar
2000-01-06  0:00                   ` Robert A Duff
2000-01-06  0:00                     ` Larry Kilgallen
2000-01-07  0:00                     ` Florian Weimer
2000-01-07  0:00                       ` Robert A Duff
2000-01-07  0:00                         ` Robert Dewar
2000-02-04  0:00                           ` Florian Weimer
2000-02-04  0:00                             ` Robert A Duff
2000-02-04  0:00                               ` Florian Weimer
2000-01-11  0:00                         ` Mats Weber
2000-01-11  0:00                           ` Robert A Duff
2000-01-12  0:00                             ` Mats Weber
2000-01-12  0:00                               ` Thierry Lelegard
2000-01-13  0:00                                 ` Mats Weber [this message]
2000-01-13  0:00                                 ` Robert A Duff
2000-01-13  0:00                                   ` Larry Kilgallen
2000-01-13  0:00                                   ` Thierry Lelegard
     [not found]                               ` <387dfb1e.cbbf14c7@mail.com>
2000-01-13  0:00                                 ` Larry Kilgallen
2000-01-11  0:00                     ` Mats Weber
2000-01-07  0:00                   ` Tarjei T. Jensen
2000-01-07  0:00                     ` Robert Dewar
2000-01-06  0:00               ` Robert Dewar
2000-01-04  0:00       ` Robert Dewar
2000-01-04  0:00         ` Charles Hixson
2000-01-04  0:00           ` Keith Thompson
2000-01-05  0:00           ` Robert Dewar
2000-01-05  0:00           ` Robert Dewar
2000-01-05  0:00             ` Y21C Bug :-) Charles Hixson
2000-01-06  0:00               ` Ted Dennison
2000-01-07  0:00                 ` Keith Thompson
2000-01-07  0:00                   ` Robert A Duff
replies disabled

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