[PATCH] D20665: Claim NoAlias if two GEPs index different fields of the same struct

Daniel Berlin via llvm-commits llvm-commits at lists.llvm.org
Thu May 26 09:32:08 PDT 2016

Doesn't this guarantee that they are starting from the same point
> regardless of their allocation site?

Yes, I missed that in the context :)

> The logic is that if two GEPs sharing the same base pointer access through
> the same index until index 'i-1' but have a different value at index 'i',
> and if the index typed at index 'i-1' is a struct, then at index 'i' they
> access two different fields of the same struct (I assumed 'same struct'
> because two GEPs share the same pointer operand and same index until 'i-1').

Okay. Because of the way the loop is structured, this isn't really clear
that this is what is happening, despite the comment

> http://reviews.llvm.org/D20665
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160526/703a3e2a/attachment.html>

More information about the llvm-commits mailing list