TermUI.Dev.PerfMonitor (TermUI v0.2.0)
View SourcePerformance Monitor for development mode.
Displays real-time performance metrics: FPS, frame time, memory usage, and process count. Toggle with Ctrl+Shift+P when dev mode is enabled.
Metrics
- FPS: Frames per second (rolling average)
- Frame Time: Time to render each frame (graph)
- Memory: Total BEAM memory usage
- Processes: Number of BEAM processes
Summary
Functions
Formats bytes into human-readable string.
Formats microseconds into human-readable string.
Gets detailed BEAM memory breakdown.
Gets message queue length for a process.
Gets reduction count for a process (rough CPU usage indicator).
Gets scheduler utilization.
Renders the performance monitor panel.
Calculates sparkline characters for a list of values.
Functions
Formats bytes into human-readable string.
Formats microseconds into human-readable string.
@spec get_memory_breakdown() :: map()
Gets detailed BEAM memory breakdown.
Gets message queue length for a process.
Gets reduction count for a process (rough CPU usage indicator).
@spec get_scheduler_utilization() :: [float()]
Gets scheduler utilization.
Renders the performance monitor panel.
Returns render nodes for the metrics display.
Calculates sparkline characters for a list of values.