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

```asm
<quickSortGlobalEdgeTablefromto>:
  endbr64
  push   %r15
  movslq %edx,%rax
  push   %r14
  lea    0x1(%rax),%edx
  push   %r13
  sub    %esi,%edx
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x28,%rsp
  mov    %esi,0xc(%rsp)
  mov    %eax,0x10(%rsp)
  cmp    $0x1,%edx
  jle    L5
  lea    (%rdi,%rax,4),%rax
  mov    %rdi,%rbp
  mov    %edx,%r12d
  mov    %rax,0x18(%rsp)
  nopw   0x0(%rax,%rax,1)
L39:
  movslq 0xc(%rsp),%rax
  mov    0x18(%rsp),%r14
  lea    0x0(%rbp,%rax,4),%r13
  mov    (%r14),%r15d
  mov    0x0(%r13),%ebx
  mov    %r15d,%esi
  mov    %ebx,%edi
  call   <getSortsbefore@plt>
  test   %eax,%eax
  jne    L41
  mov    0x0(%r13),%eax
  mov    (%r14),%ecx
  mov    %ecx,0x0(%r13)
  mov    %eax,(%r14)
  mov    %ebx,%eax
  mov    %r15d,%ebx
  mov    %eax,%r15d
L41:
  cmp    $0x2,%r12d
  je     L5
  mov    0x10(%rsp),%eax
  add    0xc(%rsp),%eax
  mov    %ebx,%edi
  sar    %eax
  cltq
  lea    0x0(%rbp,%rax,4),%r14
  mov    (%r14),%r8d
  mov    %r8d,%esi
  mov    %r8d,0x14(%rsp)
  call   <getSortsbefore@plt>
  mov    0x14(%rsp),%r8d
  test   %eax,%eax
  jne    L85
  mov    0x0(%r13),%eax
  mov    (%r14),%esi
  mov    %esi,0x0(%r13)
  mov    %eax,(%r14)
L119:
  cmp    $0x3,%r12d
  je     L5
L110:
  mov    0xc(%rsp),%r15d
  mov    0x10(%rsp),%r12d
  cs nopw 0x0(%rax,%rax,1)
L82:
  lea    -0x1(%r12),%r13d
  movslq %r13d,%r13
  nopl   0x0(%rax,%rax,1)
L116:
  mov    %r13d,%r12d
  cmp    %r13d,%r15d
  jg     L31
  mov    0x0(%rbp,%r13,4),%esi
  mov    %ebx,%edi
  sub    $0x1,%r13
  call   <getSortsbefore@plt>
  test   %eax,%eax
  jne    L116
L31:
  movslq %r15d,%rax
  lea    0x4(%rbp,%rax,4),%r14
  nopl   0x0(%rax)
L77:
  mov    %r15d,%r13d
  add    $0x1,%r15d
  cmp    %r12d,%r15d
  jg     L35
  mov    (%r14),%edi
  mov    %ebx,%esi
  mov    %r14,%r13
  add    $0x4,%r14
  call   <getSortsbefore@plt>
  test   %eax,%eax
  jne    L77
  movslq %r12d,%rax
  mov    0x0(%r13),%edx
  lea    0x0(%rbp,%rax,4),%rax
  mov    (%rax),%esi
  mov    %esi,0x0(%r13)
  mov    %edx,(%rax)
  jmp    L82
  nop
L35:
  mov    0xc(%rsp),%esi
  mov    %r12d,%edx
  mov    %rbp,%rdi
  call   <quickSortGlobalEdgeTablefromto>
  mov    0x10(%rsp),%r12d
  sub    %r13d,%r12d
  cmp    $0x1,%r12d
  jle    L5
  mov    %r15d,0xc(%rsp)
  jmp    L39
L85:
  mov    %r15d,%esi
  mov    %r8d,%edi
  call   <getSortsbefore@plt>
  mov    0x14(%rsp),%ebx
  test   %eax,%eax
  jne    L119
  mov    0x18(%rsp),%rcx
  mov    (%r14),%esi
  mov    %r15d,%ebx
  mov    (%rcx),%eax
  mov    %esi,(%rcx)
  mov    %eax,(%r14)
  cmp    $0x3,%r12d
  jne    L110
L5:
  add    $0x28,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

assistant: ```c
int quickSortGlobalEdgeTablefromto(int *array, int i, int j) {
  int k;
  int again;
  int tt;
  int di;
  int n;
  int l;
  int dj;
  int before;
  int dij;
  int ij;
  int tmp;
  if ((n = (j + 1) - i) <= 1) {
    return 0;
  }
  di = array[i];
  dj = array[j];
  before = getSortsbefore(di, dj);
  if (!(before)) {
    tmp = array[i];
    array[i] = (array[j]);
    array[j] = tmp;
    tt = di;
    di = dj;
    dj = tt;
  }
  if (n <= 2) {
    return 0;
  }
  ij = ((int)(i + j) >> 1);
  dij = array[ij];
  before = getSortsbefore(di, dij);
  if (before) {
    before = getSortsbefore(dij, dj);
    if (!(before)) {
      tmp = array[j];
      array[j] = (array[ij]);
      array[ij] = tmp;
      dij = dj;
    }
  } else {
    tmp = array[i];
    array[i] = (array[ij]);
    array[ij] = tmp;
    dij = di;
  }
  if (n <= 3) {
    return 0;
  }
  k = i;
  l = j;
  again = 1;
  while (again) {
    before = 1;
    while (before) {
      if (k <= (l -= 1)) {
        tmp = array[l];
        before = getSortsbefore(dij, tmp);
      } else {
        before = 0;
      }
    }
    before = 1;
    while (before) {
      if ((k += 1) <= l) {
        tmp = array[k];
        before = getSortsbefore(tmp, dij);
      } else {
        before = 0;
      }
    }
    again = k <= l;
    if (again) {
      tmp = array[k];
      array[k] = (array[l]);
      array[l] = tmp;
    }
  }
  quickSortGlobalEdgeTablefromto(array, i, l);
  quickSortGlobalEdgeTablefromto(array, k, j);
}
```