[llvm-dev] GlobalsAA from GVN

James Molloy via llvm-dev llvm-dev at lists.llvm.org
Thu Dec 3 01:32:18 PST 2015

Hi Vaivaswatha,

GlobalsAA is not an immutable pass because it needs to cache queries to
avoid them being unusably slow. It therefore relies on passes explicitly
preserving it. Most of the passes in the scalar pipeline have been modified
to setPreserved<GlobalsAA>() and I know the pass gets preserved at least
until LICM.

You can use -debug-pass=Executions to determine at what point GlobalsAA is
not preserved (which pass clobbers it) - you'd then need to add GlobalsAA
to its preserved pass list.



On Wed, 2 Dec 2015 at 09:35 Vaivaswatha Nagaraj via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> Hi,
> I've noticed that alias analysis queries arising from GVN do not use the
> results from GlobalsAA.
> The last call to AAResultsWrapperPass::runOnFunction() before GVN does not
> add GlobalsAAWrapperPass due to unavailability. This leads to the alias
> queries from GVN not having any globals mod-ref info.
> Is this a known issue? and is there any way to have globals mod-ref info
> available for GVN?
> Thanks,
>   - Vaivaswatha
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20151203/fd90afd1/attachment.html>

More information about the llvm-dev mailing list