From: Gary Thomas <gthomas@redhat.com>
To: Fabrice Gautier <Fabrice_Gautier@sdesigns.com>
Cc: "Ecos-List \(E-mail\)" <ecos-discuss@sourceware.cygnus.com>
Subject: RE: [ECOS] Programs Image Size
Date: Thu, 20 Jul 2000 17:28:00 -0000 [thread overview]
Message-ID: <XFMail.20000720182827.gthomas@redhat.com> (raw)
In-Reply-To: <21DDE8E5343ED411840A00A0CC3340201047E5@EXCHANGE5_5>
On 20-Jul-2000 Fabrice Gautier wrote:
> Hi,
>
> When building the examples in the eCos/examples directory, with a default
> ARM PID board configuration, the resulting .exe images are about 1 Meg in
> size. However when downloading to the board the downloaded size is only
> about 40Ko. Why is there such a difference? What are in the .exe images? And
> how can I evaluate the "real" size?
>
The executable image will contain information used by GDB and/or Insight
for debugging purposes. Since this information must represent the program
in it's entirety, you can imagine it might be large.
If you want to see how big a program is, try using "size" or "objdump".
E.g.
[gary@hermes edb7212_test]$ arm-elf-size install/tests/kernel/current/tests/tm_basic
text data bss dec hex filename
43184 5360 5798192 5846736 5936d0 install/tests/kernel/current/tests/tm_basic
[gary@hermes edb7212_test]$ arm-elf-objdump -h install/tests/kernel/current/tests/tm_basic
install/tests/kernel/current/tests/tm_basic: file format elf32-littlearm
Sections:
Idx Name Size VMA LMA File off Algn
0 .debug_aranges 000010a0 00000000 00000000 00013da0 2**0
CONTENTS, READONLY, DEBUGGING
1 .debug_pubnames 00002ed7 00000000 00000000 00014e40 2**0
CONTENTS, READONLY, DEBUGGING
2 .debug_info 0006dda7 00000000 00000000 00017d17 2**0
CONTENTS, READONLY, DEBUGGING
3 .debug_abbrev 00005adf 00000000 00000000 00085abe 2**0
CONTENTS, READONLY, DEBUGGING
4 .debug_line 00012f73 00000000 00000000 0008b59d 2**0
CONTENTS, READONLY, DEBUGGING
5 .rom_vectors 00000060 00008000 00008000 00008000 2**5
CONTENTS, ALLOC, LOAD, CODE
6 .text 0000a850 00008060 00008060 00008060 2**2
CONTENTS, ALLOC, LOAD, READONLY, CODE
7 .fini 00000000 000128b0 000128b0 0009e510 2**0
CONTENTS
8 .rodata 000010e0 000128b0 000128b0 000128b0 2**2
CONTENTS, ALLOC, LOAD, DATA
9 .rodata1 00000000 00013990 00013990 0009e510 2**0
CONTENTS
10 .fixup 00000000 00013990 00013990 0009e510 2**0
CONTENTS
11 .gcc_except_table 00000000 00013990 00013990 0009e510 2**0
CONTENTS
12 .data 00000410 00013990 00013990 00013990 2**2
CONTENTS, ALLOC, LOAD, DATA
13 .bss 00587930 00013da0 00013da0 00013da0 2**4
ALLOC
14 .sram 00000000 60000000 60000000 0009e510 2**0
CONTENTS
From this example, you can see that the code size of this program is
only 43k, but the debug information is quite large (750k).
prev parent reply other threads:[~2000-07-20 17:28 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-07-20 16:47 Fabrice Gautier
2000-07-20 17:28 ` Gary Thomas [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=XFMail.20000720182827.gthomas@redhat.com \
--to=gthomas@redhat.com \
--cc=Fabrice_Gautier@sdesigns.com \
--cc=ecos-discuss@sourceware.cygnus.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).