Run
size <object>
or
size <archive>
or
size <shared-object>
. (or "target-") if you use cross-compilation: arm size if you use arm-gcc)
He will give you
text data bss dec hex filename
where text is the size of the program, bss is the initialized globals and data is read-only data.
While this answers your question, you probably want to use a specific LdScript (when using ld as the linker), where you will place partitions in accessible memory locations manually when making the last link.
source share