This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
C Preprocessing Directive in assembler
- From: "twomol" <twomol at bj1860 dot net>
- To: ecos-discuss at sources dot redhat dot com <ecos-discuss at sources dot redhat dot com>
- Date: Wed, 10 Nov 2004 11:56:1 +0800
- Subject: [ECOS] C Preprocessing Directive in assembler
hello
I'm a new guy to ecos,when I read the source of ecos ,I was puzzled.For example,
the vector.s in the hal\arm\arch\v2_0\src directory:
#ifdef CYGSEM_HAL_ROM_RESET_USES_JUMP
// Assumption: ROM code has these vectors at the hardware reset address.
// A simple jump removes any address-space dependencies [i.e. safer]
b reset_vector // 0x00
#else
ldr pc,.reset_vector // 0x00
#endif
ldr pc,.undefined_instruction // 0x04
ldr pc,.software_interrupt // 0x08 start && software int
the "#ifdef CYGSEM_HAL_ROM_RESET_USES_JUMP" is a c/c++ language Preprocessing Directive,how dose it affect the assembler.
Thanks very very very much!
twomol
twomol@bj1860.net
2004-11-10
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss