[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 056/111] m68k-linux-user: add '--enable-emulop'
From: |
Bryce Lanham |
Subject: |
[Qemu-devel] [PATCH 056/111] m68k-linux-user: add '--enable-emulop' |
Date: |
Wed, 17 Aug 2011 15:47:01 -0500 |
From: Laurent Vivier <address@hidden>
Allow to configure if the m68k emulator must implement
fake operation to allow returning from the emulator when
the emulator is used with the m68k-tester tool.
Signed-off-by: Laurent Vivier <address@hidden>
---
configure | 11 +++++++++++
target-m68k/cpu.h | 3 +++
target-m68k/translate.c | 10 ++++++++++
3 files changed, 24 insertions(+), 0 deletions(-)
diff --git a/configure b/configure
index 40b1fa9..23ec821 100755
--- a/configure
+++ b/configure
@@ -135,6 +135,7 @@ kvm="no"
gprof="no"
debug_tcg="no"
debug_mon="no"
+emulop="no"
debug="no"
strip_opt="yes"
bigendian="no"
@@ -582,6 +583,10 @@ for opt do
;;
--disable-debug-tcg) debug_tcg="no"
;;
+ --enable-emulop) emulop="yes"
+ ;;
+ --disable-emulop) emulop="no"
+ ;;
--enable-debug-mon) debug_mon="yes"
;;
--disable-debug-mon) debug_mon="no"
@@ -1046,6 +1051,8 @@ echo " --disable-usb-redir disable usb network
redirection support"
echo " --enable-usb-redir enable usb network redirection support"
echo " --disable-guest-agent disable building of the QEMU Guest Agent"
echo " --enable-guest-agent enable building of the QEMU Guest Agent"
+echo " --enable-emulop enable emulation tester helper"
+echo " --disable-emulop disable emulation tester helper"
echo ""
echo "NOTE: The object files are built at the place where configure is
launched"
exit 1
@@ -2684,6 +2691,7 @@ echo "host CPU $cpu"
echo "host big endian $bigendian"
echo "target list $target_list"
echo "tcg debug enabled $debug_tcg"
+echo "emulop enabled $emulop"
echo "Mon debug enabled $debug_mon"
echo "gprof enabled $gprof"
echo "sparse enabled $sparse"
@@ -3449,6 +3457,9 @@ if test ! -z "$gdb_xml_files" ; then
echo "TARGET_XML_FILES=$list" >> $config_target_mak
fi
+if test "$target_user_only" = "yes" -a "$target_arch2" = "m68k" -a "$emulop"
= "yes" ; then
+ echo "CONFIG_EMULOP=y" >> $config_target_mak
+fi
if test "$target_user_only" = "yes" -a "$bflt" = "yes"; then
echo "TARGET_HAS_BFLT=y" >> $config_target_mak
fi
diff --git a/target-m68k/cpu.h b/target-m68k/cpu.h
index 0d5e3d3..e316b1e 100644
--- a/target-m68k/cpu.h
+++ b/target-m68k/cpu.h
@@ -54,6 +54,9 @@
#define EXCP_RTE 0x100
#define EXCP_HALT_INSN 0x101
+#ifdef CONFIG_EMULOP
+#define EXCP_EXEC_RETURN 0x20000
+#endif
#define NB_MMU_MODES 2
diff --git a/target-m68k/translate.c b/target-m68k/translate.c
index f93ad02..b011a5e 100644
--- a/target-m68k/translate.c
+++ b/target-m68k/translate.c
@@ -3904,6 +3904,13 @@ DISAS_INSN(to_mext)
gen_helper_set_mac_extu(cpu_env, val, acc);
}
+#ifdef CONFIG_EMULOP
+DISAS_INSN(emulop_exec_return)
+{
+ gen_exception(s, s->pc - 2, EXCP_EXEC_RETURN);
+}
+#endif
+
static disas_proc opcode_table[65536];
static void
@@ -4173,6 +4180,9 @@ void register_m68k_insns (CPUM68KState *env)
INSN(cpushl, f428, ff38, CF_ISA_A);
INSN(wddata, fb00, ff00, CF_ISA_A);
INSN(wdebug, fbc0, ffc0, CF_ISA_A);
+#ifdef CONFIG_EMULOP
+ INSN(emulop_exec_return, 7100, ffff, M68000);
+#endif
#undef INSN
}
--
1.7.2.3
- [Qemu-devel] [PATCH 081/111] m68k: correct fpcr update, (continued)
- [Qemu-devel] [PATCH 081/111] m68k: correct fpcr update, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 063/111] m68k: some FPU debugging macros, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 066/111] m68k: add fgetexp, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 051/111] m68k: correct divs.w and divu.w, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 071/111] m68k: correct cmpa comparison datatype, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 061/111] m68k: remove useless file m68k-qreg.h, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 059/111] m68k: add m68030 definition, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 034/111] m68k: correct typo on f64_to_i32() return type., Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 052/111] m68k: correct flags with negl, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 038/111] m68k: add EA support for negx, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 056/111] m68k-linux-user: add '--enable-emulop',
Bryce Lanham <=
- [Qemu-devel] [PATCH 080/111] m68k: add fcos instruction, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 064/111] m68k: more tests, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 072/111] m68k: add flog10, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 021/111] m68k: add "byte", "word" and memory rotate., Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 078/111] m68k: add ftan instruction, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 032/111] m68k: add linkl instruction, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 036/111] m68k: correct neg condition code flags computation, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 024/111] m68k: add cas, Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 028/111] m68k: allow fpu to manage double data type., Bryce Lanham, 2011/08/17
- [Qemu-devel] [PATCH 077/111] m68k: add facos instruction, Bryce Lanham, 2011/08/17