Registry / observability / puffin

puffin

JSON →
library0.20.0rscratesunverified

A simple instrumentation profiler for games and real-time applications.

# Cargo.toml [dependencies] puffin = "0.20.0"
INSTALL
IMPORT
SIG · PUFFIN
P
puffin
observabilityrustv0.20.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

profile_function
use puffin::profile_function;

Profile a function using Puffin's macro and print results.

use puffin::profile_function; fn expensive_function() { profile_function!(); // ... work } fn main() { puffin::set_scopes_on(true); expensive_function(); puffin::GlobalProfiler::lock().print(); }
Debug
Known issues
gotchaProfiling scopes must be enabled at runtime with `puffin::set_scopes_on(true)`; otherwise no data is collected.
fix
Call `puffin::set_scopes_on(true)` before profiling.
affects: >=0.1.0
Upgrade
Version history
0.20.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
30 hits · last 30 days
node
24
OpenAI (training)
2
Resources
puffin — cargo add puffin · libregistry