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

--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
I wonder if we could just optimize:
h_392 = h_391 ptr+ 1;
  _394 = h_392 ptr- &o;

into:
  _394 = (h_391 ptr- &o) + 1;

that is left with:
  _386 = (sizetype) &o;
  _390 = _386 + 2;
  h_391 = (char *) _390;

or
(char *)((sizetype) &o + 2) ptr- &o

(pointer_diff (convert (plus (convert @0) @1)) @0)
-> (convert @1)

Which will get us 3 as 2+1

Reply via email to