The Telemetry Engine is the central hub for data collection and distribution in TelemetryX.
The engine operates on a push-pull model:
- Pull: The engine polls registered
Collectorsat a high frequency (default 16.6ms intervals). - Push: Collected samples are packed into
TxMetricSamplestructs and pushed into a lock-free SPSC ring buffer. - Subscribe: UI widgets or the binary logger subscribe to the buffer to receive updates without blocking the collection loop.
Wait-free and lock-free concurrency is critical for near-zero overhead.
- Capacity: Pre-allocated to store thousands of latest samples.
- Ordering: Strictly chronological to ensure accurate frametime graphs.
- Performance: Pushing a sample takes ~15-30 nanoseconds on modern CPUs.
All metrics are converted to a Canonical Schema to ensure a consistent experience regardless of hardware.
- Frame Rate (FPS)
- Frame Time (ms)
- GPU Utilization (%)
- GPU Clock (MHz)
- GPU Temperature (°C)
- VRAM Usage (MB)
- CPU Utilization (%)
- I/O Disk Latency (ms)
- Network Ping (ms)
- C17 Implementation: Direct access to hardware APIs with minimal abstraction cost.
- SIMD-Friendly Structures: Data is packed to maximize cache hits during batch normalization.
- Instruction Level Parallelism: The poll loop is designed to be lean, allowing the CPU to execute collection calls in parallel where possible.