f811485ffb
Many of the MSP430 crt functions (e.g. to initialize bss) are linked "dynamically", based on symbols defined in the program. The GNU assembler defines the symbols corresponding to the crt functions by examining the section names in the input file. If GCC has been configured with --enable-initfini-array, then .init_array and .fini_array will hold pointers to global constructors/destructors. These sections can also hold functions that need to be executed for other purposes. The attached patch puts the __crt0_run_{preinit,init,fini}_array and __crt0_run_array functions in their own object files, so they will only be linked when needed. Successfully regtested the DejaGNU GCC testsuite using the binutils and newlib changes together with GCC trunk configured with --enable-initfini-array. |
||
---|---|---|
.. | ||
Makefile.in | ||
cio.S | ||
cio.h | ||
ciosyscalls.S | ||
configure | ||
configure.in | ||
crt0.S | ||
crt_bss.S | ||
crtn.S | ||
gcrt0.S | ||
intr_vectors.ld | ||
memmodel.h | ||
msp430-sim.ld | ||
msp430xl-sim.ld | ||
sbrk.c | ||
syscalls.S | ||
unlink.c | ||
write.c |