Rust API for Optick Profiler
Supported Platforms
Windows (x64) | Linux | MacOS |
---|---|---|
YES | NO (IN PROGRESS) | NO (IN PROGRESS) |
How to use
In Cargo.toml
add:
[]
= "1.3.4"
Example 1 (generic app, automation, etc.):
Example 2 (game):
GUI
Use Optick GUI to open saved *.opt capture for further analysis: https://github.com/bombomby/optick/releases After grabbing the latest available Optick_vX.X.X.zip => launch Optick.exe.
Video Tutorial (Features Overview)
Procedural Macros
Optick supports a set of procedural macros for simplifying the process of code markup: https://crates.io/crates/optick-attr
// Instrument current function
//Generate performance capture for function to {working_dir}/capture_name(date-time).opt.
Feature flags
enable
- this flag is used by default and enables Optick instrumentation
Run as Administartor to collect ETW events
Optick uses ETW to collect hardware counters: switch-contexts, auto-sampling, CPU core utilization, etc. Run your app as administrator to enable the collection of ETW events:
Start-Process cargo run -Verb runAs