This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
struct cgraph_edge *edge = cgraph_edge (id->src_node, orig_stmt);POINT_A
int flags;POINT_B
switch (id->transform_call_graph_edges) { case CB_CGE_DUPLICATE: if (edge) cgraph_clone_edge (edge, id->dst_node, stmt, REG_BR_PROB_BASE, 1, edge->frequency, true); break;
case CB_CGE_MOVE_CLONES: cgraph_set_call_stmt_including_clones (id->dst_node, orig_stmt, stmt); break;
case CB_CGE_MOVE: if (edge) cgraph_set_call_stmt (edge, stmt);
break;POINT_C
default: gcc_unreachable (); }
edge = cgraph_edge (id->src_node, orig_stmt);
/* Constant propagation on argument done during inlining
may create new direct call. Produce an edge for it. */
if ((!edge
|| (edge->indirect_call
&& id->transform_call_graph_edges == CB_CGE_MOVE_CLONES))
&& is_gimple_call (stmt)
&& (fn = gimple_call_fndecl (stmt)) != NULL)
POINT_DWe begin by looking up the edge at POINT_A. We then move the edge at POINT_B. We then look up the edge *again* at POINT_C. Ought we be surprised when we do not find the edge at POINT_D?
case CB_CGE_MOVE:
edge = cgraph_edge (id->dst_node, orig_stmt);
cgraph_set_call_stmt (edge, stmt);
// Possibly fix up indirect->direct call here.| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |