[cfe-dev] Static Analyzer : Query regarding how symbols are marked as dead
blitz.opensource at gmail.com
Mon Mar 11 01:09:14 PDT 2013
I was going through Malloc checker in clang Static analyzer. I had a few
1) How is a symbol marked as dead( How does clang static analyzer detect
that a symbol is dead) ?
char* p = (char*) malloc(sizeof(char));
char* q = myMalloc();
In the above example symbol assigned for p in myMalloc is alive till
main(caller) exits right?
2) In case of IPA how are symbol propagated form one function to another in
case it is passed as a parameter.
void myFree(char* p)
char* q = (char*) malloc(sizeof(char));
In the above example is it true that the parameter p in myFree is assigned
the same symbol as that of q being passed to the function? If yes could
someone guide me were this assignment of symbol happens?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the cfe-dev