// File: /workspace/github_c_makefile_star2_O0/zenkj[P]luajit-arm64/src/host/minilua.c
// Function: auxsort
static void auxsort(lua_State*L,int l,int u){
while(l<u){
int i,j;
lua_rawgeti(L,1,l);
lua_rawgeti(L,1,u);
if(sort_comp(L,-1,-2))
set2(L,l,u);
else
lua_pop(L,2);
if(u-l==1)break;
i=(l+u)/2;
lua_rawgeti(L,1,i);
lua_rawgeti(L,1,l);
if(sort_comp(L,-2,-1))
set2(L,i,l);
else{
lua_pop(L,1);
lua_rawgeti(L,1,u);
if(sort_comp(L,-1,-2))
set2(L,i,u);
else
lua_pop(L,2);
}
if(u-l==2)break;
lua_rawgeti(L,1,i);
lua_pushvalue(L,-1);
lua_rawgeti(L,1,u-1);
set2(L,i,u-1);
i=l;j=u-1;
for(;;){
while(lua_rawgeti(L,1,++i),sort_comp(L,-1,-2)){
if(i>u)luaL_error(L,"invalid order function for sorting");
lua_pop(L,1);
}
while(lua_rawgeti(L,1,--j),sort_comp(L,-3,-1)){
if(j<l)luaL_error(L,"invalid order function for sorting");
lua_pop(L,1);
}
if(j<i){
lua_pop(L,3);
break;
}
set2(L,i,j);
}
lua_rawgeti(L,1,u-1);
lua_rawgeti(L,1,i);
set2(L,u-1,i);
if(i-l<u-i){
j=l;i=i-1;l=i+2;
}
else{
j=i+1;i=u;u=j-2;
}
auxsort(L,j,i);
}
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movl %edx, 0x8(%rsp)
movl 0xc(%rsp), %eax
cmpl 0x8(%rsp), %eax
jge 0x1bd61
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl 0x8(%rsp), %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl $0xfffffffe, %edx       # imm = 0xFFFFFFFE
callq 0x1bd70
cmpl $0x0, %eax
je 0x1ba72
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %esi
movl 0x8(%rsp), %edx
callq 0x1be30
jmp 0x1ba81
movq 0x10(%rsp), %rdi
movl $0xfffffffd, %esi       # imm = 0xFFFFFFFD
callq 0x11600
movl 0x8(%rsp), %eax
subl 0xc(%rsp), %eax
cmpl $0x1, %eax
jne 0x1ba93
jmp 0x1bd61
movl 0xc(%rsp), %eax
addl 0x8(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, 0x4(%rsp)
movq 0x10(%rsp), %rdi
movl 0x4(%rsp), %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x1bd70
cmpl $0x0, %eax
je 0x1bafa
movq 0x10(%rsp), %rdi
movl 0x4(%rsp), %esi
movl 0xc(%rsp), %edx
callq 0x1be30
jmp 0x1bb5a
movq 0x10(%rsp), %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x11600
movq 0x10(%rsp), %rdi
movl 0x8(%rsp), %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl $0xfffffffe, %edx       # imm = 0xFFFFFFFE
callq 0x1bd70
cmpl $0x0, %eax
je 0x1bb49
movq 0x10(%rsp), %rdi
movl 0x4(%rsp), %esi
movl 0x8(%rsp), %edx
callq 0x1be30
jmp 0x1bb58
movq 0x10(%rsp), %rdi
movl $0xfffffffd, %esi       # imm = 0xFFFFFFFD
callq 0x11600
jmp 0x1bb5a
movl 0x8(%rsp), %eax
subl 0xc(%rsp), %eax
cmpl $0x2, %eax
jne 0x1bb6c
jmp 0x1bd61
movq 0x10(%rsp), %rdi
movl 0x4(%rsp), %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0xf7f0
movq 0x10(%rsp), %rdi
movl 0x8(%rsp), %edx
subl $0x1, %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl 0x4(%rsp), %esi
movl 0x8(%rsp), %edx
subl $0x1, %edx
callq 0x1be30
movl 0xc(%rsp), %eax
movl %eax, 0x4(%rsp)
movl 0x8(%rsp), %eax
subl $0x1, %eax
movl %eax, (%rsp)
jmp 0x1bbcd
movq 0x10(%rsp), %rdi
movl 0x4(%rsp), %edx
addl $0x1, %edx
movl %edx, 0x4(%rsp)
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl $0xfffffffe, %edx       # imm = 0xFFFFFFFE
callq 0x1bd70
cmpl $0x0, %eax
je 0x1bc2e
movl 0x4(%rsp), %eax
cmpl 0x8(%rsp), %eax
jle 0x1bc1d
movq 0x10(%rsp), %rdi
leaq 0x7513(%rip), %rsi      # 0x23129
movb $0x0, %al
callq 0x10790
movq 0x10(%rsp), %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x11600
jmp 0x1bbcd
jmp 0x1bc30
movq 0x10(%rsp), %rdi
movl (%rsp), %edx
addl $-0x1, %edx
movl %edx, (%rsp)
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl $0xfffffffd, %esi       # imm = 0xFFFFFFFD
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x1bd70
cmpl $0x0, %eax
je 0x1bc8e
movl (%rsp), %eax
cmpl 0xc(%rsp), %eax
jge 0x1bc7d
movq 0x10(%rsp), %rdi
leaq 0x74b3(%rip), %rsi      # 0x23129
movb $0x0, %al
callq 0x10790
movq 0x10(%rsp), %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x11600
jmp 0x1bc30
movl (%rsp), %eax
cmpl 0x4(%rsp), %eax
jge 0x1bca8
movq 0x10(%rsp), %rdi
movl $0xfffffffc, %esi       # imm = 0xFFFFFFFC
callq 0x11600
jmp 0x1bcbe
movq 0x10(%rsp), %rdi
movl 0x4(%rsp), %esi
movl (%rsp), %edx
callq 0x1be30
jmp 0x1bbcb
movq 0x10(%rsp), %rdi
movl 0x8(%rsp), %edx
subl $0x1, %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl 0x4(%rsp), %edx
movl $0x1, %esi
callq 0x1aaa0
movq 0x10(%rsp), %rdi
movl 0x8(%rsp), %esi
subl $0x1, %esi
movl 0x4(%rsp), %edx
callq 0x1be30
movl 0x4(%rsp), %eax
subl 0xc(%rsp), %eax
movl 0x8(%rsp), %ecx
subl 0x4(%rsp), %ecx
cmpl %ecx, %eax
jge 0x1bd2f
movl 0xc(%rsp), %eax
movl %eax, (%rsp)
movl 0x4(%rsp), %eax
subl $0x1, %eax
movl %eax, 0x4(%rsp)
movl 0x4(%rsp), %eax
addl $0x2, %eax
movl %eax, 0xc(%rsp)
jmp 0x1bd4b
movl 0x4(%rsp), %eax
addl $0x1, %eax
movl %eax, (%rsp)
movl 0x8(%rsp), %eax
movl %eax, 0x4(%rsp)
movl (%rsp), %eax
subl $0x2, %eax
movl %eax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
movl (%rsp), %esi
movl 0x4(%rsp), %edx
callq 0x1ba00
jmp 0x1ba11
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)