Upper limit for BSS on SPARC BSP ?

Sebastian Huber sebastian.huber at embedded-brains.de
Mon Sep 17 11:51:50 UTC 2018


On 08/09/2018 10:21, Jiri Gaisler wrote:
>
>
>
> On 09/07/2018 07:47 AM, Hugues Jérôme wrote:
>> Thanks Sebastian and Joel, we will try your suggestions
>>
>> I’ll see with partners what is feasible. I also suspect a difference 
>> of behaviour between dmon and grmon monitors when loading the program 
>> in memory
>>
>> Note I may have been misleading somehow:
>> our test program with a BSS of 1MB works perfectly fine,
>> the exact same program, with a different set of size for our data has 
>> a BSS of 4MB, and crashes due to an alignment error at RTEMS start up.
>>
>> The second seems to point to an unexpected behavior in the code 
>> setting the BSS
>
> Check that the external memory is working correctly, and that grmon 
> has set the stack pointer to top of external SDRAM. With 1 MByte BSS, 
> you might be executing completely from L2 cache, so you will never 
> access external RAM. With 4 MByte, you will hit the external RAM and 
> this might lead to failures if it is not working or initialized 
> correctly. You might need to 'wash' the external memory before first 
> use if it uses external EDAC, otherwise you will get spurious EDAC 
> errors on byte writes. Use the wash command in grmon or similar.
>
> Also check that the program is linked to start address that is withing 
> the RAM boundaries. Note that GR740 has start of SDRAM at address 0x0 
> while most leon2/3 systems has this at 0x40000000. A general leon3 
> binary will then not run properly on GR740 except when it fits in the 
> L2 cache.

Thanks for the hints. This turned out to be a problem in combination 
with the dmon boot loader/debugger. With the grmon it works.

-- 
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.huber at embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.



More information about the users mailing list