Commit 03cb2519 authored by Christoph Mallon's avatar Christoph Mallon
Browse files

Manual CSE.

[r16078]
parent 9322d068
......@@ -67,22 +67,24 @@ void ia32_handle_intrinsics(void) {
*/
static void resolve_call(ir_node *call, ir_node *l_res, ir_node *h_res, ir_graph *irg, ir_node *block) {
ir_node *res, *in[2];
ir_node *bad = get_irg_bad(irg);
ir_node *nomem = get_irg_no_mem(irg);
in[0] = l_res;
in[1] = h_res;
res = new_r_Tuple(irg, block, h_res == NULL ? 1 : 2, in);
turn_into_tuple(call, pn_Call_max);
set_Tuple_pred(call, pn_Call_M_regular, get_irg_no_mem(irg));
set_Tuple_pred(call, pn_Call_M_regular, nomem);
/* Matze: the new_r_Jmp here sometimes CSEs and then bad things happen
* (in movgen.c from 186.crafty for example) I don't know why it is here
* and if this fix is correct... */
/*set_Tuple_pred(call, pn_Call_X_regular, new_r_Jmp(irg, block));*/
set_Tuple_pred(call, pn_Call_X_regular, get_irg_bad(irg));
set_Tuple_pred(call, pn_Call_X_except, get_irg_bad(irg));
set_Tuple_pred(call, pn_Call_X_regular, bad);
set_Tuple_pred(call, pn_Call_X_except, bad);
set_Tuple_pred(call, pn_Call_T_result, res);
set_Tuple_pred(call, pn_Call_M_except, get_irg_no_mem(irg));
set_Tuple_pred(call, pn_Call_P_value_res_base, get_irg_bad(irg));
set_Tuple_pred(call, pn_Call_M_except, nomem);
set_Tuple_pred(call, pn_Call_P_value_res_base, bad);
}
/**
......
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