Re: [committed] Fix up pr90478.c testcase (was Re: [PATCH] Check for overflow in tree-switch-conversion (PR middle-end/90478).)

2019-05-16 Thread Martin Liška
On 5/16/19 12:45 AM, Jakub Jelinek wrote: > Fixed thusly, tested on x86_64-linux with -m32/-m64, committed to trunk as > obvious: Thank you Jakub.

[committed] Fix up pr90478.c testcase (was Re: [PATCH] Check for overflow in tree-switch-conversion (PR middle-end/90478).)

2019-05-15 Thread Jakub Jelinek
On Wed, May 15, 2019 at 12:20:42PM +0200, Martin Liška wrote: > 2019-05-15 Martin Liska > > PR middle-end/90478 > * tree-switch-conversion.c (jump_table_cluster::can_be_handled): > Check for overflow. > > gcc/testsuite/ChangeLog: > > 2019-05-15 Martin Liska > > PR

Re: [PATCH] Check for overflow in tree-switch-conversion (PR middle-end/90478).

2019-05-15 Thread Richard Biener
On Wed, May 15, 2019 at 1:30 PM Martin Liška wrote: > > On 5/15/19 1:21 PM, Richard Biener wrote: > > On Wed, May 15, 2019 at 12:21 PM Martin Liška wrote: > >> > >> Hi. > >> > >> The patch is about handling of overflow in > >> jump_table_cluster::can_be_handled. > >> I calculate 100 * range and

Re: [PATCH] Check for overflow in tree-switch-conversion (PR middle-end/90478).

2019-05-15 Thread Martin Liška
On 5/15/19 1:21 PM, Richard Biener wrote: > On Wed, May 15, 2019 at 12:21 PM Martin Liška wrote: >> >> Hi. >> >> The patch is about handling of overflow in >> jump_table_cluster::can_be_handled. >> I calculate 100 * range and compare it to range. If it's smaller, then >> overflow happens. >> >> P

Re: [PATCH] Check for overflow in tree-switch-conversion (PR middle-end/90478).

2019-05-15 Thread Richard Biener
On Wed, May 15, 2019 at 12:21 PM Martin Liška wrote: > > Hi. > > The patch is about handling of overflow in jump_table_cluster::can_be_handled. > I calculate 100 * range and compare it to range. If it's smaller, then > overflow happens. > > Patch can bootstrap on x86_64-linux-gnu and survives regr