This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH RFA: PR 29286: Handle placement new aliasing issues
> What does TYPE_REF_CAN_ALIAS_ALL mean, exactly? Right now it is
> implemented to mean that a pointer with that type can point to
> anything whatsoever.
That's wrong. It doesn't mean "pointer to volatile", but "pointer to alias
set 0".
> That is not what CHANGE_DYNAMIC_TYPE_EXPR means
> in my patch. CHANGE_DYNAMIC_TYPE_EXPR means that a specific pointer
> can point to a value of any type.
This is what TYPE_REF_CAN_ALIAS_ALL is supposed to mean.
> TYPE_REF_CAN_ALIAS_ALL disables the whole analysis. That is, if P has
> a type with TYPE_REF_CAN_ALIAS_ALL, then the alias analysis code
> assumes that P could point to V, even if it can't see any way that the
> address of V could have wound up in the variable P.
That sounds like an incorrect implementation to me. It's just supposed to
disable the type-based checking.