2 * OpenRISC execution defines
4 * Copyright (c) 2009 Stuart Brady <stuart.brady@gmail.com>
5 * Copyright (c) 2009 Laurent Desnogues
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version.
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Library General Public License for more details.
17 * You should have received a copy of the GNU Library General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA
22 #include "dyngen-exec.h"
24 register struct CPUOpenRISCState
*env
asm(AREG0
);
30 static inline void env_to_regs(void)
35 static inline void regs_to_env(void)
39 static inline int cpu_has_work(CPUState
*env
)
41 return env
->interrupt_request
& (CPU_INTERRUPT_HARD
| CPU_INTERRUPT_TIMER
);
44 static inline int cpu_halted(CPUState
*env
)
49 if (cpu_has_work(env
)) {
56 #if !defined(CONFIG_USER_ONLY)
57 #include "softmmu_exec.h"