Actions

icon Post
text/html Subscribe
text/html Unsubscribe

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [coldfire-gnu-discuss] The different size is gotten from m68k-elf-nm and m68k-elf-readelf


  • To: Ha Luong <haluongvn@xxxxxxxxx>
  • Subject: Re: [coldfire-gnu-discuss] The different size is gotten from m68k-elf-nm and m68k-elf-readelf
  • From: Daniel Jacobowitz <dan@xxxxxxxxxxxxxxxx>
  • Date: Mon, 24 Mar 2008 10:00:11 -0400

On Mon, Mar 24, 2008 at 02:32:23PM +0700, Ha Luong wrote:
> Dear Sir,
> 
> I used m68k-elf-readelf and m68k-elf-nm for calculating the elf size. But
> the total size from m68k-elf-readelf is different to its from m68k-elf-nm.
> I used
> The total size from m68k-elf-readelf = the total of size column.
> with the command line option "m68k-elf-readelf -S xxx.elf"
> 
> And The total size from m68k-elf-nm = the total of column 2
> with the command line option "m68k-elf-nm.exe -S --print-size --print-armap
> --size-sort xxx.elf"

The total size of all sections may be larger than the total size of
all symbols.  There are structures in your application, like the
symbol table, which do not have an associated symbol.

If you just want the memory requirements of your application, I
recommend using m68k-elf-size or m68k-elf-readelf -l (lowercase
L).

-- 
Daniel Jacobowitz
CodeSourcery