bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: changing "configure" to default to "gcc -g -O2 -fwrapv ..."


From: Paul Eggert
Subject: Re: changing "configure" to default to "gcc -g -O2 -fwrapv ..."
Date: Mon, 01 Jan 2007 16:02:04 -0800
User-agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.4 (gnu/linux)

address@hidden (Richard Kenner) writes:

>> More important, we don't yet have an easy way to characterize the
>> cases where (2) would apply.  For (2), we need a simple, documented
>> rule that programmers can easily understand, so that they can easily
>> verify that C code is safe
>
> I'm not sure what you mean: there's the C standard.

(2) was Ian Lance Taylor's proposal to add an option which acts like
-fwrapv except not so all-encompassingly.  That is, as I understood
it, -fstrict-signed-overflow would act like -fwrapv except it would
guarantee wrapv semantics only in some cases, not in all cases.  This
is intended to be a compromise between -O2 and -O2 -fwrapv, a
compromise that gets almost all the performance of former and almost
all the safety of the latter.  (Or maybe I got it backwards and that
is what -fno-strict-signed-overflow would mean, but the spelling of
the option isn't the crucial point here, the semantics are.)

So the question is, what the "some cases" would be.  That is, how
would we write the documentation for -fstrict-signed-overflow?  This
is not a question that the C standard can answer.  Nor do I think it
an easy question to answer -- at least, we don't have an answer now.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]