[LLVMdev] llvm-prof: Error opening 'llvmprof.out': Illegal seek
reem abdelkader
rm_aik at yahoo.com
Wed Sep 4 03:32:30 PDT 2013
It is solved.
The problem was trying to profile while the llvmprof.out has not been
generated.
Below, the sequence of instructions that worked with me
$ clang -03 -emit-llvm hello.c -c -o hello.bc
$ opt -insert-edge-profiling hello.bc -o hello.profile.bc
$ llc hello.profile.bc -o hello.profile.s
$ clang -o hello.profile hello.profile.s
<LLVM_HOME_DIR>/build/Debug+Asserts/lib/libprofile_rt.so
$ ./hello.profile
$ llvm-prof hello.profile.bc
and the output is:
===-------------------------------------------------------------------------===
LLVM profiling output for execution:
===-------------------------------------------------------------------------===
Function execution frequencies:
## Frequency
1. 1/1 main
===-------------------------------------------------------------------------===
Top 20 most frequently executed basic blocks:
## %%
Frequency
1. 100% 1/1 main() -
--
View this message in context: http://llvm.1065342.n5.nabble.com/llvm-prof-Error-opening-llvmprof-out-Illegal-seek-tp60909p60931.html
Sent from the LLVM - Dev mailing list archive at Nabble.com.
More information about the llvm-dev
mailing list