Storage for uninitialized objects (PR 24626)

Robert Dewar dewar@adacore.com
Sun Jan 15 10:56:00 GMT 2006


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.




More information about the Gcc mailing list