AS Jakub  observed in an earlier testcase (97325),  when EVRP dumps the known SSA_RANGES, it isn't expecting names to be deleted that it could not delete, so it wasn't checking.

With the hybrid model, ranger sometimes deletes things that EVRP calculated a range for, and the resulting dump was confusing

 _1: short unsigned int VARYING
 _2: int [0, 65535]
 _3: int [-65535, 0]
 : int [0, 32]
 : long long unsigned int [0, 0]
 c_6(D): long long unsigned int VARYING
 : long long unsigned int [0, 32]

Now we just check if then name is valid before dumping.

Bootstrapped on x86_64-pc-linux-gnu,  no regressions, pushed.
2020-10-16  Andrew MacLeod  <amacl...@redhat.com>

	* vr-values.c (dump_all_value_ranges): Only dump names which are
	still active.


diff --git a/gcc/vr-values.c b/gcc/vr-values.c
index da0b249278b..e917704d9bb 100644
--- a/gcc/vr-values.c
+++ b/gcc/vr-values.c
@@ -1999,7 +1999,7 @@ vr_values::dump_all_value_ranges (FILE *file)
 
   for (i = 0; i < num_vr_values; i++)
     {
-      if (vr_value[i])
+      if (vr_value[i] && ssa_name (i))
 	{
 	  print_generic_expr (file, ssa_name (i));
 	  fprintf (file, ": ");

Reply via email to