[PATCH] D92401: [BasicAA] Handle two unknown sizes for GEPs
Johannes Doerfert via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 1 23:24:22 PST 2020
jdoerfert added a comment.
In D92401#2426503 <https://reviews.llvm.org/D92401#2426503>, @nikic wrote:
> In D92401#2426402 <https://reviews.llvm.org/D92401#2426402>, @jdoerfert wrote:
>
>> This kind of logic should always be valid, regardless if V1 is a GEP or not, right? Is there a way to do this check early or late for any query?
>
> The general idea is valid, but the way it is applied depends on the operation. For GEPs we just strip to the base pointer. For phis and selects, we recurse over the phi/select operands (with special casing for the case of identical control dependence).
Hm, I'm confused(, but also not deep enough in the BasicAA code to argue). I assumed that this new logic which is put in a function that has a precondition (isa<GEP>(V1)) could be placed in a function without that precondition. The logic does not utilize the fact that V1 isa GEP. Anyway, it was just a thought.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D92401/new/
https://reviews.llvm.org/D92401
More information about the llvm-commits
mailing list