This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Configtool building and code size


> The reason I built the configtool is to try to get the code size down for
> OpenRISC implementation.

The CLI based tool is just as good for such optimizations.

> My really simple program:
> 
> <hello.c>
> int my_bss;
> int my_data = 2;
> const int my_rodata = 4;
> 
> int main(int argc, char **argv)
> {
>    int i = 1;
>    int j = 2;
>    return i + j;
> }
> </hello.c>
> 
> built with:
> 
> or32-elf-gcc -g -I../install/include hello.c -L../install/lib -o
> hello -Ttarget.ld -nostdlib
> 
> ends up this big:
> 
>    text	   data	    bss	    dec	    hex	filename
>   82440	   2632	  14832	  99904	  18640	hello

Well, for this application all you really need is the HAL. So rename
main to cyg_start, and do

ecosconfig new openrisc minimal
ecosconfig tree
make

etc.

You should really be asking yourself the question "What do i require
from eCos for my application". Once you know that, you can decide
which packages to include and which to leave out.

        Andrew


-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]