user: 请将以下的汇编代码转换成C语言代码:

```asm
<selectOrder>:
  endbr64
  cmp    $0x1,%esi
  jle    L74
  push   %r15
  mov    $0x1,%ecx
  push   %r14
  mov    %rdi,%r14
  push   %r13
  lea    0x4(%rdi),%r13
  push   %r12
  mov    %esi,%r12d
  push   %rbp
  lea    -0x1(%rsi),%ebp
  push   %rbx
  sub    $0x8,%rsp
  movdqa D11(%rip),%xmm7
  nopl   (%rax)
L115:
  mov    %r12d,%r8d
  mov    $0x1,%eax
  mov    -0x4(%r13),%edi
  lea    -0x1(%rcx),%esi
  sub    %ecx,%r8d
  cmp    %ecx,%r12d
  cmovle %eax,%r8d
  mov    %ebp,%eax
  sub    %ecx,%eax
  cmp    $0x6,%eax
  jbe    L29
  cmp    %ecx,%r12d
  jle    L29
  lea    0x2(%rcx),%eax
  movd   %esi,%xmm6
  lea    0x1(%rcx),%ebx
  movd   %eax,%xmm0
  lea    0x3(%rcx),%eax
  pshufd $0x0,%xmm6,%xmm4
  movd   %eax,%xmm3
  movd   %ecx,%xmm2
  movd   %ebx,%xmm6
  mov    %r8d,%eax
  punpckldq %xmm3,%xmm0
  shr    $0x2,%eax
  movd   %edi,%xmm3
  punpckldq %xmm6,%xmm2
  sub    $0x1,%eax
  pshufd $0x0,%xmm3,%xmm9
  pxor   %xmm1,%xmm1
  movdqa D9(%rip),%xmm3
  shl    $0x4,%rax
  punpcklqdq %xmm0,%xmm2
  movdqa %xmm1,%xmm8
  lea    0x10(%r13,%rax,1),%rdx
  mov    %r13,%rax
  nopl   (%rax)
L126:
  movdqu (%rax),%xmm0
  movdqa %xmm2,%xmm6
  add    $0x10,%rax
  paddd  %xmm7,%xmm2
  pcmpgtd %xmm9,%xmm0
  pcmpeqd %xmm8,%xmm0
  movdqa %xmm0,%xmm5
  pand   %xmm0,%xmm4
  pand   %xmm0,%xmm1
  pandn  %xmm6,%xmm5
  pandn  %xmm3,%xmm0
  paddd  %xmm7,%xmm3
  por    %xmm5,%xmm4
  por    %xmm0,%xmm1
  cmp    %rax,%rdx
  jne    L126
  pshufd $0x55,%xmm1,%xmm0
  movd   %xmm1,%r10d
  movd   %xmm0,%eax
  movd   %xmm0,%r9d
  movdqa %xmm1,%xmm0
  cmp    %eax,%r10d
  punpckhdq %xmm1,%xmm0
  cmovae %r10d,%r9d
  movd   %xmm0,%r11d
  cmp    %r11d,%r9d
  jb     L11
  pshufd $0x55,%xmm4,%xmm0
  cmp    %eax,%r10d
  movd   %xmm4,%eax
  movd   %xmm0,%edx
  cmovb  %edx,%eax
  mov    %eax,%r10d
L112:
  cmp    %r11d,%r9d
  pshufd $0xff,%xmm1,%xmm1
  pshufd $0xff,%xmm4,%xmm0
  cmovb  %r11d,%r9d
  movd   %xmm1,%eax
  movd   %xmm0,%edx
  cmp    %eax,%r9d
  mov    %r8d,%eax
  cmovae %r10d,%edx
  and    $0xfffffffc,%eax
  add    %eax,%ecx
  cmp    %eax,%r8d
  je     L149
L141:
  movslq %ecx,%r8
  cmp    %edi,(%r14,%r8,4)
  lea    0x0(,%r8,4),%rax
  lea    0x1(%rcx),%r8d
  cmovg  %ecx,%edx
  cmp    %r8d,%r12d
  jle    L149
  cmp    0x4(%r14,%rax,1),%edi
  cmovge %edx,%r8d
  lea    0x2(%rcx),%edx
  cmp    %edx,%r12d
  jle    L24
  cmp    0x8(%r14,%rax,1),%edi
  cmovge %r8d,%edx
  lea    0x3(%rcx),%r8d
  cmp    %r8d,%r12d
  jle    L149
  cmp    0xc(%r14,%rax,1),%edi
  lea    0x4(%rcx),%r9d
  cmovge %edx,%r8d
  cmp    %r12d,%r9d
  jge    L24
  cmp    0x10(%r14,%rax,1),%edi
  lea    0x5(%rcx),%edx
  cmovge %r8d,%r9d
  cmp    %edx,%r12d
  jle    L120
  cmp    0x14(%r14,%rax,1),%edi
  cmovge %r9d,%edx
  add    $0x6,%ecx
  cmp    %ecx,%r12d
  jle    L149
  cmp    0x18(%r14,%rax,1),%edi
  cmovl  %ecx,%edx
L149:
  mov    %r14,%rdi
  add    $0x4,%r13
  call   <swap@plt>
  cmp    %ebx,%r12d
  movdqa D11(%rip),%xmm7
  mov    %ebx,%ecx
  jne    L115
  add    $0x8,%rsp
  mov    %ebp,%edx
  mov    %ebp,%esi
  mov    %r14,%rdi
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1050 <swap@plt>
  nopl   (%rax)
L11:
  movdqa %xmm4,%xmm0
  punpckhdq %xmm4,%xmm0
  movd   %xmm0,%r10d
  jmp    L112
  nopw   0x0(%rax,%rax,1)
L24:
  mov    %r8d,%edx
  jmp    L149
L29:
  mov    %esi,%edx
  lea    0x1(%rcx),%ebx
  jmp    L141
L74:
  ret
L120:
  mov    %r9d,%edx
  jmp    L149
```

tool_calls: name: unpack_data
arguments: data_label: D11
type_infered: byte[16]
name: unpack_data
arguments: data_label: D9
type_infered: byte[16]

tool: {"D11": [0x04,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x04,0x00,0x00,0x00]}

tool: {"D9": [0x01,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x04,0x00,0x00,0x00]}

assistant: ```c
void selectOrder(int array[], int n) {
  if (n <= 1) {
    return;
  }
  for (int i = 0; i < n; i++) {
    int selectIndex = i;
    for (int j = i + 1; j < n; j++) {
      if (array[j] > array[i]) {
        selectIndex = j;
      }
    }
    swap(array, i, selectIndex);
  }
}
```