https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68756
--- Comment #3 from Arseny Solokha <asolokha at gmx dot com> --- The following observations were made w/ gcc-6.0.0-alpha20151220 snapshot. isl fails w/ > isl-0.15/isl_ctx.c:227: Assertion "ctx->ref > 0" failed when compiling the following snippet w/ the same options as above: int s9; int id[2]; void aj(void) { int l6, p0, dg, it, gs = 0; for (it = 0; it < 2; ++it) { --gs; for (s9 = 0; s9 < 2; ++s9) { if (gs != 0) break; for (dg = 0; dg < 2; ++dg) for (p0 = 0; p0 < 2; ++p0) for (l6 = 0; l6 < 2; ++l6) id[l6] = 0; } } } After moving s9 declarations into aj() cc1 starts to segfault w/ a new backtrace: --- qtcykola.c 2015-12-22 17:00:04.827862358 +0700 +++ eu1fk1op.c 2015-12-22 17:00:39.119531288 +0700 @@ -1,9 +1,9 @@ -int s9; int id[2]; void aj(void) { + int s9; int l6, p0, dg, it, gs = 0; for (it = 0; it < 2; ++it) { --gs; #0 0x000003fff7eefeca in isl_map_dim () from /usr/lib64/libisl.so.15 #1 0x00000000011c3a0a in translate_isl_ast_to_gimple::get_max_schedule_dimensions(scop*) () #2 0x00000000011c3ad9 in translate_isl_ast_to_gimple::generate_isl_schedule(scop*) () #3 0x00000000011c5924 in translate_isl_ast_to_gimple::scop_to_isl_ast(scop*, std::map<isl_id*, tree_node*, std::less<isl_id*>, std::allocator<std::pair<isl_id* const, tree_node*> > >&) () #4 0x00000000011c9012 in graphite_regenerate_ast_isl(scop*) () #5 0x00000000011c0366 in graphite_transform_loops() () [trimmed] Further minimization of these two new testcases yield the same failure as in #c0. Another question is, why segfaults in libisl.so aren't propagated to cc1 and, eventually, to a driver?