[LLVMdev] About static-profile in llvm-2.8

Qingan Li ww345ww at gmail.com
Thu Jan 20 23:14:51 PST 2011


When I searched for branch frequency profiling on the internet, I got this
link  by a casual chance:
http://homepages.dcc.ufmg.br/~rimsa/tools/stprof-llvm.patch.
It seems it was written by Andrei Rimsa.

So I downloaded and integrate these files into the llvm-2.8 building. After
the building, I tried "opt -static-profile bitcnt_1.bc", and an segment
fault error occured. I debugged it step by step, and found the initial
reason was:
in StaticProfilePass.cpp: line 307 (funciton: PropagateCallFrequency), since
the root of type CallGraphNode * has no valid function,  the
node->getFunction() returned a NULL pointer, thus the F->getName() in line
307 caused a code down. I confirmed that there was a main function in
bitcnt_1.c (from MiBench)

I need the help.
-- 
Best regards,

Li Qingan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110121/27b9eb56/attachment.html>


More information about the llvm-dev mailing list