[Bug tree-optimization/62071] [4.10 Regression] ICE: in before_dom_children, at tree-ssa-pre.c:4411

hubicka at ucw dot cz gcc-bugzilla@gcc.gnu.org
Sun Aug 17 15:57:00 GMT 2014


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62071

--- Comment #9 from Jan Hubicka <hubicka at ucw dot cz> ---
> >>>The constructor is keyed to other compilation unit here, but we are provided with a body
> >>>that we will never use (modulo the tree-ssa-pre bug that brings the reference into code).
> >>
> >>Hmm, we might consider overriding DECL_EXTERNAL so that there's a
> >>definition available for devirtualization.
> >
> >I can always implement logic to use it only when it is inlined, but that will probably drag
> >in references to other symbols belonging to the class...
> 
> I'm not too concerned about that; users should expect an inline
> function to be inlined.

Thiking about this - can't we make these just DECL_COMDAT?  If it is safe to
inline them, it is also safe to introduce COMDAT copy of the body if we
introduce the reference to it. Becaue the method is keyed, it will be overriden
by non-weak in the case user links with the implementation. If he doesn't then
the weak copy is no worse (reference wise) than inline copy...

Honza



More information about the Gcc-bugs mailing list