// File: /workspace/github_cpp_makefile_star2_O3/adamiaonr[P]rid-analytics/src/pugixml.cpp
// Function: void pugi::impl::(anonymous namespace)::sort<pugi::xpath_node*, pugi::impl::(anonymous namespace)::duplicate_comparator>(pugi::xpath_node*, pugi::xpath_node*, pugi::impl::(anonymous namespace)::duplicate_comparator const&)
void sort(I begin, I end, const Pred& pred)
	{
		// sort large chunks
		while (end - begin > 32)
		{
			// find median element
			I middle = begin + (end - begin) / 2;
			median(begin, middle, end - 1, pred);

			// partition in three chunks (< = >)
			I eqbeg, eqend;
			partition(begin, middle, end, pred, &eqbeg, &eqend);

			// loop on larger half
			if (eqbeg - begin > end - eqend)
			{
				sort(eqend, end, pred);
				end = eqbeg;
			}
			else
			{
				sort(begin, eqbeg, pred);
				begin = eqend;
			}
		}

		// insertion sort small chunk
		if (begin != end) insertion_sort(begin, end, pred, &*begin);
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %r13
subq %rdi, %r13
sarq $0x4, %r13
cmpq $0x21, %r13
jl 0x17f4f
movq %r14, %rax
shrq %r13
shlq $0x4, %r13
leaq (%rbx,%r13), %rsi
leaq -0x10(%r14), %r12
movq %r12, %rbp
subq %rbx, %rbp
sarq $0x4, %rbp
cmpq $0x28, %rbp
movq %rax, 0x20(%rsp)
jg 0x17c6f
movq %rbx, %rdi
movq %r12, %rdx
jmp 0x17cd6
incq %rbp
shrq $0x3, %rbp
movq %rbp, %r15
shlq $0x4, %r15
leaq (%rbx,%r15), %rax
movq %rax, 0x18(%rsp)
shlq $0x5, %rbp
leaq (%rbx,%rbp), %rdx
movq %rbx, %rdi
movq %rsi, 0x10(%rsp)
movq %rax, %rsi
callq 0x18042
movq 0x10(%rsp), %rsi
movq %rsi, %rdi
subq %r15, %rdi
leaq (%rsi,%r15), %rdx
callq 0x18042
movq %r12, %rdi
subq %rbp, %rdi
movq %r12, %rbp
subq %r15, %rbp
movq %rbp, %rsi
movq %r12, %rdx
callq 0x18042
movq 0x18(%rsp), %rdi
movq 0x10(%rsp), %rsi
movq %rbp, %rdx
callq 0x18042
movq %r13, %rax
movq %rax, %rdx
testq %rax, %rax
je 0x17d0b
movdqu -0x10(%rbx,%rdx), %xmm0
movdqu (%rbx,%rdx), %xmm1
pcmpeqd %xmm0, %xmm1
pshufd $0xb1, %xmm1, %xmm0     # xmm0 = xmm1[1,0,3,2]
pand %xmm1, %xmm0
movmskpd %xmm0, %ecx
leaq -0x10(%rdx), %rax
cmpl $0x3, %ecx
je 0x17cde
addq %rbx, %rdx
leaq (%rbx,%r13), %rax
addq $0x10, %rax
movq %rax, %r15
cmpq %r14, %rax
je 0x17d41
movdqu (%r15), %xmm0
movdqu (%rdx), %xmm1
pcmpeqd %xmm0, %xmm1
pshufd $0xb1, %xmm1, %xmm0     # xmm0 = xmm1[1,0,3,2]
pand %xmm1, %xmm0
movmskpd %xmm0, %ecx
leaq 0x10(%r15), %rax
cmpl $0x3, %ecx
je 0x17d16
movq %rdx, %rax
movq %r15, %rcx
movb $0x1, %sil
cmpq %r14, %rcx
je 0x17dac
movq 0x8(%rdx), %rdi
movq 0x8(%rcx), %r8
testq %rdi, %rdi
je 0x17d6e
testq %r8, %r8
je 0x17da4
cmpq %r8, %rdi
jb 0x17da4
movq (%rcx), %r9
movq (%rdx), %r10
jmp 0x17d7e
movq (%rcx), %r9
movq (%rdx), %r10
testq %r8, %r8
jne 0x17d7e
cmpq %r9, %r10
jb 0x17da4
cmpq %r10, %r9
jne 0x17daa
cmpq %rdi, %r8
jne 0x17daa
movups (%rcx), %xmm0
movaps %xmm0, (%rsp)
movups (%r15), %xmm0
movups %xmm0, (%rcx)
movapd (%rsp), %xmm0
movupd %xmm0, (%r15)
addq $0x10, %r15
addq $0x10, %rcx
jmp 0x17d4a
xorl %esi, %esi
cmpq %rbx, %rax
je 0x17e38
addq $-0x10, %rax
movq %rax, %rdi
movq %rdx, %r12
movq %rdi, %rax
movq 0x8(%rdi), %rdx
movq 0x8(%r12), %rdi
testq %rdx, %rdx
je 0x17de3
testq %rdi, %rdi
je 0x17e26
cmpq %rdi, %rdx
jb 0x17e26
movq (%r12), %r8
movq (%rax), %r9
jmp 0x17df4
movq (%r12), %r8
movq (%rax), %r9
testq %rdi, %rdi
jne 0x17df4
cmpq %r8, %r9
jb 0x17e26
cmpq %r9, %r8
jne 0x17e91
cmpq %rdx, %rdi
jne 0x17e91
movups (%rax), %xmm0
movaps %xmm0, (%rsp)
movups -0x10(%r12), %xmm0
movups %xmm0, (%rax)
movapd (%rsp), %xmm0
movupd %xmm0, -0x10(%r12)
addq $-0x10, %r12
leaq -0x10(%rax), %rdi
cmpq %rbx, %rax
jne 0x17dbf
addq $0x10, %rdi
movq %rdi, %rax
jmp 0x17e3b
movq %rdx, %r12
testb %sil, %sil
jne 0x17eff
cmpq %rcx, %r15
je 0x17e65
movups (%r12), %xmm0
movaps %xmm0, (%rsp)
movups (%r15), %xmm0
movups %xmm0, (%r12)
movapd (%rsp), %xmm0
movupd %xmm0, (%r15)
addq $0x10, %r15
movups (%rcx), %xmm0
movaps %xmm0, (%rsp)
movups (%r12), %xmm0
movups %xmm0, (%rcx)
addq $0x10, %rcx
leaq 0x10(%r12), %rdx
movapd (%rsp), %xmm0
movupd %xmm0, (%r12)
jmp 0x17d47
testb %sil, %sil
je 0x17edd
leaq 0x10(%rax), %rsi
leaq -0x10(%r12), %rdx
cmpq %r12, %rsi
je 0x17eba
movups (%rax), %xmm0
movaps %xmm0, (%rsp)
movups (%rdx), %xmm0
movups %xmm0, (%rax)
movapd (%rsp), %xmm0
movupd %xmm0, (%rdx)
movups (%rdx), %xmm0
movaps %xmm0, (%rsp)
movups -0x10(%r15), %xmm0
movups %xmm0, (%rdx)
movapd (%rsp), %xmm0
movupd %xmm0, -0x10(%r15)
addq $-0x10, %r15
jmp 0x17d47
movups (%rcx), %xmm0
movaps %xmm0, (%rsp)
movups (%rax), %xmm0
movups %xmm0, (%rcx)
addq $0x10, %rcx
movapd (%rsp), %xmm0
movupd %xmm0, (%rax)
movq %r12, %rdx
jmp 0x17d47
movq %r12, %rax
subq %rbx, %rax
movq 0x20(%rsp), %rcx
subq %r15, %rcx
cmpq %rcx, %rax
jle 0x17f25
movq %r15, %rdi
movq %r14, %rsi
callq 0x17c18
movq %r12, %rax
movq %r12, %r14
jmp 0x17f39
movq %rbx, %rdi
movq %r12, %rsi
callq 0x17c18
movq %r15, %rbx
movq %r14, %rax
movq %r14, %r12
movq %rax, %r13
subq %rbx, %r13
sarq $0x4, %r13
cmpq $0x20, %r13
jg 0x17c43
jmp 0x17f52
movq %r14, %r12
cmpq %r12, %rbx
je 0x18033
leaq 0x10(%rbx), %rax
movq %rax, 0x10(%rsp)
cmpq %r12, %rax
je 0x18033
leaq 0x8(%rbx), %rax
movq %rax, 0x18(%rsp)
leaq 0x18(%rbx), %r13
xorl %ebp, %ebp
movq 0x10(%rsp), %rax
movq %rbx, %rsi
movq 0x10(%rsi), %r15
movq 0x18(%rsi), %r14
movq %rax, %rsi
movq 0x8(%rbx), %rcx
testq %r14, %r14
je 0x17fa7
testq %rcx, %rcx
je 0x17fb7
movq %r13, %rax
cmpq %rcx, %r14
jae 0x17fe3
jmp 0x17fb7
movq %r13, %rax
testq %rcx, %rcx
jne 0x17fe3
movq %r13, %rax
cmpq (%rbx), %r15
jae 0x17fe3
movq %rbp, %rdx
shlq $0x4, %rdx
addq $0x10, %rdx
movq 0x10(%rsp), %rdi
movq %rsi, 0x20(%rsp)
movq %rbx, %rsi
callq 0x4650
movq 0x20(%rsp), %rsi
movq %r15, (%rbx)
movq 0x18(%rsp), %rax
jmp 0x1801c
leaq -0x18(%rax), %rcx
movq -0x10(%rax), %rdx
testq %r14, %r14
je 0x17ffc
testq %rdx, %rdx
je 0x18006
cmpq %rdx, %r14
jb 0x18006
jmp 0x18018
testq %rdx, %rdx
jne 0x18018
cmpq (%rcx), %r15
jae 0x18018
leaq -0x8(%rax), %rdx
movupd (%rcx), %xmm0
movupd %xmm0, (%rdx)
addq $-0x10, %rax
jmp 0x17fe3
movq %r15, -0x8(%rax)
movq %r14, (%rax)
leaq 0x10(%rsi), %rax
incq %rbp
addq $0x10, %r13
cmpq %r12, %rax
jne 0x17f84
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq