clean: fix indentation

This commit is contained in:
starnakin 2024-09-03 10:28:47 +02:00
parent a5ccf7df95
commit 3632b34e40
4 changed files with 47 additions and 49 deletions

View File

@ -1,10 +1,9 @@
section .note.GNU-stack noalloc noexec nowrite progbits section .text
section .text
global ft_strcmp global ft_strcmp
ft_strcmp: ft_strcmp:
mov rcx, 0 mov rcx, 0
loop: loop:
mov dl, [rsi + rcx] mov dl, [rsi + rcx]
mov bl, [rdi + rcx] mov bl, [rdi + rcx]
@ -16,7 +15,7 @@ loop:
inc rcx inc rcx
jmp loop jmp loop
out: out:
sub bl, dl sub bl, dl
movsx rax, bl movsx rax, bl
ret ret

View File

@ -1,9 +1,9 @@
section .text section .text
global ft_strcpy global ft_strcpy
ft_strcpy: ft_strcpy:
mov rcx, 0 mov rcx, 0
loop: loop:
mov al, [rsi + rcx] mov al, [rsi + rcx]
mov [rdi + rcx], al mov [rdi + rcx], al
@ -14,6 +14,6 @@ loop:
inc rcx inc rcx
jmp loop jmp loop
out: out:
mov rax, rdi mov rax, rdi
ret ret

View File

@ -1,13 +1,13 @@
section .text section .text
global ft_strlen global ft_strlen
ft_strlen: ft_strlen:
mov rcx, 0 mov rcx, 0
loop: loop:
cmp BYTE [rdi + rcx], 0 cmp BYTE [rdi + rcx], 0
je out je out
inc rcx inc rcx
jmp loop jmp loop
out: out:
mov rax, rcx mov rax, rcx
ret ret

View File

@ -1,7 +1,6 @@
section .text section .text
global ft_write global ft_write
ft_write:
ft_write:
mov rax, 1 mov rax, 1
syscall syscall
ret ret