This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Purpose of startup files for ARM


David Mc Kenna wrote:

Hi folks,

Does anyone know what the standard startup files, excluded by using the command
-nostartfiles, are expected to do and if they are necessary?


The reason I ask is that I have a chip with no ANGEL, or similar monitor, on
board, and the startup routines included by GCC by default includes SWI calls
with codes which suggest a monitor is used.


In this case, you can write your own crt0.S. crt0.S does the following work:
initialize the hardware, e.g., the SDRAM
set the sp register to some place in the higher memory
initialize the .bss sections
copy the .data section from ROM to RAM if you're writing a rom application
call the main function


Do you have ADS or SDT documentation? There're examples on how to write crt0.S.

Best regards,
Dai Yuwen





------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]