J. Nick Koston d1ef6bf604 [runtime_stats] Store stats inline on Component to eliminate std::map lookup
The runtime_stats component used a std::map<Component*, ComponentRuntimeStats>
to record per-component timing data. Every loop iteration for every component
required a red-black tree lookup to record its time, adding ~2-3µs of
measurement overhead per component — often exceeding the actual work done
by lightweight components like OTA idle checks.

Move RuntimeStats struct directly onto Component (behind #ifdef USE_RUNTIME_STATS)
so recording is a direct member access with zero lookup cost. The
RuntimeStatsCollector now iterates App.components_ to collect stats instead of
maintaining its own map, eliminating ~2KB of red-black tree code.
2026-03-31 22:58:18 -10:00
2023-06-12 17:00:34 +12:00
2026-03-31 13:08:50 +13:00
2026-04-01 09:29:57 +13:00
2022-09-06 15:48:01 +12:00
2025-12-21 09:26:03 -05:00
2024-03-28 10:20:51 +13:00
2025-07-17 22:40:28 +12:00
2025-12-08 14:37:45 -05:00
2026-03-12 07:34:53 +13:00
2025-07-17 22:40:28 +12:00
S
Description
ESPHome is a system to control your ESP8266/ESP32 by simple yet powerful configuration files and control them remotely through Home Automation systems.
Readme Multiple Licenses 546 MiB
Languages
C++ 60.1%
Python 39.3%
C 0.3%
JavaScript 0.2%