Fix crash bug in Z80 interrupt support
author |
Mike Pavone <pavone@retrodev.com> |
date |
Fri, 03 May 2013 18:50:16 -0700 |
parents |
1a7d0a964ad2 |
children |
765e132edd71 |
files |
blastem.c zruntime.S |
diffstat |
2 files changed, 2 insertions(+), 1 deletions(-)
[+]
|
line diff
--- a/blastem.c Fri May 03 18:49:48 2013 -0700
+++ b/blastem.c Fri May 03 18:50:16 2013 -0700
@@ -133,7 +133,7 @@
uint8_t busack = 0;
uint32_t busack_cycle = CYCLE_NEVER;
uint8_t new_busack = 0;
-
+//#define DO_DEBUG_PRINT
#ifdef DO_DEBUG_PRINT
#define dprintf printf
#define dputs puts
--- a/zruntime.S Fri May 03 18:49:48 2013 -0700
+++ b/zruntime.S Fri May 03 18:50:16 2013 -0700
@@ -38,6 +38,7 @@
shr $8, %r13w
call z_inccycles
call z80_write_byte_noinc
+ pop %r14 /*dispose of return address */
/* TODO: Support interrupt mode 0 and 2 */
mov $0x38, %r13w
call z80_native_addr