Re: [PATCH] Fix high handling in wi::mul_internal (PR tree-optimization/61682)

2014-07-03 Thread Mike Stump
On Jul 3, 2014, at 2:53 PM, Richard Sandiford wrote: > Jakub Jelinek writes: >> >> + if (sgn == SIGNED && wi::neg_p (op1)) > > I think the preferred way of writing this is "wi::neg_p (op1, svn)" Yes.

Re: [PATCH] Fix high handling in wi::mul_internal (PR tree-optimization/61682)

2014-07-03 Thread Richard Sandiford
Jakub Jelinek writes: > @@ -1302,12 +1310,28 @@ wi::mul_internal (HOST_WIDE_INT *val, co >/* Handle multiplications by 1. */ >if (op1 == 1) > { > + if (high) > + { > + if (sgn == SIGNED && wi::neg_p (op2)) > + val[0] = -1; > + else > + val[0] = 0;