[llvm-dev] Access to dynamic execution information.

Chandler Carruth via llvm-dev llvm-dev at lists.llvm.org
Sun May 15 17:53:04 PDT 2016

On Fri, May 13, 2016 at 8:35 AM fateme Hoseini via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> Hi
> Does LLVM dynamically run the program to obtain profiling information like
> branch weight?

No, the profile information is either collected via instrumentation of the
program or via external sampling profilers. It is then read back into the
IR by the frontend or an optimization pass.

> if so, can we access the information regarding this run like the number of
> instructions that have been executed dynamically between two specific
> points of the program?

If Manuel Rigger's suggestion doesn't work, maybe try Valgrind which can
get these kinds of instruction counts?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160516/9b006325/attachment.html>

More information about the llvm-dev mailing list