Re: [PATCH] analyzer: fix handling of negative byte offsets (PR 93281)

2020-01-16 Thread Jakub Jelinek
On Wed, Jan 15, 2020 at 06:56:48PM -0500, David Malcolm wrote: > gcc/analyzer/ChangeLog: > PR analyzer/93281 > * region-model.cc > (region_model::convert_byte_offset_to_array_index): Convert > offset_cst to ssizetype before dividing by byte_size. > --- > gcc/analyzer/region

Re: [PATCH] analyzer: fix handling of negative byte offsets (PR 93281)

2020-01-15 Thread Richard Biener
On January 16, 2020 12:56:48 AM GMT+01:00, David Malcolm wrote: >Various 32-bit targets show failures in gcc.dg/analyzer/data-model-1.c >with tests of the form: > __analyzer_eval (q[-2].x == 107024); /* { dg-warning "TRUE" } */ > __analyzer_eval (q[-2].y == 107025); /* { dg-warning "TRUE" } */

[PATCH] analyzer: fix handling of negative byte offsets (PR 93281)

2020-01-15 Thread David Malcolm
Various 32-bit targets show failures in gcc.dg/analyzer/data-model-1.c with tests of the form: __analyzer_eval (q[-2].x == 107024); /* { dg-warning "TRUE" } */ __analyzer_eval (q[-2].y == 107025); /* { dg-warning "TRUE" } */ where they emit UNKNOWN instead. The root cause is that gimple has a