Hi, I cross-compiled GCC 4.6.3 and binutil 2.22 for microblaze and I came into a problem, the constructors table is not sorted by priority, actually the priority seem to be gone. I have added this template in the linker script: .ctors : { __CTOR_LIST__ = .; ___CTORS_LIST___ = .; KEEP (*crtbegin.o(.ctors)) KEEP (*(EXCLUDE_FILE(*crtend.o) .ctors)) KEEP (*(SORT(.ctors.*))) KEEP (*(.ctors)) __CTOR_END__ = .; ___CTORS_END___ = .; } > _region_ .dtors : { __DTOR_LIST__ = .; ___DTORS_LIST___ = .; KEEP (*crtbegin.o(.dtors)) KEEP (*(EXCLUDE_FILE(*crtend.o) .dtors)) KEEP (*(SORT(.dtors.*))) KEEP (*(.dtors)) __DTOR_END__ = .; ___DTORS_END___ = .; } > _region_ The result of the constructor section is the following: .ctors 0x0000000090092008 0x64 0x0000000090092008 __CTOR_LIST__ = . 0x0000000090092008 ___CTORS_LIST___ = . *crtbegin.o(.ctors) *(EXCLUDE_FILE(*crtend.o) .ctors) .ctors 0x0000000090092008 0x10 /tmp/ecos/spartan3adsp_net/install/lib/extras.o .ctors 0x0000000090092018 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(infra_diag.o) .ctors 0x000000009009201c 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(kernel_kapi.o) .ctors 0x0000000090092020 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(kernel_thread.o) .ctors 0x0000000090092024 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(kernel_except.o) .ctors 0x0000000090092028 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(kernel_intr.o) .ctors 0x000000009009202c 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(kernel_sched.o) .ctors 0x0000000090092030 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(compat_posix_pthread.o) .ctors 0x0000000090092034 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(compat_posix_time.o) .ctors 0x0000000090092038 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(compat_posix_signal.o) .ctors 0x000000009009203c 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(io_wallclock_wallclock.o) .ctors 0x0000000090092040 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(io_fileio_fd.o) .ctors 0x0000000090092044 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(io_fileio_select.o) .ctors 0x0000000090092048 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(net_bsd_tcpip_init.o) .ctors 0x000000009009204c 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(kernel_clock.o) .ctors 0x0000000090092050 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(services_memalloc_common_kapi.o) .ctors 0x0000000090092054 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(services_memalloc_common_heaps.o) .ctors 0x0000000090092058 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(language_c_libc_stdio_stderr.o) .ctors 0x000000009009205c 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(language_c_libc_stdio_stdin.o) .ctors 0x0000000090092060 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(language_c_libc_stdio_stdiofiles.o) .ctors 0x0000000090092064 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(language_c_libc_stdio_stdout.o) .ctors 0x0000000090092068 0x4 /tmp/ecos/spartan3adsp_net/install/lib/libtarget.a(io_fileio_socket.o) *(SORT(.ctors.*)) *(.ctors) 0x000000009009206c __CTOR_END__ = . 0x000000009009206c ___CTORS_END__ With a similar application compiled with powerpc-eabi - GCC 4.5 / binutil 2.20 I get a list sorted differently, also some priority number are attached to each entry which is not the case for microblaze. *(SORT(.ctors*)) .ctors.07535 0x00150680 0x4 /tmp/ecos/mpc8572ds_net/install/lib/extras.o .ctors.07535 0x00150684 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(compat_posix_pthread.o) .ctors.07535 0x00150688 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(compat_posix_time.o) .ctors.07535 0x0015068c 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(compat_posix_signal.o) .ctors.09435 0x00150690 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(net_bsd_tcpip_init.o) .ctors.09533 0x00150694 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(language_c_libc_stdio_stderr.o) .ctors.09534 0x00150698 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(language_c_libc_stdio_stdout.o) .ctors.09535 0x0015069c 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(language_c_libc_stdio_stdin.o) .ctors.09535 0x001506a0 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(language_c_libc_stdio_stdiofiles.o) .ctors.15535 0x001506a4 0x8 /tmp/ecos/mpc8572ds_net/install/lib/extras.o .ctors.15535 0x001506ac 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(io_fileio_fd.o) .ctors.15535 0x001506b0 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(io_fileio_select.o) .ctors.15535 0x001506b4 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(io_fileio_socket.o) .ctors.16535 0x001506b8 0x4 /tmp/ecos/mpc8572ds_net/install/lib/extras.o .ctors.29535 0x001506bc 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(io_wallclock_wallclock.o) .ctors.45635 0x001506c0 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(services_memalloc_common_heaps.o) .ctors.51535 0x001506c4 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(kernel_clock.o) .ctors.53535 0x001506c8 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(kernel_except.o) .ctors.53535 0x001506cc 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(kernel_intr.o) .ctors.54435 0x001506d0 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(kernel_thread.o) .ctors.54535 0x001506d4 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(kernel_sched.o) .ctors.55435 0x001506d8 0x4 /tmp/ecos/mpc8572ds_net/install/lib/libtarget.a(infra_diag.o) Has anyone tips to get the constructor priority to work with microblaze compiler/linker? Thanks, Christophe GCC configuration: .configure --target=$TARGET --prefix=/tmp/gnutools/$TARGET --with-newlib --with-gnu-as --with-gnu-ld --enable-languages=c,c++ --enable-threads --disable-hosted-libstdcxx --disable-__cxa_atexit Binutil configuration: configure --target=$TARGET --prefix=/tmp/gnutools/$TARGET