On Sat, Oct 26, 2019 at 12:21:15PM +0100, Iain Sandoe wrote:
> Georg-Johann Lay <g...@gcc.gnu.org> wrote:
> > Wilco Dijkstra schrieb:
> >> GCC currently defaults to -fcommon.  As discussed in the PR, this is an 
> >> ancient
> >> C feature which is not conforming with the latest C standards.  On many 
> >> targets
> >> this means global variable accesses have a codesize and performance 
> >> penalty.
> >> This applies to C code only, C++ code is not affected by -fcommon.  It is 
> >> about
> >> time to change the default.
> >> OK for commit?
> > 
> > IIRC using -fno-common might lead to some testsuit fallout because
> > some optimizations / test cases are sensitive to -f[no-]common.
> > So I wonder that no adjustments to test cases are needed?
> 
> Two points here:
> 
> (a) I actually agree with the idea to change the default

I think everyone does, this has been long overdue.

> (b) there will surely be testsuite fallout on Darwin, where common accesses 
> are
>      mandated to be indirect in the ABI, where non-weak .data accesses are not
>     Thus code generated for Darwin will change for any test using variables 
> that
>     are “common” and where the test does not already force -fno-common
> 
>     I’d expect fallout to be quite large - since there are plenty of 
> testcases with uninit
>    gobals.  We might want to make a test-run and see the size of the problem, 
> but
>    preferably once the stage#1 submisison and gcc-7 release cycles are done.

Yeah -- and if fallout is more than just testsuite, should it be postponed
to GCC 11?  And announced now, etc.

But to find out we probably should flip the switch soon, see what happens,
only flip it back if necessary.


Segher

Reply via email to