-
-
Notifications
You must be signed in to change notification settings - Fork 250
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Profiling support #743
base: master
Are you sure you want to change the base?
Profiling support #743
Conversation
@@ -1,5 +1,6 @@ | |||
{ | |||
"rust-analyzer.cargo.features": [ | |||
"simd-stable" | |||
"simd-stable", | |||
"dim3" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is not needed, but not an entirely bad thing 🤔 ; should we ignore this file in gitignore though ?
@@ -21,6 +27,7 @@ anyhow = "1" | |||
bitflags = "2" | |||
# NOTE: we are not using the (more recent) urdf-rs crate because of https://github.com/openrr/urdf-rs/issues/94 | |||
xurdf = "0.2" | |||
profiling = "1.0" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added the profiling
dependency there but I think I didn´t mark any functions
@@ -1552,6 +1552,7 @@ fn update_testbed( | |||
if state.running == RunMode::Step { | |||
state.running = RunMode::Stop; | |||
} | |||
profiling::finish_frame!(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
profiling::finish_frame!();
belongs here (in user code), as rapier isn't strictly the owner of the loop.
This PR uses https://crates.io/crates/profiling so we can choose any supported profiling options. This is also helpful for users to get an understanding of performances.
using tracy on all_examples3 (
cargo run --bin all_examples3 --features profiling/profile-with-tracy
)Should we remove
counters
from rapier ? I imagine it would be great to be able to output the same kind of csv we're doing currently, but using this profiling option.