qemu-arm
[Top][All Lists]
Advanced

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

Re: [Qemu-arm] .bss more than LM3S6965evb RAM size


From: Hui Yie Teh
Subject: Re: [Qemu-arm] .bss more than LM3S6965evb RAM size
Date: Sun, 22 Oct 2017 00:10:31 +1300

I see, thanks for your reply Peter! 

What if I have a stack size of 2048*4 as I'm using 4 threads with that stack size? Will that be in the RAM as well?

Also, this is the memory map of my linker: 

MEMORY {
RAM_INT (AIW) : ORIGIN = 0x20000000, LENGTH = 16M
ROM_INT (RX)  : ORIGIN = 0x00000000, LENGTH = 64M
}

I was wondering if it means that I have 16MB of RAM and 64MB of ROM? Or does it not affect the original RAM and ROM sizes?


On 21 October 2017 at 23:38, Peter Maydell <address@hidden> wrote:
On 21 October 2017 at 08:31, Hui Yie Teh <address@hidden> wrote:
> Hi,
>
> As far as I'm aware, the LM3S6965evb board on qemu has 64kB of RAM. However,
> my application has the following sizes:
>
>>    text        data       bss         dec         hex     filename
>>  77540      1544     64032  143116   22f0c   o-optimize/test.exe
>
>
> The bss and part of the data, I believe, will be located in the RAM.
> However, that is more than 64kB, but my program still runs fine on the
> emulated board. Is there a reason why? Or am I missing something here?

If the data runs off the end of the RAM, the image write will silently
write the data into nothingness, and reads will read as zeroes. If
your program doesn't actually use the data that's got lost it won't
notice, or maybe it behaves wrongly but not in ways you've noticed.
In this case it looks like your data+bss is 65576 bytes, which is only
40 bytes off the end, so it depends what the linker has put in those
last 40 bytes.

thanks
-- PMM


reply via email to

[Prev in Thread] Current Thread [Next in Thread]