From: weldat on
Hi all;
may someone explain to me how to add memory to store my microBlaze program
if my system is out of memory?
thank you in advance



---------------------------------------
Posted through http://www.FPGARelated.com
From: Magne Munkejord on
weldat wrote:
> Hi all;
> may someone explain to me how to add memory to store my microBlaze program
> if my system is out of memory?
> thank you in advance
>
>
>
> ---------------------------------------
> Posted through http://www.FPGARelated.com

I think you have three choices:
1. Rerun the system builder wizard (if you saved the .bsb file after the
first run) You will loose any changes you have done to the hardware.

2. Edit the memory component in XPS GUI.

3. Manually edit the hardware specification file for your system (.mhs)

Rebuild hardware and remember to rerun address map auto generation.

When you have updated your hardware you must update your software
platform, and specifically your linkerscript.

HTH,

Magne
From: Andy Peters on
On Mar 12, 5:36 am, "weldat" <gweleki...(a)gmail.com> wrote:
>  Hi all;
> may someone explain to me how to add memory to store my microBlaze program
> if my system is out of memory?
> thank you in advance

I assume that "by out of memory," you mean that you do not have enough
BRAMs to store the program. If so, then you need to provide some kind
of non-volatile storage, like a flash EEPROM. You then need to
determine whether the flash access time is fast enough to allow you to
run the program directly out of it, or whether you need faster program
memory, either by using BRAMs and banking or perhaps by adding
external SRAM/SDRAM/DDR SDRAM.

-a
From: weldat on
>On Mar 12, 5:36=A0am, "weldat" <gweleki...(a)gmail.com> wrote:
>> =A0Hi all;
>> may someone explain to me how to add memory to store my microBlaze
progra=
>m
>> if my system is out of memory?
>> thank you in advance
>
>I assume that "by out of memory," you mean that you do not have enough
>BRAMs to store the program. If so, then you need to provide some kind
>of non-volatile storage, like a flash EEPROM. You then need to
>determine whether the flash access time is fast enough to allow you to
>run the program directly out of it, or whether you need faster program
>memory, either by using BRAMs and banking or perhaps by adding
>external SRAM/SDRAM/DDR SDRAM.
>
>-a
>
hi
i got this message
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
region ilmb_cntlr_dlmb_cntlr is full (TestApp_Memory/executable.elf section
..text)
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
region ilmb_cntlr_dlmb_cntlr is full (TestApp_Memory/executable.elf section
..stack)
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .init [00000050 -> 00000077] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .fini [00000078 -> 00000097] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .rodata [00000098 -> 000007ef] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .data [000007f0 -> 00000d33] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .ctors [00000d34 -> 00000d3b] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .dtors [00000d3c -> 00000d43] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .eh_frame [00000d44 -> 00000d47] overlaps section .text [00000050
-> 00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .jcr [00000d48 -> 00000d4b] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .bss [00000d50 -> 00001bff] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .heap [00001c00 -> 00001fff] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
section .stack [00002000 -> 000023ff] overlaps section .text [00000050 ->
00012d2f]
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
TestApp_Memory/executable.elf: section .text lma 0x50 overlaps previous
sections
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
TestApp_Memory/executable.elf: section .fini lma 0x78 overlaps previous
sections
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
TestApp_Memory/executable.elf: section .rodata lma 0x98 overlaps previous
sections
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
TestApp_Memory/executable.elf: section .data lma 0x7f0 overlaps previous
sections
/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/m/crtend.o:(.init+0x0):
relocation truncated to fit: R_MICROBLAZE_32_PCREL_LO against `.text'
collect2: ld returned 1 exit status
make: *** [TestApp_Memory/executable.elf] Error 1

---------------------------------------
Posted through http://www.FPGARelated.com
From: Brian Drummond on
On Mon, 15 Mar 2010 02:07:47 -0500, "weldat"
<gwelekiros(a)n_o_s_p_a_m.n_o_s_p_a_m.gmail.com> wrote:

>>On Mar 12, 5:36=A0am, "weldat" <gweleki...(a)gmail.com> wrote:
>>> =A0Hi all;
>>> may someone explain to me how to add memory to store my microBlaze
>progra=
>>m
>>> if my system is out of memory?
>>> thank you in advance
>>
>>I assume that "by out of memory," you mean that you do not have enough
>>BRAMs to store the program. If so, then you need to provide some kind
>>of non-volatile storage, like a flash EEPROM. You then need to
>>determine whether the flash access time is fast enough to allow you to
>>run the program directly out of it, or whether you need faster program
>>memory, either by using BRAMs and banking or perhaps by adding
>>external SRAM/SDRAM/DDR SDRAM.
>>
>>-a
>>
>hi
>i got this message
....
>/cygdrive/c/Xilinx/10.1/EDK/gnu/microblaze/nt/bin/../lib/gcc/microblaze-xilinx-elf/4.1.1/../../../../microblaze-xilinx-elf/bin/ld.real:
>section .init [00000050 -> 00000077] overlaps section .text [00000050 ->
>00012d2f]

section .text [00000050 -> 00012d2f]

This section is somewhere over 80 kilobytes...

You need to:
(a) increase the size of the program memory - at least to 96kb - IF the FPGA has
more memory available, (you may also need to learn how to write linker scripts)

or - most likely the real problem

(b) reduce the size of the program. Look at the symbol tables and see what's
taking up so much space. Rewrite it smaller or eliminate it. For example: there
are simpler versions of "printf" - like xil_printf - that can save several kB of
memory at a stroke. If the code is cobbled together from different places it may
waste even more space by using both.
If the program uses floating point math, consider using scaled integer or fixed
point instead.

- Brian