Collecting LLVM Edge Profiling with llvm-prof

谁说胖子不能爱 提交于 2019-12-04 07:46:51

The problem was that I was passing to llvm-prof the bitcode file with instrumentation, the correct is to use the original file (without instrumentation):

llvm-prof sort.bc

another problem related to llvm-prof is that it's rounding the function/block execution frequency due to scientific notation. I've submitted a patch to llvm for correcting that.

Another tip is llvm-prof per default shows only the top 20 most executed basic blocks and it doesn't provide the user any means to change that. I've submitted another patch that add a command line parameter enabling the user to set how many basic blocks he/she wants in the output.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!