;	WinSTon

;	EOR Dn,<ea>

;	XNZVC
;	-**00

PUBLIC _eor_dn_dn_byte
PUBLIC _eor_dn_dn_word
PUBLIC _eor_dn_dn_long
PUBLIC _eor_dn_ea_byte
PUBLIC _eor_dn_ea_word
PUBLIC _eor_dn_ea_long

;-----------------------------------------------------------------------
;EOR.B Dn,Dn
_eor_dn_dn_byte PROC NEAR
	mov		edx,DECODE_2[ecx]						;DReg
	mov		bl,[edx]								;Src Dn
	xor		al,al									;Clear NZVC(ignore X)
	mov		edx,DECODE_1[ecx]						;Dest DReg <ea>
	xor		[edx],bl								;Dest Dn
	SET_NZ
_eor_dn_dn_byte ENDP

;EOR.W Dn,Dn
_eor_dn_dn_word PROC NEAR
	mov		edx,DECODE_2[ecx]						;DReg
	mov		bx,[edx]								;Src Dn
	xor		al,al									;Clear NZVC(ignore X)
	mov		edx,DECODE_1[ecx]						;Dest DReg <ea>
	xor		[edx],bx								;Dest Dn
	SET_NZ
_eor_dn_dn_word ENDP

;EOR.L Dn,Dn
_eor_dn_dn_long PROC NEAR
	mov		edx,DECODE_2[ecx]						;DReg
	mov		ebx,[edx]								;Src Dn
	xor		al,al									;Clear NZVC(ignore X)
	mov		edx,DECODE_1[ecx]						;Dest DReg <ea>
	xor		[edx],ebx								;Dest Dn
	SET_NZ
_eor_dn_dn_long ENDP

;-----------------------------------------------------------------------
;EOR.B Dn,<ea>
_eor_dn_ea_byte PROC NEAR
	EFFADDR_READ									;Read <ea>
	xor		al,al									;Clear NZVC(ignore X)
	mov		edx,DECODE_2[ecx]						;DReg
	xor		bl,[edx]								;Src Dn
	WRITE_BYTE_NZ
_eor_dn_ea_byte ENDP

;EOR.W Dn,<ea>
_eor_dn_ea_word PROC NEAR
	EFFADDR_READ									;Read <ea>
	xor		al,al									;Clear NZVC(ignore X)
	mov		edx,DECODE_2[ecx]						;DReg
	xor		bx,[edx]								;Src Dn
	WRITE_WORD_NZ
_eor_dn_ea_word ENDP

;EOR.L Dn,<ea>
_eor_dn_ea_long PROC NEAR
	EFFADDR_READ									;Read <ea>
	xor		al,al									;Clear NZVC(ignore X)
	mov		edx,DECODE_2[ecx]						;DReg
	xor		ebx,[edx]								;Src Dn
	WRITE_LONG_NZ
_eor_dn_ea_long ENDP
