summaryrefslogtreecommitdiff
path: root/runtime.S
diff options
context:
space:
mode:
authorMike Pavone <pavone@retrodev.com>2013-01-06 21:42:57 -0800
committerMike Pavone <pavone@retrodev.com>2013-01-06 21:42:57 -0800
commitbb95ed38345859df9ac367c166c46a56e6f752e1 (patch)
tree092ef0cb63998ec194a5a8d431dd9faab966fee3 /runtime.S
parent81e14475cee68cf26901057acd5cb318abd854ee (diff)
Print a message when we try to run an invalid instruction, not when we try to translate it
Diffstat (limited to 'runtime.S')
-rw-r--r--runtime.S12
1 files changed, 12 insertions, 0 deletions
diff --git a/runtime.S b/runtime.S
index 140241f..73a09bf 100644
--- a/runtime.S
+++ b/runtime.S
@@ -88,6 +88,18 @@ already_supervisor_trap:
call m68k_native_addr_and_sync
add $24, %eax
jmp *%rcx
+
+invalid_msg:
+ .asciz "Invalid instruction at %X\n"
+
+ .global m68k_invalid
+m68k_invalid:
+ lea invalid_msg(%rip), %rdi
+ mov %ecx, %esi
+ xor %rax, %rax
+ call printf
+ mov $1, %rdi
+ call exit
int_dbg_msg:
.asciz "Executing Interrupt!"