qxl: factor out properties
[qemu/opensuse.git] / dyngen-exec.h
blobfbde29ea014edc990c308c6ee615ac7f9726b9e5
1 /*
2 * dyngen defines for micro operation code
4 * Copyright (c) 2003 Fabrice Bellard
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, see <http://www.gnu.org/licenses/>.
19 #if !defined(__DYNGEN_EXEC_H__)
20 #define __DYNGEN_EXEC_H__
22 #if defined(__i386__)
23 #define AREG0 "ebp"
24 #elif defined(__x86_64__)
25 #define AREG0 "r14"
26 #elif defined(_ARCH_PPC)
27 #define AREG0 "r27"
28 #elif defined(__arm__)
29 #define AREG0 "r7"
30 #elif defined(__hppa__)
31 #define AREG0 "r17"
32 #elif defined(__mips__)
33 #define AREG0 "s0"
34 #elif defined(__sparc__)
35 #ifdef CONFIG_SOLARIS
36 #define AREG0 "g2"
37 #else
38 #ifdef __sparc_v9__
39 #define AREG0 "g5"
40 #else
41 #define AREG0 "g6"
42 #endif
43 #endif
44 #elif defined(__s390__)
45 #define AREG0 "r10"
46 #elif defined(__alpha__)
47 /* Note $15 is the frame pointer, so anything in op-i386.c that would
48 require a frame pointer, like alloca, would probably loose. */
49 #define AREG0 "$15"
50 #elif defined(__mc68000)
51 #define AREG0 "%a5"
52 #elif defined(__ia64__)
53 #define AREG0 "r7"
54 #else
55 #error unsupported CPU
56 #endif
58 register CPUState *env asm(AREG0);
60 #endif /* !defined(__DYNGEN_EXEC_H__) */