From 3f43dc36878e698c71c9828ca59a4c3259845589 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Thu, 24 Jun 2010 19:34:03 +0000 Subject: Document problems that I encountered when working on -scev-aa. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106776 91177308-0d34-0410-b5e6-96231b3b80d8 --- docs/AliasAnalysis.html | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) (limited to 'docs') diff --git a/docs/AliasAnalysis.html b/docs/AliasAnalysis.html index 5b4eb937a5..42b01ac7ec 100644 --- a/docs/AliasAnalysis.html +++ b/docs/AliasAnalysis.html @@ -31,6 +31,7 @@
  • AliasAnalysis chaining behavior
  • Updating analysis results for transformations
  • Efficiency Issues
  • +
  • Pass Manager Issues
  • @@ -502,6 +503,45 @@ method as possible (within reason).

    + +
    + Pass Manager Issues +
    + +
    + +

    PassManager support for alternative AliasAnalysis implementation +has some issues.

    + +

    There is no way to override the default alias analysis. It would +be very useful to be able to do something like "opt -my-aa -O2" and +have it use -my-aa for all passes which need AliasAnalysis, but there +is currently no support for that, short of changing the source code +and recompiling. Similarly, there is also no way of setting a chain +of analyses as the default.

    + +

    There is no way for transform passes to declare that they preserve +AliasAnalysis implementations. The AliasAnalysis +interface includes deleteValue and copyValue methods +which are intended to allow a pass to keep an AliasAnalysis consistent, +however there's no way for a pass to declare in its +getAnalysisUsage that it does so. Some passes attempt to use +AU.addPreserved<AliasAnalysis>, however this doesn't +actually have any effect. + +

    AliasAnalysisCounter (-count-aa) and AliasDebugger +(-debug-aa) are implemented as ModulePass classes, so if your +alias analysis uses FunctionPass, it won't be able to use +these utilities. If you try to use them, the pass manager will +silently route alias analysis queries directly to +BasicAliasAnalysis instead.

    + +

    Similarly, the opt -p option introduces ModulePass +passes between each pass, which prevents the use of FunctionPass +alias analysis passes.

    + +
    +
    Using alias analysis results -- cgit v1.2.3