;	WinSTon

;	EXG.L Dx,Dy
;	EXG.L Ax,Ay
;	EXG.L Dx,Ay

;	XNZVC
;	-----

PUBLIC _exg_dn_dn_long
PUBLIC _exg_an_an_long
PUBLIC _exg_dn_an_long

;-----------------------------------------------------------------------
;EXG.L Dx,Dy
_exg_dn_dn_long PROC NEAR
	mov		edx,DECODE_1[ecx]						;Rx('opcode' bits 9-11)
	mov		ecx,DECODE_2[ecx]						;Ry('opcode' bits 0-2)
	mov		ebx,[ecx]								;Dy->ebx
	xchg	ebx,[edx]								;Dx<->ebx
	mov		[ecx],ebx								;ebx->Dy
	FRET
_exg_dn_dn_long ENDP

;-----------------------------------------------------------------------
;EXG.L Ax,Ay
_exg_an_an_long PROC NEAR
	mov		edx,DECODE_1[ecx]						;Rx('opcode' bits 9-11)
	mov		ecx,DECODE_2[ecx]						;Ry('opcode' bits 0-2)
	mov		ebx,[ecx]								;Ay->ebx
	xchg	ebx,[edx]								;Ax<->ebx
	mov		[ecx],ebx								;ebx->Ay
	FRET
_exg_an_an_long ENDP

;-----------------------------------------------------------------------
;EXG.L Dx,Ay
_exg_dn_an_long PROC NEAR
	mov		edx,DECODE_1[ecx]						;Rx('opcode' bits 9-11)
	mov		ecx,DECODE_2[ecx]						;Ry('opcode' bits 0-2)
	mov		ebx,[ecx]								;Ay->ebx
	xchg	ebx,[edx]								;Dx<->ebx
	mov		[ecx],ebx								;ebx->Ay
	FRET
_exg_dn_an_long ENDP
