root / target-cris / exec.h @ d78f3995
History | View | Annotate | Download (1.5 kB)
1 | 81fdc5f8 | ths | /*
|
---|---|---|---|
2 | 81fdc5f8 | ths | * CRIS execution defines
|
3 | 81fdc5f8 | ths | *
|
4 | 81fdc5f8 | ths | * Copyright (c) 2007 AXIS Communications AB
|
5 | 81fdc5f8 | ths | * Written by Edgar E. Iglesias
|
6 | 81fdc5f8 | ths | *
|
7 | 81fdc5f8 | ths | * This library is free software; you can redistribute it and/or
|
8 | 81fdc5f8 | ths | * modify it under the terms of the GNU Lesser General Public
|
9 | 81fdc5f8 | ths | * License as published by the Free Software Foundation; either
|
10 | 81fdc5f8 | ths | * version 2 of the License, or (at your option) any later version.
|
11 | 81fdc5f8 | ths | *
|
12 | 81fdc5f8 | ths | * This library is distributed in the hope that it will be useful,
|
13 | 81fdc5f8 | ths | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
14 | 81fdc5f8 | ths | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
15 | 81fdc5f8 | ths | * General Public License for more details.
|
16 | 81fdc5f8 | ths | *
|
17 | 81fdc5f8 | ths | * You should have received a copy of the GNU Lesser General Public
|
18 | 81fdc5f8 | ths | * License along with this library; if not, write to the Free Software
|
19 | fad6cb1a | aurel32 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA
|
20 | 81fdc5f8 | ths | */
|
21 | 81fdc5f8 | ths | #include "dyngen-exec.h" |
22 | 81fdc5f8 | ths | |
23 | 81fdc5f8 | ths | register struct CPUCRISState *env asm(AREG0); |
24 | 31c18d87 | edgar_igl | |
25 | 81fdc5f8 | ths | #include "cpu.h" |
26 | 81fdc5f8 | ths | #include "exec-all.h" |
27 | 81fdc5f8 | ths | |
28 | 81fdc5f8 | ths | static inline void env_to_regs(void) |
29 | 81fdc5f8 | ths | { |
30 | 81fdc5f8 | ths | } |
31 | 81fdc5f8 | ths | |
32 | 81fdc5f8 | ths | static inline void regs_to_env(void) |
33 | 81fdc5f8 | ths | { |
34 | 81fdc5f8 | ths | } |
35 | 81fdc5f8 | ths | |
36 | 81fdc5f8 | ths | #if !defined(CONFIG_USER_ONLY)
|
37 | 81fdc5f8 | ths | #include "softmmu_exec.h" |
38 | 81fdc5f8 | ths | #endif
|
39 | 81fdc5f8 | ths | |
40 | 81fdc5f8 | ths | void cpu_cris_flush_flags(CPUCRISState *env, int cc_op); |
41 | 81fdc5f8 | ths | void helper_movec(CPUCRISState *env, int reg, uint32_t val); |
42 | 81fdc5f8 | ths | |
43 | 81fdc5f8 | ths | static inline int cpu_halted(CPUState *env) { |
44 | 81fdc5f8 | ths | if (!env->halted)
|
45 | 81fdc5f8 | ths | return 0; |
46 | 69b5cae1 | edgar_igl | |
47 | 69b5cae1 | edgar_igl | /* IRQ, NMI and GURU execeptions wakes us up. */
|
48 | 69b5cae1 | edgar_igl | if (env->interrupt_request
|
49 | 69b5cae1 | edgar_igl | & (CPU_INTERRUPT_HARD | CPU_INTERRUPT_NMI)) { |
50 | 81fdc5f8 | ths | env->halted = 0;
|
51 | 81fdc5f8 | ths | return 0; |
52 | 81fdc5f8 | ths | } |
53 | 81fdc5f8 | ths | return EXCP_HALTED;
|
54 | 81fdc5f8 | ths | } |