ci: stop building every translation on five Zephyr boards - #11336
Merged
Merged
Conversation
objcopy writes one image from the lowest address to the highest, so a board with a region far above the firmware one gets a sparse file whose size is the span rather than the usage. renesas_ek_ra8d1 keeps its option bytes 16 MB above flash and reports 16818896 bytes used of 2064384, so it never looks like it fits and every language is built. When the image is larger than the region it has to fit in, it cannot be a usage figure. Take the bytes the hex puts inside the region instead: renesas_ek_ra8d1 now reads 523932 bytes, 4 bytes from what ld's own --print-memory-usage table prints. Unchanged on 30 local maps across atmel-samd, raspberrypi and zephyr-cp.
The three native_* Zephyr boards link a host executable, so there is no zephyr.bin, build_memory_info has nothing to measure and writes no firmware.size.json. The missing file reads as "size unknown, build them all", which is right for a board with flash and pointless for one without: native_native_sim spends 21 of its 26 minutes proving that 16 translations fit in a flash it doesn't have. A board whose only artifact is a host executable skips them, like a board with room to spare. CIRCUITPY_BUILD_EXTENSIONS == ["exe"] holds for the three native_* boards and for no other board in any port.
regions_from_map() returns (origin, length) now and the RAM line still read it as a length, so every board with a RAM region failed after printing the flash line.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Five Zephyr boards build all 17 translations on a pull request, for two reasons.
The three
native_*boards link a host executable with no flash region in the map, so there is nothing to measure, nofirmware.size.json, and a missing one means build them all. native_native_sim spends 21 of its 26 minutes there.renesas_ek_ra8d1andrenesas_ek_ra6m5keep their option bytes 16 MB above flash, sozephyr.binis sparse and its size is the span. Both report 16818896 bytes used of a 2 MB region and never fit.A board whose only artifact is a host executable has no flash to fit in, so it skips them now. An image bigger than its region is measured from the hex instead: ra8d1 reads 523932 bytes, 4 bytes from ld's own
--print-memory-usage. About 85 minutes per run that builds Zephyr.CIRCUITPY_BUILD_EXTENSIONSis["exe"]on those three boards.build_memory_info.pygives the same numbers as before on 30 linker maps from three ports.