Commit d8b649b9 authored by Christoph Mallon's avatar Christoph Mallon
Browse files

Remove redundant mode equality test before calling tarval_convert_to().

parent 7c7abb4c
......@@ -4878,9 +4878,7 @@ static ir_node *transform_node_shl_shr(ir_node *n)
return n;
}
if (get_tarval_mode(tv_shl) != get_tarval_mode(tv_shr)) {
tv_shl = tarval_convert_to(tv_shl, get_tarval_mode(tv_shr));
}
tv_shl = tarval_convert_to(tv_shl, get_tarval_mode(tv_shr));
assert(tv_mask != tarval_bad);
assert(get_tarval_mode(tv_mask) == mode);
......@@ -6075,8 +6073,7 @@ handle_tv:;
if (offset == 0
&& get_mode_arithmetic(tv_mode) == get_mode_arithmetic(mode)
&& get_mode_size_bits(tv_mode) == get_mode_size_bits(mode)) {
if (tv_mode != mode)
tv = tarval_convert_to(tv, mode);
tv = tarval_convert_to(tv, mode);
return new_r_Const(irg, tv);
}
/* TODO: more advanced variants */
......
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