what is __eabi in main()
Michael Meissner (meissner@cygnus.com)
09 Nov 1998 1914:14:48 -0500
brendan@dgs.monash.edu.au (Brendan Simon) writes:
> I have built a powerpc cross compiler with eabi. I notice that main
> calls __eabi. It apparently sets up the eabi environment (what ever
> that means). I have seen some startup code stub the __eabi so that it
> returns straight away. Is this safe ? How important is the eabi
> environment ?
Look in gcc/config/rs6000/eabi.asm. It is the general purpose hook to
initialize things. Currently it:
1) Sets up r2 and r13 to hold the 2 small data pointers (ie, support for
the -msdata switch).
2) Relocates all pointers used if loaded at a different location than it
was linked for, providing all modules were compiled with -mrelocatable
or -mrelocatable-lib.
3) Call the C++ constructors.
Obviously in the future, it may be used for other initializations.
--
Michael Meissner, Cygnus Solutions (Massachusetts office)
4th floor, 955 Massachusetts Avenue, Cambridge, MA 02139, USA
meissner@cygnus.com, 617-354-5416 (office), 617-354-7161 (fax)
________________________________________________
To get help for the crossgcc list, send mail to
crossgcc-request@cygnus.com with the text 'help'
(without the quotes) in the body of the message.