mirror of git://gcc.gnu.org/git/gcc.git
cgraphunit.c (verify_cgraph_node): Verify there is no direct call to a thunk.
2011-01-03 Martin Jambor <mjambor@suse.cz> * cgraphunit.c (verify_cgraph_node): Verify there is no direct call to a thunk. From-SVN: r168422
This commit is contained in:
parent
ce47fda3ce
commit
76df0ae6df
|
|
@ -1,3 +1,8 @@
|
|||
2011-01-03 Martin Jambor <mjambor@suse.cz>
|
||||
|
||||
* cgraphunit.c (verify_cgraph_node): Verify there is no direct call to
|
||||
a thunk.
|
||||
|
||||
2011-01-03 Martin Jambor <mjambor@suse.cz>
|
||||
|
||||
PR tree-optimization/46984
|
||||
|
|
|
|||
|
|
@ -647,6 +647,8 @@ verify_cgraph_node (struct cgraph_node *node)
|
|||
}
|
||||
if (!e->indirect_unknown_callee)
|
||||
{
|
||||
struct cgraph_node *n;
|
||||
|
||||
if (e->callee->same_body_alias)
|
||||
{
|
||||
error ("edge points to same body alias:");
|
||||
|
|
@ -667,6 +669,15 @@ verify_cgraph_node (struct cgraph_node *node)
|
|||
debug_tree (decl);
|
||||
error_found = true;
|
||||
}
|
||||
else if (decl
|
||||
&& (n = cgraph_get_node_or_alias (decl))
|
||||
&& (n->same_body_alias
|
||||
&& n->thunk.thunk_p))
|
||||
{
|
||||
error ("a call to thunk improperly represented "
|
||||
"in the call graph:");
|
||||
debug_gimple_stmt (stmt);
|
||||
}
|
||||
}
|
||||
else if (decl)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue