Dne 2019-03-06 13:22, Martin Jambor napsal:
Hi,

PR 88235 is a cgraph verification failure which is a false positive.
The problem is that after thunk expansion which is done as a part of
thunk inlining the verifier is no longer able to detect that a call
graph edge callee points to a clone of the destination of the now
expanded thunk in the decl of the corresponding gimple statement.

Fixed in a way agreed on with Honza in bugzilla, we simply add a way to
detect former (expanded) thunks, I understand this is already done
by devirtualization in a similar way too, and use that information in
the verifier.

Passed bootstrap and testing on x86_64-linux, OK for trunk?  OK for
gcc-7-branch and gcc-8-branch too if a backport is straightforward (I
have not tried yet) and it passes testing there too?

Thanks,

Martin


2019-03-05  Martin Jambor  <mjam...@suse.cz>

        PR ipa/88235
        * cgraph.h (cgraph_node): New inline method former_thunk_p.
        * cgraph.c (cgraph_node::dump): Dump a note if node is a former thunk.
        (clone_of_p): Treat expanded thunks like thunks, be optimistic if they
        have multiple callees.  At the end check if declarations match as
        opposed to cgraph_nodes.

        testsuite/
        * g++.dg/ipa/pr88235.C: New test.

OK,
thanks!
Honza

Reply via email to