Hi,<br>I am implementing refactorings in CDT using clang (or llvm?) as the analysis engine. I am planning to write these library functions on top of clang, and then using native calls to communicate with them. Here are some specific things that I want to perform.<br>

<br>a) Given two variables, ask analysis engine if they are aliases or not.<br>b) Given a variable, find about its points-to-set. <br>c) Given a variable, follow its def-use chain.<br>d) Given a function, follow its call graph.<br>

e) Given a cursor, browse the AST. The AST may involve multiple files.<br>etc..<br><br>The analysis should be inter-procedural.<br><br>These are not written as optimization passes, but should be function calls that are like queries.<br>

<br>Please guide me as to: 1) whether I need to use llvm or clang, 2) which parts of clang/llvm should I concentrate on.<br><br>Thanks in advance.<br><br>Munawar<br>