Commit 5265f892 authored by Christoph Mallon's avatar Christoph Mallon
Browse files

arm: Avoid redundant sign/zero extension right after a load.

parent f9649062
......@@ -38,6 +38,7 @@ libFirm 1.22.1 (2016-01-07)
* arm: Support computed goto
* opt: Simplify computed goto with known destination to unconditional branch
* opt: Handle constant folding for the builtins `clz`, `ctz`, `ffs`, `parity` and `popcount`
* arm: Avoid redundant sign/zero extension right after a load
* Bugfixes
libFirm 1.22.0 (2015-12-31)
......
......@@ -217,9 +217,13 @@ static ir_node *gen_extension(dbg_info *dbgi, ir_node *block, ir_node *op,
*/
static bool upper_bits_clean(ir_node *transformed_node, ir_mode *mode)
{
(void)transformed_node;
(void)mode;
/* TODO */
if (is_Proj(transformed_node) && get_Proj_num(transformed_node) == pn_arm_Ldr_res) {
ir_node *const ldr = get_Proj_pred(transformed_node);
if (is_arm_Ldr(ldr)) {
arm_load_store_attr_t const *const attr = get_arm_load_store_attr_const(ldr);
return get_mode_size_bits(attr->load_store_mode) <= get_mode_size_bits(mode);
}
}
return false;
}
......
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