[PATCH] D38862: Add must alias info to ModRefInfo.
Alina Sbirlea via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 12 17:36:32 PDT 2017
asbirlea added inline comments.
================
Comment at: lib/Analysis/AliasAnalysis.cpp:128
// Early-exit the moment we reach the bottom of the lattice.
- if (Result == MRI_NoModRef)
+ if ((Result & MRI_ModRef) == MRI_NoModRef)
return Result;
----------------
george.burgess.iv wrote:
> Probably-silly question: what's the difference between `Result == MRI_NoModRef` and `Result == MRI_Must`?
>
> (If the answer is "nothing", should we ever really see `MRI_Must` on its own?)
Not silly at all. In theory Result == MRI_Must can happen when checking ModRefInfo for 2 locations that alias each other, and both only read.
I updated the check for safety. I am not sure we should see MRI_Must on its own, but there is nothing preventing it right now.
https://reviews.llvm.org/D38862
More information about the llvm-commits
mailing list