When running FRE in the loop pipeline (as part of the conditionally
scheduled scalar cleanups) we have to reset the SCEV hashtable as
otherwise we can end up with stale entries and all sorts of problems.
Catched by my out-of-tree verifier for this problem.
2021-01-08 Richard Biener <rguenther@suse.de>
* tree-ssa-sccvn.c (pass_fre::execute): Reset the SCEV hash table.
if (iterate_p)
loop_optimizer_finalize ();
+ if (scev_initialized_p ())
+ scev_reset_htab ();
+
/* For late FRE after IVOPTs and unrolling, see if we can
remove some TREE_ADDRESSABLE and rewrite stuff into SSA. */
if (!may_iterate)