[Bug c++/13768] [3.4/3.5 Regression] -funit-at-a-time compiles unused inline function
mark at codesourcery dot com
gcc-bugzilla@gcc.gnu.org
Tue Feb 3 15:46:00 GMT 2004
------- Additional Comments From mark at codesourcery dot com 2004-02-03 15:46 -------
Subject: Re: [3.4/3.5 Regression] -funit-at-a-time compiles
unused inline function
hubicka at ucw dot cz wrote:
>------- Additional Comments From hubicka at ucw dot cz 2004-02-03 11:00 -------
>Subject: Re: [3.4/3.5 Regression] -funit-at-a-time compiles unused inline function
>
>
>
>>------- Additional Comments From mmitchel at gcc dot gnu dot org 2004-02-03 09:25 -------
>>The code is indeed invalid.
>>
>>When a complete object of type X<int> is created, the compiler is allowed to
>>emit the vtable for X, and that permits instantiating the virtual functions.
>>
>>However, this is an optimization deficiency in -funit-at-a-time.
>>
>>
>
>Yes, the problem is that all dependencies are resolved before
>optimization is done. I am planning to address this by doing early pass
>of tree-ssa optimization before inlining and cgraph construction. That
>way we should catch majority of cases.
>I also plan to deffer output of datastrctures to the very end of
>compilation and use information about what was really used by backend.
>
>Honza
>
What do you suggest, if anything, for GCC 3.4?
(This is potentially a regression with respect to the size of the
generated code. There is lots of code with trivial constructors that,
after inlining, will be eliminated.)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13768
More information about the Gcc-bugs
mailing list