determine code size
I have library intended for embedded devices developed in C for which I need 开发者_Go百科to compute the code size. The OS is Linux and compiler is gcc. Could you please indicate how this can be done? Also are there ways in which I can reduce the foot print size using mechanisms like compiler optimization?
gcc will do size optimization if the -Os option is given.
The GNU size utility will show the size of object code. See man size
.
精彩评论