Reducing firmware code size by using more ROM symbols
Posted: Thu Jun 04, 2015 9:24 am
Moin,
I am trying to reduce the size for linked firmware to have more room for application code
and file system.
I saw that symbols like __udivsi3 and __udivdi3 are used from libgcc.a and I would like
to replace them by a reference to the firmware routines:
I can't get the linker to use them!
I know that PROVIDE has a lower priority than command line arguments and so I tried with an explicit
symbol in linker script without success.
Any idea how to make the linker use the ROM firmware symbol?
On another system we used small assembler stubs for this but the variant I can think of
would at least waste about 12 bytes per function for nothing.
Any idea?
Cal
I am trying to reduce the size for linked firmware to have more room for application code
and file system.
I saw that symbols like __udivsi3 and __udivdi3 are used from libgcc.a and I would like
to replace them by a reference to the firmware routines:
Code: Select all
ld/eagle.rom.addr.v6.ld:PROVIDE ( __udivdi3 = 0x4000d310 );
ld/eagle.rom.addr.v6.ld:PROVIDE ( __udivsi3 = 0x4000e21c );
I can't get the linker to use them!
I know that PROVIDE has a lower priority than command line arguments and so I tried with an explicit
symbol in linker script without success.
Any idea how to make the linker use the ROM firmware symbol?
On another system we used small assembler stubs for this but the variant I can think of
would at least waste about 12 bytes per function for nothing.
Any idea?
Cal