// File: /workspace/github_c_makefile_star2_O2/rpeepz[P]ft_ssl/srcs/hash/md5.c
// Function: md5
char			*md5(char *buf, char *to_hash)
{
	t_md5		b;
	int			i;

	i = -1;
	ft_bzero(&b, sizeof(t_md5));
	md5_set(to_hash, &b, (int)-1, (uint64_t)0);
	b.hash[0] = 0x67452301;
	b.hash[1] = 0xefcdab89;
	b.hash[2] = 0x98badcfe;
	b.hash[3] = 0x10325476;
	while (++i < (int)b.multiples)
		md5_cycle(i, &b);
	endian_rev(&b.hash[0]);
	endian_rev(&b.hash[1]);
	endian_rev(&b.hash[2]);
	endian_rev(&b.hash[3]);
	to_hash = buf;
	ft_sprintf(to_hash, "%.8x%.8x%.8x%.8x",
		b.hash[0], b.hash[1], b.hash[2], b.hash[3]);
	free(b.message);
	return (to_hash);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rsi, %r15
movq %rdi, 0x18(%rsp)
leaq 0x30(%rsp), %r12
pushq $0x78
popq %rsi
movq %r12, %rdi
callq 0x6720
movq %r15, %rdi
callq 0x739e
movq %rax, %r14
leaq 0x8(%rax), %r13
shrq $0x6, %r13
incl %r13d
movl %r13d, 0x10(%r12)
shll $0x6, %r13d
movq %r13, %rdi
callq 0x10b0
movq %rax, 0x30(%r12)
movq %rax, %rdi
movq %r13, %rsi
callq 0x6720
movq 0x30(%r12), %rdi
movq %r15, %rsi
callq 0x7190
movq 0x30(%r12), %rax
movb $-0x80, (%rax,%r14)
shlq $0x3, %r14
pushq $-0x8
popq %rax
xorl %ecx, %ecx
testl %eax, %eax
je 0x37b4
movq %r14, %rdx
shrq %cl, %rdx
testq %rdx, %rdx
je 0x37b4
movq 0x60(%rsp), %rsi
movl 0x40(%rsp), %edi
shll $0x6, %edi
addl %eax, %edi
movb %dl, (%rsi,%rdi)
incl %eax
addq $0x8, %rcx
jmp 0x378c
movabsq $-0x1032547698badcff, %rax # imm = 0xEFCDAB8967452301
leaq 0x34(%rsp), %rcx
movq %rax, -0x4(%rcx)
leaq 0x38(%rsp), %rax
movl $0x98badcfe, (%rax)     # imm = 0x98BADCFE
movl $0x10325476, %r12d      # imm = 0x10325476
pushq $-0x1
popq %rdx
xorl %ecx, %ecx
movl %r12d, 0x3c(%rsp)
incq %rdx
movslq 0x40(%rsp), %rax
cmpq %rax, %rdx
jge 0x396f
movq %rdx, 0x20(%rsp)
movq %rcx, 0x28(%rsp)
movq %rcx, %rax
leaq 0x68(%rsp), %rcx
pushq $-0x1
popq %rdx
cmpq $0xf, %rdx
je 0x3838
incq %rdx
xorl %esi, %esi
cmpq $0x4, %rsi
je 0x382e
movq 0x60(%rsp), %rdi
addq %rax, %rdi
movb (%rsi,%rdi), %dil
movb %dil, (%rcx,%rsi)
incq %rsi
jmp 0x3813
addq $0x4, %rcx
addq $0x4, %rax
jmp 0x3808
movl 0x30(%rsp), %ecx
movl 0x34(%rsp), %edx
movl 0x38(%rsp), %r14d
xorl %ebx, %ebx
movl 0x3c(%rsp), %r12d
pushq $0x1
popq %r15
pushq $0x5
popq %rdi
xorl %esi, %esi
xorl %eax, %eax
movl %ecx, 0x8(%rsp)
movl %r12d, 0x14(%rsp)
movl %r14d, 0x10(%rsp)
movl %edx, 0xc(%rsp)
cmpq $0x40, %rax
je 0x3920
cmpq $0xf, %rax
ja 0x388a
movl %r14d, %r13d
xorl %r12d, %r13d
andl %edx, %r13d
xorl %r12d, %r13d
movl %eax, %r8d
jmp 0x38cf
movl %eax, %r8d
andl $-0x10, %r8d
cmpl $0x20, %r8d
je 0x38ae
cmpl $0x10, %r8d
jne 0x38bc
movl %edx, %r13d
xorl %r14d, %r13d
andl %r12d, %r13d
xorl %r14d, %r13d
movl %r15d, %r8d
jmp 0x38cb
movl %r14d, %r13d
xorl %r12d, %r13d
xorl %edx, %r13d
movl %edi, %r8d
jmp 0x38cb
movl %r12d, %r13d
notl %r13d
orl %edx, %r13d
xorl %r14d, %r13d
movl %ebx, %r8d
andl $0xf, %r8d
addl %ecx, %r13d
leaq 0xe977(%rip), %rcx      # 0x12250
addl (%rsi,%rcx), %r13d
movl %r8d, %ecx
addl 0x68(%rsp,%rcx,4), %r13d
leaq 0xe864(%rip), %rcx      # 0x12150
movb (%rsi,%rcx), %cl
movl %r13d, %ebp
roll %cl, %ebp
addl %edx, %ebp
incq %rax
addq $0x4, %rsi
addl $0x3, %edi
addl $0x5, %r15d
addl $0x7, %ebx
movl %edx, %r11d
movl %r14d, %r9d
movl %r12d, %r10d
movl %r12d, %ecx
movl %r14d, %r12d
movl %edx, %r14d
movl %ebp, %edx
jmp 0x3869
movl %r13d, 0x54(%rsp)
movl %r8d, 0x58(%rsp)
movl %r10d, 0x44(%rsp)
movl %r9d, 0x50(%rsp)
movl %r11d, 0x4c(%rsp)
movl %ebp, 0x48(%rsp)
addl 0x8(%rsp), %ecx
movl %ecx, 0x30(%rsp)
addl 0xc(%rsp), %edx
movl %edx, 0x34(%rsp)
addl 0x10(%rsp), %r14d
movl %r14d, 0x38(%rsp)
addl 0x14(%rsp), %r12d
movq 0x28(%rsp), %rcx
addq $0x40, %rcx
movq 0x20(%rsp), %rdx
jmp 0x37dd
leaq 0x30(%rsp), %r13
movq %r13, %rdi
callq 0x39de
leaq 0x34(%rsp), %rdi
callq 0x39de
leaq 0x38(%rsp), %rdi
callq 0x39de
leaq 0x3c(%rsp), %rdi
callq 0x39de
movl (%r13), %edx
movl 0x4(%r13), %ecx
movl 0x8(%r13), %r8d
movl 0xc(%r13), %r9d
leaq 0x8a0f(%rip), %rsi      # 0xc3c0
movq 0x18(%rsp), %rbx
movq %rbx, %rdi
xorl %eax, %eax
callq 0x6dd0
movq 0x30(%r13), %rdi
callq 0x1030
movq %rbx, %rax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq