ia64/xen-unstable

view tools/ioemu/target-i386-dm/cpu.h @ 10803:42aa63188a88

IA64-specific code for new Qemu
Due to some ia64 patches aren't checked into xen-unstable.hg.
I reversed related logic.

Signed-off-by: Zhang xiantao <xiantao.zhang@intel.com>
Signed-off-by: Christian Limpach <Christian.Limpach@xensource.com>
author chris@kneesaa.uk.xensource.com
date Wed Jul 26 13:41:10 2006 +0100 (2006-07-26)
parents b450f21472a0
children 6c975e642719
line source
1 /*
2 * i386 virtual CPU header
3 *
4 * Copyright (c) 2003 Fabrice Bellard
5 *
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.
10 *
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.
15 *
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 */
20 #ifndef CPU_I386_H
21 #define CPU_I386_H
23 #include "config.h"
25 #ifdef TARGET_X86_64
26 #define TARGET_LONG_BITS 64
27 #else
28 #define TARGET_LONG_BITS 32
29 #endif
31 /* target supports implicit self modifying code */
32 #define TARGET_HAS_SMC
33 /* support for self modifying code even if the modified instruction is
34 close to the modifying instruction */
35 #define TARGET_HAS_PRECISE_SMC
37 #include "cpu-defs.h"
39 #include "softfloat.h"
41 #if defined(__i386__) && !defined(CONFIG_SOFTMMU)
42 #define USE_CODE_COPY
43 #endif
45 #ifdef USE_X86LDOUBLE
46 typedef floatx80 CPU86_LDouble;
47 #else
48 typedef float64 CPU86_LDouble;
49 #endif
51 /* Empty for now */
52 typedef struct CPUX86State {
53 uint32_t a20_mask;
55 int interrupt_request;
57 CPU_COMMON
59 int send_event;
60 } CPUX86State;
62 CPUX86State *cpu_x86_init(void);
63 int cpu_x86_exec(CPUX86State *s);
64 void cpu_x86_close(CPUX86State *s);
65 int cpu_get_pic_interrupt(CPUX86State *s);
66 /* MSDOS compatibility mode FPU exception support */
67 void cpu_set_ferr(CPUX86State *s);
69 void cpu_x86_set_a20(CPUX86State *env, int a20_state);
71 #ifndef IN_OP_I386
72 void cpu_x86_outb(CPUX86State *env, int addr, int val);
73 void cpu_x86_outw(CPUX86State *env, int addr, int val);
74 void cpu_x86_outl(CPUX86State *env, int addr, int val);
75 int cpu_x86_inb(CPUX86State *env, int addr);
76 int cpu_x86_inw(CPUX86State *env, int addr);
77 int cpu_x86_inl(CPUX86State *env, int addr);
78 #endif
80 /* helper2.c */
81 int main_loop(void);
83 #if defined(__i386__) || defined(__x86_64__)
84 #define TARGET_PAGE_BITS 12
85 #elif defined(__ia64__)
86 #define TARGET_PAGE_BITS 14
87 #endif
88 #include "cpu-all.h"
90 #endif /* CPU_I386_H */