tracy-rs
This provides a Rust integration for the Tracy profiling library (https://bitbucket.org/wolfpld/tracy).
Usage
- Clone the Tracy library from the above URL.
- Follow the steps to build the profiler GUI (e.g. in tracy/profiler/build/unix/).
- Follow the steps to build the profiler shared library (e.g. in tracy/library/unix).
- Add this crate to your project dependencies, with the 'enable_profiler' cargo feature.
- Call
tracy_rs::load
at the start of your application, providing path to library from (3). - Insert the main frame marker
tracy_frame_marker!();
at the end of your frame. - Optionally, add sub-frame markers with
tracy_begin_frame!()
andtracy_end_frame!()
. - Annotate functions to be profiled with
profile_scope!()
. - Run the application and profiler GUI.