Hi,

> +  sa_cost = (TREE_CODE (expr) != MINUS_EXPR
> +             ? shiftadd_cost[speed][mode][m]
> +             : (mult == op1
> +                ? shiftsub1_cost[speed][mode][m]
> +                : shiftsub0_cost[speed][mode][m]));
> +  res = new_cost (sa_cost, 0);
> +  res = add_costs (res, mult == op1 ? cost0 : cost1);

just forgetting the cost of the other operand does not seem correct -- what
if it contains some more complicated subexpression?

Zdenek

Reply via email to