Re: Fix double_int overflow in VRP PLUS_EXPR

2012-08-22 Thread Marc Glisse
On Wed, 22 Aug 2012, Jakub Jelinek wrote: On Wed, Aug 22, 2012 at 02:34:01PM +0200, Marc Glisse wrote: Ok, I committed the __CHAR_BIT__ version (I just compiled that one file manually with old and new compilers, I didn't restart the testsuite, I hope the manual test is enough to detect any typo

Re: Fix double_int overflow in VRP PLUS_EXPR

2012-08-22 Thread Jakub Jelinek
On Wed, Aug 22, 2012 at 02:34:01PM +0200, Marc Glisse wrote: > On Wed, 22 Aug 2012, Jakub Jelinek wrote: > > >>>2012-08-21 Marc Glisse > >>>+ n <<= (8 * sizeof (NT) - 1); > > > >Better use __CHAR_BIT__ instead of 8 here... > > Ok, I committed the __CHAR_BIT__ version (I just compiled that one

Re: Fix double_int overflow in VRP PLUS_EXPR

2012-08-22 Thread Marc Glisse
On Wed, 22 Aug 2012, Jakub Jelinek wrote: 2012-08-21 Marc Glisse + n <<= (8 * sizeof (NT) - 1); Better use __CHAR_BIT__ instead of 8 here... Ok, I committed the __CHAR_BIT__ version (I just compiled that one file manually with old and new compilers, I didn't restart the testsuite, I ho

Re: Fix double_int overflow in VRP PLUS_EXPR

2012-08-22 Thread Jakub Jelinek
On Wed, Aug 22, 2012 at 02:19:19PM +0200, Richard Guenther wrote: > > 2012-08-21 Marc Glisse > > > > PR tree-optimization/54317 > > > > gcc/ > > * tree-vrp.c (extract_range_from_binary_expr_1): Test for > > double_int overflow. > > Remove dead tests. > > > > gcc/t

Re: Fix double_int overflow in VRP PLUS_EXPR

2012-08-22 Thread Richard Guenther
On Wed, Aug 22, 2012 at 1:55 PM, Marc Glisse wrote: > Hello, > > when I adapted VRP PLUS_EXPR handling for __int128, I missed one place where > double_int can overflow. Note that I have no idea if that helps for bug > 54317, but that's where I noticed the issue. Ok. Thanks, Richard. > 2012-08-2