// File: Alcaro[P]bridges/arlib/string.cpp
// Function: string::compare3(cstring, cstring)
int string::compare3(cstring a, cstring b)
{
	size_t cmplen = min(a.length(), b.length());
	int ret = memcmp(a.bytes().ptr(), b.bytes().ptr(), cmplen);
	
	if (ret) return ret;
	else return a.length() - b.length();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1c0, %rsp            # imm = 0x1C0
movq %rdi, -0x130(%rbp)
movq %rsi, -0x128(%rbp)
movq %rdx, -0x140(%rbp)
movq %rcx, -0x138(%rbp)
leaq -0x130(%rbp), %rax
movq %rax, -0xd0(%rbp)
movq -0xd0(%rbp), %rax
movq %rax, -0x178(%rbp)
movq %rax, -0xc0(%rbp)
movq -0xc0(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
cmpl $0x0, %eax
jl 0x3b953
movq -0x178(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x60(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
xorl $0xf, %eax
movzbl %al, %eax
movl %eax, -0xc4(%rbp)
jmp 0x3b963
movq -0x178(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0xc4(%rbp)
movl -0xc4(%rbp), %eax
movl %eax, -0x184(%rbp)
leaq -0x140(%rbp), %rax
movq %rax, -0xe8(%rbp)
movq -0xe8(%rbp), %rax
movq %rax, -0x180(%rbp)
movq %rax, -0xd8(%rbp)
movq -0xd8(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
cmpl $0x0, %eax
jl 0x3b9cb
movq -0x180(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
xorl $0xf, %eax
movzbl %al, %eax
movl %eax, -0xdc(%rbp)
jmp 0x3b9db
movq -0x180(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0xdc(%rbp)
movl -0x184(%rbp), %edi
movl -0xdc(%rbp), %esi
callq 0x3bcc0
movl %eax, %eax
movq %rax, -0x148(%rbp)
leaq -0x130(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x78(%rbp), %rax
leaq -0x88(%rbp), %rcx
movq %rcx, -0x38(%rbp)
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x190(%rbp)
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
cmpl $0x0, %eax
jl 0x3ba67
movq -0x190(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
callq 0x5cc0
movq -0x190(%rbp), %rsi
movsbl %al, %eax
xorl $0xf, %eax
movzbl %al, %eax
movl %eax, %edx
leaq -0x88(%rbp), %rdi
callq 0x5ed0
jmp 0x3ba82
movq -0x190(%rbp), %rax
movq (%rax), %rsi
movl 0x8(%rax), %eax
movl %eax, %edx
leaq -0x88(%rbp), %rdi
callq 0x5ed0
movups -0x88(%rbp), %xmm0
movaps %xmm0, -0x70(%rbp)
movq -0x70(%rbp), %rcx
movq -0x68(%rbp), %rax
movq %rcx, -0x160(%rbp)
movq %rax, -0x158(%rbp)
leaq -0x160(%rbp), %rdi
callq 0x62c0
movq %rax, -0x1a0(%rbp)
leaq -0x140(%rbp), %rax
movq %rax, -0xa8(%rbp)
movq -0xa8(%rbp), %rax
leaq -0xb8(%rbp), %rcx
movq %rcx, -0x18(%rbp)
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x198(%rbp)
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
cmpl $0x0, %eax
jl 0x3bb2e
movq -0x198(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rdi
callq 0x5cc0
movq -0x198(%rbp), %rsi
movsbl %al, %eax
xorl $0xf, %eax
movzbl %al, %eax
movl %eax, %edx
leaq -0xb8(%rbp), %rdi
callq 0x5ed0
jmp 0x3bb49
movq -0x198(%rbp), %rax
movq (%rax), %rsi
movl 0x8(%rax), %eax
movl %eax, %edx
leaq -0xb8(%rbp), %rdi
callq 0x5ed0
movups -0xb8(%rbp), %xmm0
movaps %xmm0, -0xa0(%rbp)
movq -0xa0(%rbp), %rcx
movq -0x98(%rbp), %rax
movq %rcx, -0x170(%rbp)
movq %rax, -0x168(%rbp)
leaq -0x170(%rbp), %rdi
callq 0x62c0
movq -0x1a0(%rbp), %rdi
movq %rax, %rsi
movq -0x148(%rbp), %rdx
callq 0x4100
movl %eax, -0x14c(%rbp)
cmpl $0x0, -0x14c(%rbp)
je 0x3bbb5
movl -0x14c(%rbp), %eax
movl %eax, -0x11c(%rbp)
jmp 0x3bcab
leaq -0x130(%rbp), %rax
movq %rax, -0x100(%rbp)
movq -0x100(%rbp), %rax
movq %rax, -0x1a8(%rbp)
movq %rax, -0xf0(%rbp)
movq -0xf0(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
cmpl $0x0, %eax
jl 0x3bc11
movq -0x1a8(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
xorl $0xf, %eax
movzbl %al, %eax
movl %eax, -0xf4(%rbp)
jmp 0x3bc21
movq -0x1a8(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0xf4(%rbp)
movl -0xf4(%rbp), %eax
movl %eax, -0x1b4(%rbp)
leaq -0x140(%rbp), %rax
movq %rax, -0x118(%rbp)
movq -0x118(%rbp), %rax
movq %rax, -0x1b0(%rbp)
movq %rax, -0x108(%rbp)
movq -0x108(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
cmpl $0x0, %eax
jl 0x3bc89
movq -0x1b0(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rdi
callq 0x5cc0
movsbl %al, %eax
xorl $0xf, %eax
movzbl %al, %eax
movl %eax, -0x10c(%rbp)
jmp 0x3bc99
movq -0x1b0(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0x10c(%rbp)
movl -0x1b4(%rbp), %eax
subl -0x10c(%rbp), %eax
movl %eax, -0x11c(%rbp)
movl -0x11c(%rbp), %eax
addq $0x1c0, %rsp            # imm = 0x1C0
popq %rbp
retq
nopw (%rax,%rax)