1 //*****************************************************************************
\r
3 // asmdefs.h - Macros to allow assembly code be portable among toolchains.
\r
5 // Copyright (c) 2005,2006 Luminary Micro, Inc. All rights reserved.
\r
7 // Software License Agreement
\r
9 // Luminary Micro, Inc. (LMI) is supplying this software for use solely and
\r
10 // exclusively on LMI's Stellaris Family of microcontroller products.
\r
12 // The software is owned by LMI and/or its suppliers, and is protected under
\r
13 // applicable copyright laws. All rights are reserved. Any use in violation
\r
14 // of the foregoing restrictions may subject the user to criminal sanctions
\r
15 // under applicable laws, as well as to civil liability for the breach of the
\r
16 // terms and conditions of this license.
\r
18 // THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED
\r
19 // OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
\r
20 // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE.
\r
21 // LMI SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR
\r
22 // CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
\r
24 // This is part of revision 635 of the Stellaris Driver Library.
\r
26 //*****************************************************************************
\r
28 #ifndef __ASMDEFS_H__
\r
29 #define __ASMDEFS_H__
\r
31 //*****************************************************************************
\r
33 // The defines required for EW-ARM.
\r
35 //*****************************************************************************
\r
41 #define __TEXT__ rseg CODE:CODE(2)
\r
42 #define __DATA__ rseg DATA:DATA(2)
\r
43 #define __BSS__ rseg DATA:DATA(2)
\r
46 // Assembler nmenonics.
\r
48 #define __ALIGN__ alignrom 4
\r
50 #define __EXPORT__ export
\r
51 #define __IMPORT__ import
\r
54 #define __THUMB_LABEL__
\r
55 #define __WORD__ dcd
\r
59 //*****************************************************************************
\r
61 // The defines required for GCC.
\r
63 //*****************************************************************************
\r
67 // The assembly code preamble required to put the assembler into the correct
\r
76 #define __TEXT__ .text
\r
77 #define __DATA__ .data
\r
78 #define __BSS__ .bss
\r
81 // Assembler nmenonics.
\r
83 #define __ALIGN__ .balign 4
\r
84 #define __END__ .end
\r
85 #define __EXPORT__ .globl
\r
86 #define __IMPORT__ .extern
\r
88 #define __STR__ .ascii
\r
89 #define __THUMB_LABEL__ .thumb_func
\r
90 #define __WORD__ .word
\r
94 //*****************************************************************************
\r
96 // The defines required for RV-MDK.
\r
98 //*****************************************************************************
\r
102 // The assembly code preamble required to put the assembler into the correct
\r
110 // Section headers.
\r
112 #define __TEXT__ area ||.text||, code, readonly, align=2
\r
113 #define __DATA__ area ||.data||, data, align=2
\r
114 #define __BSS__ area ||.bss||, noinit, align=2
\r
117 // Assembler nmenonics.
\r
119 #define __ALIGN__ align 4
\r
120 #define __END__ end
\r
121 #define __EXPORT__ export
\r
122 #define __IMPORT__ import
\r
124 #define __STR__ dcb
\r
125 #define __THUMB_LABEL__
\r
126 #define __WORD__ dcd
\r
130 #endif // __ASMDEF_H__
\r