[Bug tree-optimization/64277] [4.9/5.0 Regression] Incorrect warning array subscript is above array bounds

2015-01-15 Thread izamyatin at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64277

--- Comment #5 from Igor Zamyatin izamyatin at gmail dot com ---
BTW, making nc and m to be int instead short eliminates the warning


[Bug tree-optimization/64277] [4.9/5.0 Regression] Incorrect warning array subscript is above array bounds

2015-01-12 Thread izamyatin at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64277

--- Comment #4 from Igor Zamyatin izamyatin at gmail dot com ---
See the warning ( used -O3 -mssse3 -Wall) on current trunk configured as

../configure --enable-clocale=gnu --with-system-zlib --enable-shared
--with-demangler-in-ld --with-fpmath=sse --enable-checking=release
--enable-languages=c,c++,fortran


[Bug tree-optimization/64277] [4.9/5.0 Regression] Incorrect warning array subscript is above array bounds

2014-12-23 Thread izamyatin at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64277

Igor Zamyatin izamyatin at gmail dot com changed:

   What|Removed |Added

 CC||izamyatin at gmail dot com

--- Comment #1 from Igor Zamyatin izamyatin at gmail dot com ---
Warnings are issued by vrp2.

It happens when we have both vector and scalar versions of code. Something
seems to confuse VRP analysis, probably the reason is that m and nc are shorts.
Changing them to int makes warnings disappear


[Bug tree-optimization/64277] [4.9/5.0 Regression] Incorrect warning array subscript is above array bounds

2014-12-23 Thread manu at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64277

Manuel López-Ibáñez manu at gcc dot gnu.org changed:

   What|Removed |Added

 CC||manu at gcc dot gnu.org

--- Comment #2 from Manuel López-Ibáñez manu at gcc dot gnu.org ---
I cannot reproduce this in GCC 5.0 with or without -msse3 (on
x86_64-linux-gnu). I always get:

test.c: In function ‘foo’:
test.c:12:14: warning: ‘f1’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
f1[i] = f1[i] + 1;
  ^

which seems correct.

In any case, warning about f1[i] being above array bounds would be correct:
there is no check that i  10.

[Bug tree-optimization/64277] [4.9/5.0 Regression] Incorrect warning array subscript is above array bounds

2014-12-23 Thread aivchenk at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64277

--- Comment #3 from Alexander Ivchenko aivchenk at gmail dot com ---
You need to specify -mssse3 (not -msse3). Warning about array bounds is not
correct, because gcc does not know how this function is being called.


[Bug tree-optimization/64277] [4.9/5.0 Regression] Incorrect warning array subscript is above array bounds

2014-12-12 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64277

Richard Biener rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|--- |4.9.3