From b22183ba021d9ab3418d8f47545708597247e583 Mon Sep 17 00:00:00 2001 From: Charles Date: Fri, 22 Nov 2019 02:35:31 +0100 Subject: strcpy, strcmp, write, read --- ft_strlen.s | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'ft_strlen.s') diff --git a/ft_strlen.s b/ft_strlen.s index 82c0e34..c548d73 100644 --- a/ft_strlen.s +++ b/ft_strlen.s @@ -1,8 +1,8 @@ -.globl _ft_strlen +.globl _ft_strlen _ft_strlen: - mov rbx, rdi # first argument in rbx - xor rax, rax # rax = 0 + mov rbx, rdi # str argument + xor rax, rax FT_STRLEN_LOOP: cmp byte ptr [rbx + rax], 0 # compare rbx[rax] and '\0' je FT_STRLEN_RET -- cgit