https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105663
--- Comment #6 from Richard Biener <rguenth at gcc dot gnu.org> --- bitwise and is allowed for pointers on GIMPLE for alignment purposes and to avoid round-trips to/from integer types for this. It's only natural to then allow all bit operations on pointers (and hard to excempt some given we have many patterns transforming between them). It looks like also MIN/MAX is allowed (why not, we also allow relational compares), but BIT_NOT is explicitely disallowed. I think we simply have to accept those operations on pointers or decide allowing BIT_AND was a mistake and remove support for all of them.