This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Storage for uninitialized objects (PR 24626)
- From: Robert Dewar <dewar at adacore dot com>
- To: Paul Schlie <schlie at comcast dot net>
- Cc: Ian Lance Taylor <ian at airs dot com>, John David Anglin <dave at hiauly1 dot hia dot nrc dot ca>, gcc at gcc dot gnu dot org
- Date: Sun, 15 Jan 2006 05:56:40 -0500
- Subject: Re: Storage for uninitialized objects (PR 24626)
- References: <BFEF92C6.CAC8%schlie@comcast.net>
Paul Schlie wrote:
(or might it actually make substantially more sense for a compiler to
do what the code logically specified in absents of any more reliably
predictable alternative; under the premise that consistency is good.)
Paul, the semantics of C programs is given by the C standard, not by some
highly undefined notion of "what Paul thinks is logical behavior". We
already
know that the latter has some very peculiar cases, such as expecting
Sin (X) to compute something sensible when X is undefined, which
implies that the compiler has to ensure the absence of signalling
NaN's, which is infeasible, not required by the standard, and not
wanted by most programmers, who are not interested in having
significant efficiency hits affecting correct programs in the
interests of more consistent behavior from incorrect programs.