Go to the documentation of this file.
41 #ifndef _COMPILLER_ARCH_H_
42 #define _COMPILLER_ARCH_H_ 1
44 #ifndef iSCHEDULER_TYPE
45 #define iSCHEDULER_TYPE -1
65 #define naked_func __attribute__((noreturn))
71 #define TH_MODE __THUMBEL__
73 #define ARM_MODE_MUL_CONST (65536-65535*(TH_MODE != 0))
75 #define portARM_SWI(SWI_NUMBER) asm volatile( \
76 "swi %[swi_num] @ syscall SWI_NUMBER" \
78 :[swi_num] "I" (SWI_NUMBER))
80 #if (iSCHEDULER_TYPE == iPREEMPETIVE_SCHEDULER)
81 #define irq_func_decl naked_func //must be RTOS prolog and epilor functions for irq
83 #define irq_func_decl __attribute__ ((interrupt ("IRQ"))) //use common irq sheme
91 #if defined(__CC_ARM) && defined(__arm__) && defined(__ARMCC_VERSION) && defined(__EDG_VERSION__)
92 #define portARM_SWI(SWI_NUMBER) __asm {SVC (SWI_NUMBER);}
93 #if defined(__thumb___)
94 #define ARM_MODE_MUL_CONST 1
96 #define ARM_MODE_MUL_CONST 65536
101 #define naked_func // __declspec(noreturn)
102 #if (iSCHEDULER_TYPE == iPREEMPETIVE_SCHEDULER)
103 #define irq_func_decl naked_func //must be RTOS prolog and epilor functions for irq
105 #define irq_func_decl __irq //use common irq sheme
108 #define irq_func irq_func_decl // then using function itself