public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] rodata feature :-(
@ 2000-11-20  6:52 Boris V. Guzhov
  2000-12-05 20:37 ` Jonathan Larmour
  0 siblings, 1 reply; 3+ messages in thread
From: Boris V. Guzhov @ 2000-11-20  6:52 UTC (permalink / raw)
  To: ecos-discuss

Hi All,

There is a very interesting  feature of the "rodata" section.

There is the a.out program that linked with the following linker
script (mlt_i386_pc_ram.ldi):
MEMORY
{
    ram : ORIGIN = 0x0, LENGTH = 0x800000
}

SECTIONS
{
    SECTIONS_BEGIN
    SECTION_vectors (ram, 0x10000, LMA_EQ_VMA)
    SECTION_text (ram, ALIGN (0x4), LMA_EQ_VMA)
    SECTION_fini (ram, ALIGN (0x4), LMA_EQ_VMA)
    SECTION_rodata1 (ram, ALIGN (0x8), LMA_EQ_VMA)
    SECTION_rodata (ram, ALIGN (0x8), LMA_EQ_VMA)
    SECTION_fixup (ram, ALIGN (0x4), LMA_EQ_VMA)
    SECTION_gcc_except_table (ram, ALIGN (0x1), LMA_EQ_VMA)
    SECTION_rel__got (ram, ALIGN (0x1), LMA_EQ_VMA)
    SECTION_data (ram, 0x100000, LMA_EQ_VMA)
    SECTION_sbss (ram, ALIGN (0x4), LMA_EQ_VMA)
    SECTION_bss (ram, ALIGN (0x10), LMA_EQ_VMA)
    SECTIONS_END
}

It's "nm -gn a.out" output:
....
0007a0e0 R bit_first_set8
00092d08 R  Cyg_libc_str_null_mask_1
 00092d10 R Cyg_libc_str_null_mask_2
0009522f R nothrow
00095360 A _EXCEPT_END_
....
There is strange memory hole between "bit_first_set8" and "
Cyg_libc_str_null_mask_1":
0x92d08 - 0x7a0e0 = 0x18C28 (~100 kb).

How can you explain it?

Note that:
- the bit_first_set8 declaration is  "extern const unsigned char
bit_first_set8[256];",
- the bit_first_set8 and Cyg_libc_str_null_mask_*  variables are declared in
different files.

Thanks in advance.

--
Boris Guzhov,
St.Petersburg, Russia




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2000-12-06  9:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-11-20  6:52 [ECOS] rodata feature :-( Boris V. Guzhov
2000-12-05 20:37 ` Jonathan Larmour
2000-12-06  9:06   ` Boris V. Guzhov

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).