|
From: | Robert Dewar |
Subject: | Re: changing "configure" to default to "gcc -g -O2 -fwrapv ..." |
Date: | Sun, 31 Dec 2006 14:10:59 -0500 |
User-agent: | Thunderbird 1.5.0.9 (Windows/20061207) |
Paul Eggert wrote:
The question is not whether GCC should support wrapv semantics; it already does, if you specify -fwrapv. The question is merely whether wrapv should be the default with optimization levels -O0 through -O2.
That over simplifies, because it presents things as though there are only two possibilities 1. Allow "undefined" optimizations without restriction 2. Forbid all such optimizations by specifying fwrapv Quite a few of us (including certainly me, and I think Richard) argue for a mid ground where We don't insist on full fwrapv semantics (because we think it will hurt code equality, particularly in the loop invariant case). We are judcious in applying the optimization in other cases in a pragmatic attempt to keep "traditional" C code working in practice.
[Prev in Thread] | Current Thread | [Next in Thread] |