From: Richard Biener Date: Mon, 29 Jan 2018 15:22:55 +0000 (+0000) Subject: re PR libgomp/84086 ([8 Regresssion] segfault in instantiate_scev_r for libgomp.fortr... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b9921bf0a01418b70e7869c45fd0c3cb7c50f528;p=gcc.git re PR libgomp/84086 ([8 Regresssion] segfault in instantiate_scev_r for libgomp.fortran/examples-4/simd-2.f90 -O1) 2018-01-29 Richard Biener PR tree-optimization/84086 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h. (flush_ssaname_freelist): When SSA names were released reset the SCEV hash table. From-SVN: r257152 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index ac75869a3e5..e860055a445 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2018-01-29 Richard Biener + + PR tree-optimization/84086 + * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h. + (flush_ssaname_freelist): When SSA names were released reset + the SCEV hash table. + 2018-01-29 Richard Biener PR tree-optimization/84057 diff --git a/gcc/tree-ssanames.c b/gcc/tree-ssanames.c index dffaa17a2d2..6cce43be593 100644 --- a/gcc/tree-ssanames.c +++ b/gcc/tree-ssanames.c @@ -29,6 +29,8 @@ along with GCC; see the file COPYING3. If not see #include "stor-layout.h" #include "tree-into-ssa.h" #include "tree-ssa.h" +#include "cfgloop.h" +#include "tree-scalar-evolution.h" /* Rewriting a function into SSA form can create a huge number of SSA_NAMEs, many of which may be thrown away shortly after their creation if jumps @@ -241,6 +243,9 @@ verify_ssaname_freelists (struct function *fun) void flush_ssaname_freelist (void) { + /* If there were any SSA names released reset the SCEV cache. */ + if (! vec_safe_is_empty (FREE_SSANAMES_QUEUE (cfun))) + scev_reset_htab (); vec_safe_splice (FREE_SSANAMES (cfun), FREE_SSANAMES_QUEUE (cfun)); vec_safe_truncate (FREE_SSANAMES_QUEUE (cfun), 0); }