https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80520
--- Comment #5 from krister.walfridsson at gmail dot com --- I have extracted a smaller test case. The loops are generated from typedef mersenne_twister_engine< uint_fast32_t, 32, 624, 397, 31, 0x9908b0dfUL, 11, 0xffffffffUL, 7, 0x9d2c5680UL, 15, 0xefc60000UL, 18, 1812433253UL> mt19937; and the expansion of the template end up with loops like void foo(unsigned long *M) { for (unsigned long k = 0; k < 227; ++k) { unsigned long y = ((M[k] & 0xffffffff80000000) | (M[k + 1] & 0x7fffffff)); M[k] = (M[k + 397] ^ (y >> 1) ^ ((y & 1) ? 2567483615 : 0)); } } which generates the dump described in the bug report. --- Comment #6 from krister.walfridsson at gmail dot com --- I have extracted a smaller test case. The loops are generated from typedef mersenne_twister_engine< uint_fast32_t, 32, 624, 397, 31, 0x9908b0dfUL, 11, 0xffffffffUL, 7, 0x9d2c5680UL, 15, 0xefc60000UL, 18, 1812433253UL> mt19937; and the expansion of the template end up with loops like void foo(unsigned long *M) { for (unsigned long k = 0; k < 227; ++k) { unsigned long y = ((M[k] & 0xffffffff80000000) | (M[k + 1] & 0x7fffffff)); M[k] = (M[k + 397] ^ (y >> 1) ^ ((y & 1) ? 2567483615 : 0)); } } which generates the dump described in the bug report.