[LLVMdev] Alias Analysis accuracy
eli.friedman at gmail.com
Fri Sep 21 14:40:35 PDT 2012
On Fri, Sep 21, 2012 at 2:35 PM, Welson Sun <welson.sun at gmail.com> wrote:
> Dear LLVM,
> I would like to understand how to improve the LLVM alias analysis accuracy.
> I am currently using llvmgcc 2.9 and llvm 3.0. Here is the C code:
> void foo(int a[SIZE], int b[SIZE], int c[SIZE])
> for(int i=0; i<SIZE; i++)
> c[i] = a[i] + b[i];
> So, all a, b and c may alias? I guess I have to read the BasicAliasAnalysis
> code to understand what is going on. But this is obviously too conservative
> to be useful.
You have a function which takes three arbitrary "int*"; how exactly do
you expect the compiler to determine an aliasing relationship?
More information about the llvm-dev