[core] Optimize looping_components_ with FixedVector to save flash (#11183)

This commit is contained in:
J. Nick Koston
2025-10-13 10:20:43 -10:00
committed by GitHub
parent aec60d122b
commit 0f356fcc79
3 changed files with 51 additions and 3 deletions

View File

@@ -340,8 +340,8 @@ void Application::calculate_looping_components_() {
}
}
// Pre-reserve vector to avoid reallocations
this->looping_components_.reserve(total_looping);
// Initialize FixedVector with exact size - no reallocation possible
this->looping_components_.init(total_looping);
// Add all components with loop override that aren't already LOOP_DONE
// Some components (like logger) may call disable_loop() during initialization