init/fini

root joel.sherrill at OARcorp.com
Sat Sep 1 13:59:51 UTC 2001


Which CPUs use init/fini for C++ global constructors/destructors?
I see RTEMS thinks it is these:

But gcc seems to have some _fini support for these:

arm (only armulator and probably wrong)
c4x
i386
m68k
sparc

bash$ grep -l _fini */*  | cut -d'/' -f1 | sort -u
alpha
c4x
i386
m32r
m68k
m88k
rs6000
sparc

I am adding -D_USE_INIT_FINI to the predefines for gcc so
RTEMS itself won't have to deal with these flags at a BSP
level.  I would like to get some feedback before modifying
the appropriate gcc/config/*/rtems*.h files.

Thanks.

--joel



More information about the users mailing list