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

```asm
<_lqsort>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbx
  sub    $0x28,%rsp
  mov    %rdi,%r13
  mov    %esi,-0x44(%rbp)
  mov    %edx,%r14d
  mov    %rcx,-0x50(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  xor    %eax,%eax
  lea    -0x40(%rbp),%r15
  jmp    L41
L44:
  mov    -0x44(%rbp),%ebx
  mov    %r14d,%r12d
  lea    (%rbx,%r12,1),%eax
  sar    %eax
  mov    %eax,%ecx
  movslq %ecx,%rax
  shl    $0x3,%rax
  add    %r13,%rax
  mov    (%rax),%rax
  mov    %rax,(%r15)
  movslq %ebx,%rax
  shl    $0x3,%rax
  add    %r13,%rax
  movslq %ecx,%rdx
  shl    $0x3,%rdx
  add    %r13,%rdx
  mov    (%rax),%rax
  mov    %rax,(%rdx)
  movslq %ebx,%rax
  shl    $0x3,%rax
  lea    0x0(%r13,%rax,1),%rdx
  mov    (%r15),%rax
  mov    %rax,(%rdx)
  jmp    L32
L40:
  sub    $0x1,%r12d
L74:
  movslq %r12d,%rax
  shl    $0x3,%rax
  add    %r13,%rax
  mov    %r15,%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  mov    -0x50(%rbp),%rcx
  call   *%rcx
  test   %eax,%eax
  jle    L40
  movslq %r12d,%rax
  shl    $0x3,%rax
  add    %r13,%rax
  movslq %ebx,%rdx
  shl    $0x3,%rdx
  add    %r13,%rdx
  mov    (%rax),%rax
  mov    %rax,(%rdx)
  jmp    L104
L46:
  add    $0x1,%ebx
L104:
  cmp    %r12d,%ebx
  jge    L26
  movslq %ebx,%rax
  shl    $0x3,%rax
  add    %r13,%rax
  mov    %r15,%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  mov    -0x50(%rbp),%rcx
  call   *%rcx
  test   %eax,%eax
  jg     L46
L26:
  movslq %ebx,%rax
  shl    $0x3,%rax
  add    %r13,%rax
  movslq %r12d,%rdx
  shl    $0x3,%rdx
  add    %r13,%rdx
  mov    (%rax),%rax
  mov    %rax,(%rdx)
L32:
  cmp    %r12d,%ebx
  jl     L74
  movslq %ebx,%rax
  shl    $0x3,%rax
  lea    0x0(%r13,%rax,1),%rdx
  mov    (%r15),%rax
  mov    %rax,(%rdx)
  mov    %ebx,%edx
  mov    -0x44(%rbp),%esi
  sub    %esi,%edx
  mov    %r14d,%eax
  sub    %ebx,%eax
  cmp    %eax,%edx
  jge    L11
  lea    -0x1(%rbx),%eax
  mov    -0x50(%rbp),%rcx
  mov    %eax,%edx
  mov    %r13,%rdi
  mov    $0x0,%eax
  call   <_lqsort>
  lea    0x1(%rbx),%eax
  mov    %eax,-0x44(%rbp)
  jmp    L41
L11:
  lea    0x1(%rbx),%eax
  mov    -0x50(%rbp),%rcx
  mov    %r14d,%edx
  mov    %eax,%esi
  mov    %r13,%rdi
  mov    $0x0,%eax
  call   <_lqsort>
  lea    -0x1(%rbx),%r14d
L41:
  cmp    -0x44(%rbp),%r14d
  jg     L44
  nop
  mov    -0x38(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L89
  call   <__stack_chk_fail@plt>
L89:
  add    $0x28,%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
```

assistant: ```c
_lqsort(base, lo, hi, cmp) register long *base;
register int lo;
register int hi;
register int (*cmp)();
{
  long k;
  register int i, j, t;
  register long *p = &k;
  while (hi > lo) {
    i = lo;
    j = hi;
    t = ((i + j) >> 1);
    *p = base[t];
    base[t] = base[i];
    base[i] = *p;
    while (i < j) {
      while (((*cmp)((base + j), p)) <= 0)
        --j;
      base[i] = base[j];
      while ((i < j) && (((*cmp)((base + i), p)) > 0))
        ++i;
      base[j] = base[i];
    }
    base[i] = *p;
    if ((i - lo) < (hi - i)) {
      _lqsort(base, lo, (i - 1), cmp);
      lo = i + 1;
    } else {
      _lqsort(base, (i + 1), hi, cmp);
      hi = i - 1;
    }
  }
}
```