I've been trying to profile my C++ application in Linux by following this article on perf record. My understanding is all I need to do is run perf record program [program_options]
, where program
is the program executable and [program options]
are the arguments I want to pass to the program. However, when I try to profile my application like this:
perf record ./csvJsonTransducer -enable-AVX-deletion test.csv testout.json
perf
returns almost immediately with a report. It takes nearly 30 seconds to run./csvJsonTransducer -enable-AVX-deletion test.csv testout.json
without perf, though, and I want perf
to monitor my program for the entirety of its execution, not return immediately. Why is perf
returning so quickly? How can I make it take the entire run of my program into account?