Program size - Microblaze

Aug 28, 2007 6 Replies

Hi,



I want to know the average size of the programs for microblaze (Xilkernel, Uart managment, SRAM managment, Ethernet with Lwip). I think that the size of my program is enormous. Even if i choose optimization in compiler option, the program size is too big.



My Progam size : 900 ko (My Code, Xilkernel without Lwip)



Size of executable.elf


Microblaze OPB | - SRAM Controller | - Ethernet Lite | - UART Lite | - UART 16550 | - Timer | - Interrupt controller | - IPIF with 3 interrupt



Thank you. Best regards.


Yannick

?

I presume this is supposed to say 900KBytes? How are you obtaining this figure? Are you looking at the raw binary, or some other format such as elf or hex?

Regards, Richard. + http://www.FreeRTOS.org A free real time kernel for 8, 16 and 32bit systems. + http://www.SafeRTOS.com An IEC 61508 certified real time kernel for safety related systems.

That's sort of like asking "How long is a piece of string?"

My guess is that it will be somewhere between several kilobytes and a couple of megabytes. Give or take.

G.

Which would make the average about 1 megabyte. :-)

Chuck F (cbfalconer at maineline dot net) Available for consulting/temporary embedded and systems.

executable.elf is not only program instructions and initialized data. Research what all an ELF file contains.

Dan Henry

Depends on the distribution. A million 7-Kb programs and one 2-Mb program will have an average[1] size of slightly over 7 Kb.

Phil

[1] Well, mean. Mode and median are exactly 7Kb.
Philip Potter pgp doc.ic.ac.uk

On MicroBlaze, a lot of the standard library functions can swell the executable massively. For example, don't use printf() if you can avoid it - use the slimline xil_printf() instead.

Phil

Philip Potter pgp doc.ic.ac.uk

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required