# HG changeset patch # User Mike Pavone # Date 1367223264 25200 # Node ID 4a7ac10ac2d98fe0c00e75118fc7c5181f87f7f9 # Parent 5f1b68cecfc7f112792adb7c2570e132d3999e63 Fix target cycle count after 68K interrupt diff -r 5f1b68cecfc7 -r 4a7ac10ac2d9 runtime.S --- a/runtime.S Mon Apr 29 00:59:50 2013 -0700 +++ b/runtime.S Mon Apr 29 01:14:24 2013 -0700 @@ -18,6 +18,7 @@ handle_cycle_limit_int: cmp 88(%rsi), %eax jb skip_int + mov 84(%rsi), %ebp /* swap USP and SSP if not already in supervisor mode */ bt $5, 5(%rsi) jc already_supervisor @@ -444,9 +445,9 @@ jmp m68k_write_word inccycles: - cmp %rbp, %rax + cmp %ebp, %eax jnb do_limit - add $4, %rax + add $4, %eax ret do_limit: push %rcx @@ -454,7 +455,7 @@ call handle_cycle_limit pop %rdi pop %rcx - add $4, %rax + add $4, %eax ret .global m68k_read_word_scratch1