Skip to content

Conversation

@kartben
Copy link
Contributor

@kartben kartben commented Dec 10, 2025

Replace inefficient string parsing loop with CMake list iteration for processing list_hardware.py output. The previous implementation used repeated string operations on the entire output string for each line, which is increasingly slow as hardware list grows...

Local tests show hwmv2.cmake module loading in ~350 ms instead of 540 ms on my machine.

Replace inefficient string parsing loop with CMake list iteration for
processing list_hardware.py output. The previous implementation used
repeated string operations on the entire output string for each line,
which is increasingly slow as hardware list grows.

Local tests show hwmv2.cmake module loading in ~350 ms instead of
540 ms on my machine.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
@kartben kartben changed the title cmake: hwmv2: optimize hardware list parsing with CMake lists cmake: hwmv2: optimize list_hardware.py output parsing Dec 10, 2025
@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants