/*****************************************************************************/
/*									     */
/*									     */
/*	CP/M emulator version 0.1					     */
/*									     */
/*	written by Michael Bischoff (mbi@mo.math.nat.tu-bs.de)		     */
/*	June-1994							     */
/*									     */
/*	This file is distributed under the GNU COPYRIGHT		     */
/*	see COPYRIGHT.GNU for Copyright details				     */
/*									     */
/*									     */
/*****************************************************************************/
		.file	"single.s"
gcc2_compiled.:
___gnu_compiled_c:
.text
		.align 4,0x90

#define dispatch	jmp exitemu

.globl		_singlestep
_singlestep:
		pushl %ebp
		pushl %esi
		pushl %edi
		pushl %ecx
		pushl %edx
		pushl %ebx
		movzwl _z80regs,%esi
		/* movzwl _z80regs+4,%ebp */
		movl $_z80mem,%ebp
		movzwl _z80regs+8,%ecx
		movzwl _z80regs+12,%edx
		movzwl _z80regs+16,%ebx
		movzwl _z80regs+20,%eax
		movzbl (%esi,%ebp),%edi
		inc %esi
		sall $2,%edi
		jmp jumptab(%edi)

		.align 4,0x90
exitemu:	/* decl %esi */
		movw %esi,_z80regs
		/* movw %ebp,_z80regs+4 */
		movw %ecx,_z80regs+8
		movw %edx,_z80regs+12
		movw %ebx,_z80regs+16
		movw %eax,_z80regs+20
		popl %ebx
		popl %edx
		popl %ecx
		popl %edi
		popl %esi
		popl %ebp
		ret

#include "code.s"
#include "code2.s"
		.align 4,0x90