You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Answering these questions will probably just need doc improvements rather than other fixes, but I'm not sure so here goes:
Using cargo profiler callgrindwhich executable is run?
How does this work with cargo bench? Can I run cargo profiler --bench callgrind (or something like that) to get profile stats for the different benchmarks? For now I've been creating a main.rs building that (with debug symbols) and then using cargo profiler callgrind -n 20 --bin ./target/release/executable_name. I swap out the contents of main with my benchmarks to get results. This seems suboptimal. I'm probably missing something.
It's probably worth calling out specifically that -n <count> limits the shown instructions. That wasn't immediately clear.
Thanks.
The text was updated successfully, but these errors were encountered:
Normally, rust benchmarks are separate binaries running with or without the --bench flag. This means, at least for now, you can profile benchmarks using the --bin flag (optionally with command line arguments via --)
Answering these questions will probably just need doc improvements rather than other fixes, but I'm not sure so here goes:
cargo profiler callgrind
which executable is run?cargo bench
? Can I runcargo profiler --bench callgrind
(or something like that) to get profile stats for the different benchmarks? For now I've been creating amain.rs
building that (with debug symbols) and then usingcargo profiler callgrind -n 20 --bin ./target/release/executable_name
. I swap out the contents of main with my benchmarks to get results. This seems suboptimal. I'm probably missing something.-n <count>
limits the shown instructions. That wasn't immediately clear.Thanks.
The text was updated successfully, but these errors were encountered: