RFA: cgraph PATCH for c++/51812 (link failure with undefined/unneeded virtual function)
Jason Merrill
jason@redhat.com
Mon Jan 23 18:03:00 GMT 2012
In this testcase, main doesn't call anything, so the inline functions in
the classes can be optimized away, and we don't need the vtables or the
virtual functions they refer to. But cgraph_decide_is_function_needed
wants to write out all static functions at -O0, which in this case was
including the local thunk alias created by use_thunk. Clearly we don't
want to force such an alias out when it isn't needed, so I've added
same-body aliases to the list of things that we don't need to emit.
OK for trunk?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 51812.patch
Type: text/x-patch
Size: 1121 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20120123/da7bfe12/attachment.bin>
More information about the Gcc-patches
mailing list