diff m68k_core_x86.c @ 986:f680fe746a7d

Implement illegal instruction trap
author Michael Pavone <pavone@retrodev.com>
date Tue, 26 Apr 2016 00:07:15 -0700
parents 751280fb4494
children 1f09994e92c5
line wrap: on
line diff
--- a/m68k_core_x86.c	Sun Apr 24 21:23:28 2016 -0700
+++ b/m68k_core_x86.c	Tue Apr 26 00:07:15 2016 -0700
@@ -1388,21 +1388,6 @@
 	m68k_save_result(inst, opts);
 }
 
-void translate_m68k_invalid(m68k_options *opts, m68kinst *inst)
-{
-	code_info *code = &opts->gen.code;
-	if (inst->src.params.immed == 0x7100) {
-		retn(code);
-		return;
-	}
-	mov_ir(code, (int64_t)stderr, RDI, SZ_PTR);
-	mov_ir(code, (int64_t)"Invalid instruction at %X\n", RSI, SZ_PTR);
-	mov_ir(code, inst->address, RDX, SZ_D);
-	call_args_abi(code, (code_ptr)fprintf, 3, RDI, RSI, RDX);
-	mov_ir(code, 1, RDI, SZ_D);
-	call_args(code, (code_ptr)exit, 1, RDI);
-}
-
 void translate_m68k_abcd_sbcd(m68k_options *opts, m68kinst *inst, host_ea *src_op, host_ea *dst_op)
 {
 	code_info *code = &opts->gen.code;
@@ -1983,13 +1968,6 @@
 	}
 }
 
-void translate_m68k_illegal(m68k_options *opts, m68kinst *inst)
-{
-	code_info *code = &opts->gen.code;
-	call(code, opts->gen.save_context);
-	call_args(code, (code_ptr)print_regs_exit, 1, opts->gen.context_reg);
-}
-
 #define BIT_SUPERVISOR 5
 
 void translate_m68k_andi_ori_ccr_sr(m68k_options *opts, m68kinst *inst)