[Bug c/80631] [6/7/8 Regression] Compiling with -O3 -mavx2 gives wrong code
jakub at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu May 4 20:09:00 GMT 2017
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80631
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2017-05-04
CC| |alan.hayward at arm dot com,
| |jakub at gcc dot gnu.org
Target Milestone|--- |6.4
Summary|Compiling with -O3 -mavx2 |[6/7/8 Regression]
|gives wrong code |Compiling with -O3 -mavx2
| |gives wrong code
Ever confirmed|0 |1
--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Started with r230297.
Note, in C
const int N = 8;
int v[N];
is a variable length array, so unnecessarily pessimizing, you need to use
#define N 8
or
enum { N = 8 };
or something similar instead for it to be a non-VLA. In C++ it is not a VLA.
But fixing that doesn't help here.
More information about the Gcc-bugs
mailing list