Expand description
Upload instrumentation and experimental upload strategies
(enabled via RANIM_PROFILE_UPLOAD).
Lightweight upload instrumentation for the queue.write_buffer paths,
recording bytes / calls / CPU time per buffer label. Enabled via
RANIM_PROFILE_UPLOAD=1 (or set_mode at runtime, e.g. from the
preview profiler panel); a no-op (one atomic read per upload) unless
enabled.
This is the stable counting core. Experimental upload strategies (skip-identical / dirty-range uploads) live on a separate branch and extend this module.
Structsยง
- Counters ๐
- Upload
Stats - Snapshot of the counters accumulated since the last
take_stats.
Enumsยง
- Upload
Mode - Upload instrumentation mode, seeded from
RANIM_PROFILE_UPLOADand runtime-switchable viaset_mode.
Staticsยง
- MODE ๐
u8::MAXmarks โnot seeded from the environment yetโ.- MODE_
SEEDED ๐
Functionsยง
- label_
or ๐ - mode
- The process-wide upload mode (seeded from
RANIM_PROFILE_UPLOADon first use, overridable at runtime viaset_mode). - record ๐
- Record one upload for
label. - registry ๐
- set_
mode - Switch the process-wide upload mode at runtime (takes effect for uploads after this call).
- take_
stats - Take and reset the accumulated stats, per buffer label.