Untitled

mail@pastecode.io avatar
unknown
assembly_x86
2 years ago
368 B
12
Indexable
Never
%macro printInt 1
    mov rax, %1
    mov rdx, 0
    mov rdi, 0
    mov rbx, 10

%%IntegerToString:
    div rbx
    add rdx, 48
    push rdx
    inc rdi
    cmp rax, 0
    jne %%IntegerToString

    mov rdx, DigitSpace

%%LoadIntoVar:
    pop rbx
    mov [rdx], rbx
    inc rdx
    inc rax
    cmp rax, rdi
    jne %%LoadIntoVar

    print 1, DigitSpace, rdi
%endmacro