// File: /workspace/github_cpp_makefile_star2_O2/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: mg_md5
void mg_md5(char *buf, ...) {
  unsigned char hash[16];
  const char *p;
  va_list ap;
  MD5_CTX ctx;

  MD5Init(&ctx);

  va_start(ap, buf);
  while ((p = va_arg(ap, const char *)) != NULL) {
    MD5Update(&ctx, (const unsigned char *) p, (unsigned) strlen(p));
  }
  va_end(ap);

  MD5Final(hash, &ctx);
  bin2str(buf, hash, sizeof(hash));
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x158, %rsp            # imm = 0x158
movq %rdi, 0x8(%rsp)
leaq 0xa0(%rsp), %rdi
movq %rsi, 0x8(%rdi)
movq %rdx, 0x10(%rdi)
movq %rcx, 0x18(%rdi)
movq %r8, 0x20(%rdi)
movq %r9, 0x28(%rdi)
testb %al, %al
je 0xc0c5
movaps %xmm0, 0xd0(%rsp)
movaps %xmm1, 0xe0(%rsp)
movaps %xmm2, 0xf0(%rsp)
movaps %xmm3, 0x100(%rsp)
movaps %xmm4, 0x110(%rsp)
movaps %xmm5, 0x120(%rsp)
movaps %xmm6, 0x130(%rsp)
movaps %xmm7, 0x140(%rsp)
movaps 0x6674(%rip), %xmm0     # 0x12740
leaq 0x58(%rsp), %r14
movaps %xmm0, -0x18(%r14)
andq $0x0, -0x8(%r14)
movabsq $0x3000000008, %rax     # imm = 0x3000000008
movq %rax, 0x10(%rsp)
leaq 0x190(%rsp), %rax
movq %rax, 0x18(%rsp)
movq %rdi, 0x20(%rsp)
pushq $0x8
popq %rbp
leaq 0x40(%rsp), %r15
cmpl $0x28, %ebp
ja 0xc122
movq %rax, %r13
movl %ebp, %eax
leaq 0xa0(%rsp), %rcx
addq %rcx, %rax
addl $0x8, %ebp
movl %ebp, 0x10(%rsp)
jmp 0xc12b
leaq 0x8(%rax), %r13
movq %r13, 0x18(%rsp)
movq (%rax), %r12
testq %r12, %r12
je 0xc206
movq %r12, %rdi
callq 0x51e0
movl 0x50(%rsp), %ecx
leal (,%rax,8), %edx
movl %eax, %esi
shrl $0x1d, %esi
addl %ecx, %edx
movl %edx, 0x50(%rsp)
adcl %esi, 0x54(%rsp)
shrl $0x3, %ecx
andl $0x3f, %ecx
je 0xc17f
leaq (%r14,%rcx), %rdi
pushq $0x40
popq %rdx
subl %ecx, %edx
movl %eax, %ebx
subl %edx, %ebx
jae 0xc187
movl %eax, %edx
movq %r12, %rsi
callq 0x53a0
movq %r13, %rax
jmp 0xc104
movq %r13, (%rsp)
movl %eax, %ebx
jmp 0xc1a7
movq %r13, (%rsp)
movl %edx, %r13d
movq %r12, %rsi
movq %r13, %rdx
callq 0x53a0
movq %r15, %rdi
movq %r14, %rsi
callq 0xd41d
addq %r13, %r12
movl %ebx, %r13d
cmpl $0x40, %r13d
jb 0xc1ef
movups (%r12), %xmm0
movups 0x10(%r12), %xmm1
movups 0x20(%r12), %xmm2
movups 0x30(%r12), %xmm3
movups %xmm3, 0x30(%r14)
movups %xmm2, 0x20(%r14)
movups %xmm1, 0x10(%r14)
movups %xmm0, (%r14)
movq %r15, %rdi
movq %r14, %rsi
callq 0xd41d
addq $0x40, %r12
addq $-0x40, %r13
jmp 0xc1aa
movq %r14, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x53a0
movq (%rsp), %rax
jmp 0xc104
movl 0x50(%rsp), %eax
shrl $0x3, %eax
andl $0x3f, %eax
leaq (%r14,%rax), %rdi
incq %rdi
movb $-0x80, 0x58(%rsp,%rax)
movl %eax, %ecx
xorl $0x3f, %ecx
cmpl $0x7, %ecx
ja 0xc254
movl %ecx, %edx
xorl %esi, %esi
callq 0x5270
leaq 0x40(%rsp), %rdi
movq %r14, %rsi
callq 0xd41d
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%r14)
movups %xmm0, 0x10(%r14)
movups %xmm0, (%r14)
andq $0x0, 0x30(%r14)
jmp 0xc260
pushq $0x37
popq %rdx
subl %eax, %edx
xorl %esi, %esi
callq 0x5270
leaq 0x40(%rsp), %r15
movq 0x10(%r15), %rax
movq %rax, 0x50(%r15)
movq %r15, %rdi
movq %r14, %rsi
callq 0xd41d
movaps (%r15), %xmm0
movaps %xmm0, 0x30(%rsp)
xorl %eax, %eax
leaq 0x6881(%rip), %rcx      # 0x12b0b
movq 0x8(%rsp), %rdi
cmpq $0x10, %rax
je 0xc2b6
movzbl 0x30(%rsp,%rax), %edx
movl %edx, %esi
shrl $0x4, %esi
movb (%rsi,%rcx), %sil
movb %sil, (%rdi,%rax,2)
andl $0xf, %edx
movb (%rdx,%rcx), %dl
movb %dl, 0x1(%rdi,%rax,2)
incq %rax
jmp 0xc28f
movb $0x0, (%rdi,%rax,2)
addq $0x158, %rsp            # imm = 0x158
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq