STM32CubeIDE memory usage units (KB vs KiB) inconsistency
- December 22, 2025
- 7 replies
- 864 views
Dear STM32CubeIDE Support Team,
while analyzing the memory usage of my STM32 project, I noticed a potential inconsistency in how memory units are displayed in STM32CubeIDE.
Both the Build Analyzer and the memory overview label the values as “KB”, but the reported numbers clearly correspond to KiB (1024 bytes) rather than kB (1000 bytes). This behavior matches the output of arm-none-eabi-size, which reports sizes in bytes.
For example:
arm-none-eabi-size reports Flash usage as:
text + data = 64824 + 148 = 64972 bytes
Converted to kB (1000 bytes), this would be:
64.972 kB
However, STM32CubeIDE displays:
64972 / 1024 = 63.45 KiB, while labeling the unit as “KB”
As a result, summing RAM and Flash values only produces consistent results when interpreting the displayed “KB” values as KiB. The current labeling can therefore be confusing, especially when documenting or comparing memory usage.
I have attached two images that illustrate this behavior and show the comparison between arm-none-eabi-size and the STM32CubeIDE memory analysis.
I wanted to report this observation and ask whether the use of the “KB” label is intentional or if a clarification or correction is planned.
Thank you for your time and support.
Best regards,
Hadi Althiab
