1 /* src/vm/jit/alpha/md-asm.h - assembler defines for Alpha ABI
3 Copyright (C) 1996-2005, 2006 R. Grafl, A. Krall, C. Kruegel,
4 C. Oates, R. Obermaisser, M. Platter, M. Probst, S. Ring,
5 E. Steiner, C. Thalinger, D. Thuernbeck, P. Tomsich, C. Ullrich,
6 J. Wenninger, Institut f. Computersprachen - TU Wien
8 This file is part of CACAO.
10 This program is free software; you can redistribute it and/or
11 modify it under the terms of the GNU General Public License as
12 published by the Free Software Foundation; either version 2, or (at
13 your option) any later version.
15 This program is distributed in the hope that it will be useful, but
16 WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
25 Contact: cacao@cacaojvm.org
27 Authors: Christian Thalinger
31 $Id: md-asm.h 4357 2006-01-22 23:33:38Z twisti $
40 /* register defines ***********************************************************/
131 /* save and restore macros ****************************************************/
133 #define SAVE_RETURN_REGISTERS(off) \
134 stq v0,(0+(off))*8(sp) ; \
135 stt fv0,(1+(off))*8(sp) ;
137 #define RESTORE_RETURN_REGISTERS(off) \
138 ldq v0,(0+(off))*8(sp) ; \
139 ldt fv0,(1+(off))*8(sp) ;
141 #define SAVE_ARGUMENT_REGISTERS(off) \
142 stq a0,(0+(off))*8(sp) ; \
143 stq a1,(1+(off))*8(sp) ; \
144 stq a2,(2+(off))*8(sp) ; \
145 stq a3,(3+(off))*8(sp) ; \
146 stq a4,(4+(off))*8(sp) ; \
147 stq a5,(5+(off))*8(sp) ; \
149 stt fa0,(6+(off))*8(sp) ; \
150 stt fa1,(7+(off))*8(sp) ; \
151 stt fa2,(8+(off))*8(sp) ; \
152 stt fa3,(9+(off))*8(sp) ; \
153 stt fa4,(10+(off))*8(sp) ; \
154 stt fa5,(11+(off))*8(sp) ;
156 #define RESTORE_ARGUMENT_REGISTERS(off) \
157 ldq a0,(0+(off))*8(sp) ; \
158 ldq a1,(1+(off))*8(sp) ; \
159 ldq a2,(2+(off))*8(sp) ; \
160 ldq a3,(3+(off))*8(sp) ; \
161 ldq a4,(4+(off))*8(sp) ; \
162 ldq a5,(5+(off))*8(sp) ; \
164 ldt fa0,(6+(off))*8(sp) ; \
165 ldt fa1,(7+(off))*8(sp) ; \
166 ldt fa2,(8+(off))*8(sp) ; \
167 ldt fa3,(9+(off))*8(sp) ; \
168 ldt fa4,(10+(off))*8(sp) ; \
169 ldt fa5,(11+(off))*8(sp) ;
171 #define SAVE_TEMPORARY_REGISTERS(off) \
172 stq t0,(0+(off))*8(sp) ; \
173 stq t1,(1+(off))*8(sp) ; \
174 stq t2,(2+(off))*8(sp) ; \
175 stq t3,(3+(off))*8(sp) ; \
176 stq t4,(4+(off))*8(sp) ; \
177 stq t5,(5+(off))*8(sp) ; \
178 stq t6,(6+(off))*8(sp) ; \
179 stq t7,(7+(off))*8(sp) ; \
180 stq t8,(8+(off))*8(sp) ; \
181 stq t9,(9+(off))*8(sp) ; \
182 stq t10,(10+(off))*8(sp) ; \
184 stt ft0,(11+(off))*8(sp) ; \
185 stt ft1,(12+(off))*8(sp) ; \
186 stt ft2,(13+(off))*8(sp) ; \
187 stt ft3,(14+(off))*8(sp) ; \
188 stt ft4,(15+(off))*8(sp) ; \
189 stt ft5,(16+(off))*8(sp) ; \
190 stt ft6,(17+(off))*8(sp) ; \
191 stt ft7,(18+(off))*8(sp) ; \
192 stt ft8,(19+(off))*8(sp) ; \
193 stt ft9,(20+(off))*8(sp) ; \
194 stt ft10,(21+(off))*8(sp) ; \
195 stt ft11,(22+(off))*8(sp) ; \
196 stt ft12,(23+(off))*8(sp) ;
199 #define RESTORE_TEMPORARY_REGISTERS(off) \
200 ldq t0,(0+(off))*8(sp) ; \
201 ldq t1,(1+(off))*8(sp) ; \
202 ldq t2,(2+(off))*8(sp) ; \
203 ldq t3,(3+(off))*8(sp) ; \
204 ldq t4,(4+(off))*8(sp) ; \
205 ldq t5,(5+(off))*8(sp) ; \
206 ldq t6,(6+(off))*8(sp) ; \
207 ldq t7,(7+(off))*8(sp) ; \
208 ldq t8,(8+(off))*8(sp) ; \
209 ldq t9,(9+(off))*8(sp) ; \
210 ldq t10,(10+(off))*8(sp) ; \
212 ldt ft0,(11+(off))*8(sp) ; \
213 ldt ft1,(12+(off))*8(sp) ; \
214 ldt ft2,(13+(off))*8(sp) ; \
215 ldt ft3,(14+(off))*8(sp) ; \
216 ldt ft4,(15+(off))*8(sp) ; \
217 ldt ft5,(16+(off))*8(sp) ; \
218 ldt ft6,(17+(off))*8(sp) ; \
219 ldt ft7,(18+(off))*8(sp) ; \
220 ldt ft8,(19+(off))*8(sp) ; \
221 ldt ft9,(20+(off))*8(sp) ; \
222 ldt ft10,(21+(off))*8(sp) ; \
223 ldt ft11,(22+(off))*8(sp) ; \
224 ldt ft12,(23+(off))*8(sp) ;
226 #endif /* _MD_ASM_H */
230 * These are local overrides for various environment variables in Emacs.
231 * Please do not remove this and leave it at the end of the file, where
232 * Emacs will automagically detect them.
233 * ---------------------------------------------------------------------
236 * indent-tabs-mode: t