[LLVMdev] RegisterAnalysisGroup

David Greene dag at cray.com
Fri Sep 14 14:04:18 PDT 2007


On Friday 14 September 2007 15:51, Chris Lattner wrote:

> When basicaa registers itself as part of the analysis group, it uses:
>
>    RegisterPass<BasicAliasAnalysis>
>    X("basicaa", "Basic Alias Analysis (default AA impl)");
>
>    // Declare that we implement the AliasAnalysis interface
>    RegisterAnalysisGroup<AliasAnalysis, true> Y(X);
>
> The "true" says that it is the default,

Right, I get that.  My question is how a pass that requires AliasAnalysis
gets Andersens when -anders-aa is passed on the command-line.
Someone has to call setNormalCtor on the PassInfo for the AliasAnalysis
group but I can't fgind that code anywhere.

Another question:

I'm debugging some analysis group code and I instrumented the
registration constructors.  I see weird things like this:

Adding No Alias Analysis (always returns 'may' alias) to group
Adding Basic Alias Analysis (default AA impl) to group
Set ctor for
Adding AA use debugger to group
Adding Count Alias Analysis Query Responses to group
Registering analysis group Alias Analysis

Huh?  How can group members be registered before the group is?
How does that work?

When I added a new coalescer to the compiler and tried to use it, I
got SimpleRegisterCoalescing (the default) instead.  I'm trying to 
figure out why.

                                     -Dave



More information about the llvm-dev mailing list