https://gcc.gnu.org/bugzilla/show_bug.cgi?id=127761
Drea Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
See Also| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=92714,
| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=59863,
| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=70189,
| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=105343
Keywords| |compile-time-hog,
| |missed-optimization
Severity|normal |enhancement
--- Comment #1 from Drea Pinski <pinskia at gcc dot gnu.org> ---
Confirmed.
The front-end produces (for [0 ... 55] = ):
const int x[10000] = {2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2};
Note maybe RANGE_EXPR should be used here instead which would help.
But then the gimplifier decides to expand out that constructor.