[Coco] Devastated. Long term OVCC project falls short
Walter Zambotti
zambotti at iinet.net.au
Fri Oct 4 21:26:01 EDT 2019
> Just curious -- is this plain-old 16-bit x86 assembly? Or 32-bit
> x86? Or is it x86_64 assembly?
It is 64 bit. However I try to avoid using the 64 bit instructions as
much as possible.
Here is an example of one of the instructions:
PUBLIC Neg_D_A ; Op 00 - Negate DP memory byte
Neg_D_A PROC
MEMADR EQU 2
VAL EQU 4
sub rsp, 28h
; Calc Address by Adding the Byte at [PC++] with DP reg
mov cx, word ptr [pc_s]
inc word ptr [pc_s]
call MemRead8_s
mov cx, word ptr [dp_s]
or cx, ax
; Save Address and use it to get a mem byte
mov word ptr [rsp+MEMADR], cx
call MemRead8_s
; Negate the byte and save the FLAGS
neg al
; Save flags CF+VF+ZF+NF
setc byte ptr [cc_s+CF_C_B]
seto byte ptr [cc_s+VF_C_B]
setz byte ptr [cc_s+ZF_C_B]
sets byte ptr [cc_s+NF_C_B]
; Write negated byte (al) to address (saved on stack)
mov cx, ax
mov dx, word ptr [rsp+MEMADR]
call MemWrite8_s ; dx - address, cx - byte
add rsp, 28h
ret
Neg_D_A ENDP
Walter
On 10/4/19 10:08 PM, John W. Linville wrote:
> On Fri, Oct 04, 2019 at 12:06:05PM +0800, Walter Zambotti wrote:
>
>> The 6309 turbo feature is a reworking of the 6309 cpu emulator written in C
>> rewritten in X86 assembly.
> Just curious -- is this plain-old 16-bit x86 assembly? Or 32-bit
> x86? Or is it x86_64 assembly?
>
> John
More information about the Coco
mailing list