Hi, I have some questions about inter-procedural analysis in LLVM.
For example, let's say that there is a code as following:
void f1(int *a, int *b, int *c) {...}
void f2(int *a, int *b, int *c) {...}
int main() {
int *a = malloc (...);
int *b = malloc (...);
int *c = malloc (...);
int *d = malloc (...);
int *e = malloc (...);
f1(a, b, c);
f2(c, d, e);
return 0;
}
I want to make information whether in attribute or metadata that f1's third argument is identical to f2's first argument.
But I am not sure the way to approach this.
I thought of Alias Analysis can lead me the way but it seems kind of different from what I'm trying to do.
The easiest way can be just iterating function arguments and collect information but doesn't seem to be safe at all.
Any advice will be helpful.
Thanks, Jake