mirror of https://github.com/proxmox/mirror_qemu
target/mips/translate: Extract DisasContext structure
Extract DisasContext to a new 'translate.h' header so different translation files (ISA, ASE, extensions) can use it. Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20201207235539.4070364-2-f4bug@amsat.org>master
parent
0dc351ca6b
commit
e31309365e
|
@ -36,6 +36,7 @@
|
||||||
#include "exec/log.h"
|
#include "exec/log.h"
|
||||||
#include "qemu/qemu-print.h"
|
#include "qemu/qemu-print.h"
|
||||||
#include "fpu_helper.h"
|
#include "fpu_helper.h"
|
||||||
|
#include "translate.h"
|
||||||
|
|
||||||
#define MIPS_DEBUG_DISAS 0
|
#define MIPS_DEBUG_DISAS 0
|
||||||
|
|
||||||
|
@ -2554,43 +2555,6 @@ static TCGv mxu_CR;
|
||||||
tcg_temp_free_i32(helper_tmp); \
|
tcg_temp_free_i32(helper_tmp); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
typedef struct DisasContext {
|
|
||||||
DisasContextBase base;
|
|
||||||
target_ulong saved_pc;
|
|
||||||
target_ulong page_start;
|
|
||||||
uint32_t opcode;
|
|
||||||
uint64_t insn_flags;
|
|
||||||
int32_t CP0_Config1;
|
|
||||||
int32_t CP0_Config2;
|
|
||||||
int32_t CP0_Config3;
|
|
||||||
int32_t CP0_Config5;
|
|
||||||
/* Routine used to access memory */
|
|
||||||
int mem_idx;
|
|
||||||
MemOp default_tcg_memop_mask;
|
|
||||||
uint32_t hflags, saved_hflags;
|
|
||||||
target_ulong btarget;
|
|
||||||
bool ulri;
|
|
||||||
int kscrexist;
|
|
||||||
bool rxi;
|
|
||||||
int ie;
|
|
||||||
bool bi;
|
|
||||||
bool bp;
|
|
||||||
uint64_t PAMask;
|
|
||||||
bool mvh;
|
|
||||||
bool eva;
|
|
||||||
bool sc;
|
|
||||||
int CP0_LLAddr_shift;
|
|
||||||
bool ps;
|
|
||||||
bool vp;
|
|
||||||
bool cmgcr;
|
|
||||||
bool mrp;
|
|
||||||
bool nan2008;
|
|
||||||
bool abs2008;
|
|
||||||
bool saar;
|
|
||||||
bool mi;
|
|
||||||
int gi;
|
|
||||||
} DisasContext;
|
|
||||||
|
|
||||||
#define DISAS_STOP DISAS_TARGET_0
|
#define DISAS_STOP DISAS_TARGET_0
|
||||||
#define DISAS_EXIT DISAS_TARGET_1
|
#define DISAS_EXIT DISAS_TARGET_1
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,50 @@
|
||||||
|
/*
|
||||||
|
* MIPS translation routines.
|
||||||
|
*
|
||||||
|
* Copyright (c) 2004-2005 Jocelyn Mayer
|
||||||
|
*
|
||||||
|
* SPDX-License-Identifier: LGPL-2.1-or-later
|
||||||
|
*/
|
||||||
|
#ifndef TARGET_MIPS_TRANSLATE_H
|
||||||
|
#define TARGET_MIPS_TRANSLATE_H
|
||||||
|
|
||||||
|
#include "exec/translator.h"
|
||||||
|
|
||||||
|
typedef struct DisasContext {
|
||||||
|
DisasContextBase base;
|
||||||
|
target_ulong saved_pc;
|
||||||
|
target_ulong page_start;
|
||||||
|
uint32_t opcode;
|
||||||
|
uint64_t insn_flags;
|
||||||
|
int32_t CP0_Config1;
|
||||||
|
int32_t CP0_Config2;
|
||||||
|
int32_t CP0_Config3;
|
||||||
|
int32_t CP0_Config5;
|
||||||
|
/* Routine used to access memory */
|
||||||
|
int mem_idx;
|
||||||
|
MemOp default_tcg_memop_mask;
|
||||||
|
uint32_t hflags, saved_hflags;
|
||||||
|
target_ulong btarget;
|
||||||
|
bool ulri;
|
||||||
|
int kscrexist;
|
||||||
|
bool rxi;
|
||||||
|
int ie;
|
||||||
|
bool bi;
|
||||||
|
bool bp;
|
||||||
|
uint64_t PAMask;
|
||||||
|
bool mvh;
|
||||||
|
bool eva;
|
||||||
|
bool sc;
|
||||||
|
int CP0_LLAddr_shift;
|
||||||
|
bool ps;
|
||||||
|
bool vp;
|
||||||
|
bool cmgcr;
|
||||||
|
bool mrp;
|
||||||
|
bool nan2008;
|
||||||
|
bool abs2008;
|
||||||
|
bool saar;
|
||||||
|
bool mi;
|
||||||
|
int gi;
|
||||||
|
} DisasContext;
|
||||||
|
|
||||||
|
#endif
|
Loading…
Reference in New Issue