https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103961

--- Comment #8 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #3)
> Looks like GCC is getting confused due to:
>  p--;
> 
> 
> I don't get:
>   [cap_text.c:419:3] # PT = anything 
>   _104 = p_65 + 18446744073709551615;
> 
> All other places just have   # PT = { D.4523 } (escaped)
> 
> D.4523 being buf decl.

I think that might be ranger adding nonnull to a pointer where we previously
have no points-to info at all (which means anything as well).  The above
stmt is introduced by PRE:

-  <bb 81> [local count: 982087419]:
-  goto <bb 21>; [100.00%]
+  <bb 94> [local count: 982087419]:
+  goto <bb 23>; [100.00%]
+
+  <bb 29> [local count: 37309945]:
+  [cap_text.c:419:3] _104 = p_65 + 18446744073709551615;

-  <bb 27> [local count: 39298952]:
+  <bb 30> [local count: 39298952]:
   # PT = { D.4523 } (escaped)
-  # p_228 = PHI <p_65(26), [cap_text.c:403:4] p_147(20)>
-  [cap_text.c:419:3] # PT = { D.4523 } (escaped)
-  p_149 = p_228 + 18446744073709551615;
+  # p_228 = PHI <p_65(29), [cap_text.c:403:4] p_147(91)>
+  # PT = { D.4523 } (escaped)
+  # prephitmp_82 = PHI <_104(29), p_210(91)>

which could indeed have preserved points-to info (but it would need to be
tracked in the expression sets so that's not too easy).

Reply via email to