https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66090
--- Comment #6 from joseph at codesourcery dot com <joseph at codesourcery dot com> --- I think this comes under tracking pointer provenance (DR#260) and saying that certain arithmetic on pointers derived by casts from integers has undefined behavior.