mirror of
https://github.com/yuzu-emu/unicorn.git
synced 2024-12-23 00:45:40 +00:00
cpu: move exec-all.h inclusion out of cpu.h
exec-all.h contains TCG-specific definitions. It is not needed outside TCG-specific files such as translate.c, exec.c or *helper.c. One generic function had snuck into include/exec/exec-all.h; move it to include/qom/cpu.h. Backports commit 63c915526d6a54a95919ebece83fa9ca631b2508 from qemu
This commit is contained in:
parent
9779bff603
commit
9485b7c2e1
|
@ -20,6 +20,7 @@
|
|||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "sysemu/cpus.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/memory-internal.h"
|
||||
|
||||
/* exit the current TB from a signal handler. The host registers are
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
/* Modified for Unicorn Engine by Nguyen Anh Quynh, 2015 */
|
||||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg.h"
|
||||
#include "sysemu/sysemu.h"
|
||||
#include "exec/address-spaces.h"
|
||||
|
|
|
@ -29,8 +29,10 @@
|
|||
#include "qemu-common.h"
|
||||
#include "cpu.h"
|
||||
#include "sysemu/sysemu.h"
|
||||
#include "sysemu/cpus.h"
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
#include "qemu/thread.h"
|
||||
#include "sysemu/cpus.h"
|
||||
|
||||
#include "exec/address-spaces.h" // debug, can be removed later
|
||||
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
|
||||
#include "exec/memory-internal.h"
|
||||
#include "exec/ram_addr.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg/tcg.h"
|
||||
|
||||
#include "uc_priv.h"
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
|
||||
#include "qemu/cutils.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg.h"
|
||||
#include "hw/hw.h"
|
||||
#include "hw/qdev.h"
|
||||
|
|
|
@ -80,15 +80,7 @@ void QEMU_NORETURN cpu_loop_exit_restore(CPUState *cpu, uintptr_t pc);
|
|||
* Note that with KVM only one address space is supported.
|
||||
*/
|
||||
void cpu_address_space_init(CPUState *cpu, AddressSpace *as, int asidx);
|
||||
/**
|
||||
* cpu_get_address_space:
|
||||
* @cpu: CPU to get address space from
|
||||
* @asidx: index identifying which address space to get
|
||||
*
|
||||
* Return the requested address space of this CPU. @asidx
|
||||
* specifies which address space to read.
|
||||
*/
|
||||
AddressSpace *cpu_get_address_space(CPUState *cpu, int asidx);
|
||||
|
||||
/* cputlb.c */
|
||||
/**
|
||||
* tlb_flush_page:
|
||||
|
@ -98,7 +90,6 @@ AddressSpace *cpu_get_address_space(CPUState *cpu, int asidx);
|
|||
* Flush one page from the TLB of the specified CPU, for all
|
||||
* MMU indexes.
|
||||
*/
|
||||
|
||||
void tlb_flush_page(CPUState *cpu, target_ulong addr);
|
||||
/**
|
||||
* tlb_flush:
|
||||
|
|
|
@ -702,6 +702,16 @@ int cpu_watchpoint_remove(CPUState *cpu, vaddr addr,
|
|||
void cpu_watchpoint_remove_by_ref(CPUState *cpu, CPUWatchpoint *watchpoint);
|
||||
void cpu_watchpoint_remove_all(CPUState *cpu, int mask);
|
||||
|
||||
/**
|
||||
* cpu_get_address_space:
|
||||
* @cpu: CPU to get address space from
|
||||
* @asidx: index identifying which address space to get
|
||||
*
|
||||
* Return the requested address space of this CPU. @asidx
|
||||
* specifies which address space to read.
|
||||
*/
|
||||
AddressSpace *cpu_get_address_space(CPUState *cpu, int asidx);
|
||||
|
||||
/* Return true if PC matches an installed breakpoint. */
|
||||
static inline bool cpu_breakpoint_test(CPUState *cpu, vaddr pc, int mask)
|
||||
{
|
||||
|
|
|
@ -16,17 +16,17 @@
|
|||
/* Modified for Unicorn Engine by Nguyen Anh Quynh, 2015 */
|
||||
|
||||
#include "qemu/osdep.h"
|
||||
#include "qapi/error.h"
|
||||
#include "qemu-common.h"
|
||||
#include "cpu.h"
|
||||
#include "qapi/error.h"
|
||||
#include "qemu-common.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/memory.h"
|
||||
#include "exec/address-spaces.h"
|
||||
#include "exec/ioport.h"
|
||||
#include "qapi/visitor.h"
|
||||
#include "qemu/bitops.h"
|
||||
#include "qom/object.h"
|
||||
#include <assert.h>
|
||||
|
||||
#include "exec/memory-internal.h"
|
||||
#include "exec/ram_addr.h"
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#ifndef ARM_LDST_H
|
||||
#define ARM_LDST_H
|
||||
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
#include "qemu/bswap.h"
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include "cpu.h"
|
||||
#include "internals.h"
|
||||
#include "qemu-common.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "qapi/qmp/qerror.h"
|
||||
#include "hw/arm/arm.h"
|
||||
#include "sysemu/sysemu.h"
|
||||
|
|
|
@ -2364,8 +2364,6 @@ static inline uint64_t *aa64_vfp_qreg(CPUARMState *env, unsigned regno)
|
|||
return &env->vfp.regs[2 * regno];
|
||||
}
|
||||
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
enum {
|
||||
QEMU_PSCI_CONDUIT_DISABLED = 0,
|
||||
QEMU_PSCI_CONDUIT_SMC = 1,
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#include "cpu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "qemu/host-utils.h"
|
||||
#include "qemu/log.h"
|
||||
#include "sysemu/sysemu.h"
|
||||
#include "qemu/bitops.h"
|
||||
#include "internals.h"
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
#include "sysemu/sysemu.h"
|
||||
#include "qemu/bitops.h"
|
||||
#include "qemu/crc32c.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
#include "arm_ldst.h"
|
||||
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "cpu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "internals.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
#define SIGNBIT (uint32_t)0x80000000
|
||||
|
|
|
@ -15,12 +15,14 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include "qemu/osdep.h"
|
||||
#include <cpu.h>
|
||||
#include <cpu-qom.h>
|
||||
#include <exec/helper-proto.h>
|
||||
#include <kvm-consts.h>
|
||||
#include <sysemu/sysemu.h>
|
||||
#include "internals.h"
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
bool arm_is_psci_call(ARMCPU *cpu, int excp_type)
|
||||
{
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "unicorn/platform.h"
|
||||
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg-op.h"
|
||||
#include "qemu/log.h"
|
||||
#include "arm_ldst.h"
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
#include "cpu.h"
|
||||
#include "internals.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg-op.h"
|
||||
#include "qemu/log.h"
|
||||
#include "qemu/bitops.h"
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/helper-proto.h"
|
||||
|
||||
#ifndef CONFIG_USER_ONLY
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include "unicorn/platform.h"
|
||||
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "sysemu/cpus.h"
|
||||
|
||||
#include "qapi/qmp/qerror.h"
|
||||
|
|
|
@ -1351,8 +1351,6 @@ void tcg_x86_init(struct uc_struct *);
|
|||
#include "hw/i386/apic.h"
|
||||
#endif
|
||||
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
static inline void cpu_get_tb_cpu_state(CPUX86State *env, target_ulong *pc,
|
||||
target_ulong *cs_base, uint32_t *flags)
|
||||
{
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "qemu/log.h"
|
||||
#include "sysemu/sysemu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
#include "cpu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "qemu/host-utils.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
#define FPU_RC_MASK 0xc00
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#ifndef CONFIG_USER_ONLY
|
||||
#include "sysemu/sysemu.h"
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "qemu/host-utils.h"
|
||||
#include "exec/helper-proto.h"
|
||||
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
#include "uc_priv.h"
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#include "cpu.h"
|
||||
#include "exec/ioport.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
#include "uc_priv.h"
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "cpu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
|
||||
void cpu_sync_bndcs_hflags(CPUX86State *env)
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
#include "cpu.h"
|
||||
#include "qemu/log.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
#include "uc_priv.h"
|
||||
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#include "cpu.h"
|
||||
#include "exec/cpu-all.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
/* Secure Virtual Machine helpers */
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
|
||||
#include "qemu/host-utils.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg-op.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
#include "exec/helper-proto.h"
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include "hw/m68k/m68k.h"
|
||||
#include "cpu.h"
|
||||
#include "qemu-common.h"
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
|
||||
static void m68k_cpu_set_pc(CPUState *cs, vaddr value)
|
||||
|
|
|
@ -282,6 +282,4 @@ static inline void cpu_get_tb_cpu_state(CPUM68KState *env, target_ulong *pc,
|
|||
| ((env->macsr >> 4) & 0xf); /* Bits 0-3 */
|
||||
}
|
||||
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
#include "exec/helper-proto.h"
|
||||
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
#if defined(CONFIG_USER_ONLY)
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg-op.h"
|
||||
#include "qemu/log.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
#include "qapi/error.h"
|
||||
#include "cpu.h"
|
||||
#include "qemu-common.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "hw/mips/mips.h"
|
||||
|
||||
|
||||
|
|
|
@ -926,8 +926,6 @@ static inline int mips_vp_active(CPUMIPSState *env)
|
|||
return 1;
|
||||
}
|
||||
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
static inline void compute_hflags(CPUMIPSState *env)
|
||||
{
|
||||
env->hflags &= ~(MIPS_HFLAG_COP1X | MIPS_HFLAG_64 | MIPS_HFLAG_CP0 |
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#include "unicorn/platform.h"
|
||||
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
enum {
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/helper-proto.h"
|
||||
|
||||
/* Data format min and max values */
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "cpu.h"
|
||||
#include "qemu/host-utils.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
/*****************************************************************************/
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg-op.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "qemu/osdep.h"
|
||||
#include "qapi/error.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "hw/sparc/sparc.h"
|
||||
|
||||
//#define DEBUG_FEATURES
|
||||
|
|
|
@ -771,6 +771,4 @@ static inline bool tb_am_enabled(int tb_flags)
|
|||
#endif
|
||||
}
|
||||
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
|
||||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "qemu/host-utils.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "sysemu/sysemu.h"
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "qemu/osdep.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
|
||||
//#define DEBUG_MMU
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
*/
|
||||
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "exec/address-spaces.h"
|
||||
|
||||
/* Sparc MMU emulation */
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
#include "cpu.h"
|
||||
#include "exec/helper-proto.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg-op.h"
|
||||
#include "exec/cpu_ldst.h"
|
||||
#include "exec/helper-gen.h"
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include "qemu/osdep.h"
|
||||
#include "qemu-common.h"
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg.h"
|
||||
#include "tcg-op.h"
|
||||
|
||||
|
|
|
@ -41,6 +41,11 @@
|
|||
#define NO_CPU_IO_DEFS
|
||||
#include "cpu.h"
|
||||
|
||||
#include "qemu/host-utils.h"
|
||||
#include "qemu/timer.h"
|
||||
#include "exec/cpu-common.h"
|
||||
#include "exec/exec-all.h"
|
||||
|
||||
#include "tcg-op.h"
|
||||
|
||||
#if UINTPTR_MAX == UINT32_MAX
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#include "qemu-common.h"
|
||||
#define NO_CPU_IO_DEFS
|
||||
#include "cpu.h"
|
||||
#include "exec/exec-all.h"
|
||||
#include "tcg.h"
|
||||
#if defined(CONFIG_USER_ONLY)
|
||||
#include "qemu.h"
|
||||
|
|
Loading…
Reference in a new issue