Static memory footprint analysis
Chris Johns
chrisj at rtems.org
Tue Mar 10 00:15:58 UTC 2009
Ingolf Steinbach wrote:
>
> is it possible to calculate the memory footprint of an RTEMS/sparc
> application (which does NOT use dynamic memory allocation like
> malloc()) by just analyzing the ELF file? Something like:
>
> % sparc-rtems-objdump --headers application.exe |
> sum_size_column_for_ALLOC_sections
> % sparc-rtems-gdb application.exe
> (gdb) print Configuration.work_space_size
>
> and then add the outputs. Which memory consuming components are not
> covered by this (i.e. is there more than ALLOC sections and RTEMS
> workspace)?
>
The libc, networking or other services could be calling malloc. For example
printf will cause stdout to allocate a buffer.
> (RTEMS-4.6.5 solution preferred)
Newer versions of RTEMS have heap reporting functions that help here.
> Kind regards
> Ingolf
> _______________________________________________
> rtems-users mailing list
> rtems-users at rtems.com
> http://rtems.rtems.org/mailman/listinfo/rtems-users
More information about the users
mailing list