aboutsummaryrefslogtreecommitdiff
path: root/gcc/ddg.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/ddg.c')
-rw-r--r--gcc/ddg.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/ddg.c b/gcc/ddg.c
index 4543ba7..b8ae375 100644
--- a/gcc/ddg.c
+++ b/gcc/ddg.c
@@ -197,6 +197,11 @@ create_ddg_dep_from_intra_loop_link (ddg_ptr g, ddg_node_ptr src_node,
}
}
+ /* If a true dep edge enters the branch create an anti edge in the
+ opposite direction to prevent the creation of reg-moves. */
+ if ((DEP_TYPE (link) == REG_DEP_TRUE) && JUMP_P (dest_node->insn))
+ create_ddg_dep_no_link (g, dest_node, src_node, ANTI_DEP, REG_DEP, 1);
+
latency = dep_cost (link);
e = create_ddg_edge (src_node, dest_node, t, dt, latency, distance);
add_edge_to_ddg (g, e);