Commit 0a0b836f authored by Andreas Zwinkau's avatar Andreas Zwinkau
Browse files

fix opt/gcse_no_end

jump threading must also copy Keep edges to keep End reachable.
parent 8ea5207a
......@@ -275,6 +275,13 @@ static void copy_and_fix(const jumpthreading_env_t *env, ir_node *block,
ir_node *copy;
ir_mode *mode;
if (is_End(node)) {
/* edge is a Keep edge. If the end block is unreachable via normal control flow,
* we must maintain end's reachability with Keeps.
/* ignore control flow */
mode = get_irn_mode(node);
if (mode == mode_X || is_Cond(node))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment