user: Translate the below assembly code into C programming language:

```asm
<qsort_int>:
  endbr64
  push   %r15
  push   %r14
  mov    $0x1,%r14d
  push   %r13
  xor    %r13d,%r13d
  push   %r12
  lea    -0x1(%rsi),%r12d
  push   %rbp
  mov    %r12d,%r15d
  xor    %ebp,%ebp
  push   %rbx
  sub    %ebp,%r15d
  mov    %rdi,%rbx
  add    $0x1,%r15d
  sub    $0x228,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x218(%rsp)
  xor    %eax,%eax
  movl   $0x0,0x10(%rsp)
  mov    %r12d,0x14(%rsp)
  cmp    $0x1,%r15d
  jle    L140
  nopl   0x0(%rax,%rax,1)
L110:
  xor    %eax,%eax
  cmp    $0xf,%r15d
  jle    L100
  call   <rand@plt>
  cltd
  idiv   %r15d
  lea    (%rdx,%rbp,1),%eax
  cltq
  mov    (%rbx,%rax,4),%ecx
  xor    %eax,%eax
  mov    %ecx,0xc(%rsp)
  call   <rand@plt>
  cltd
  idiv   %r15d
  lea    (%rdx,%rbp,1),%eax
  cltq
  mov    (%rbx,%rax,4),%esi
  xor    %eax,%eax
  mov    %esi,0x8(%rsp)
  call   <rand@plt>
  mov    0x8(%rsp),%esi
  mov    0xc(%rsp),%ecx
  cltd
  idiv   %r15d
  cmp    %esi,%ecx
  cmovl  %esi,%ecx
  lea    (%rdx,%rbp,1),%eax
  cltq
  mov    (%rbx,%rax,4),%eax
  cmp    %eax,%ecx
  cmovle %ecx,%eax
  mov    %eax,%edi
L107:
  movslq %ebp,%rax
  mov    %ebp,%r8d
  lea    0x1(%rbp),%r10d
  mov    %r12d,%edx
  lea    (%rbx,%rax,4),%r9
  movslq %r12d,%rax
  nopl   0x0(%rax,%rax,1)
L148:
  mov    (%r9),%r11d
  lea    (%rbx,%rax,4),%rsi
  mov    %r8d,%r15d
  mov    (%rsi),%ecx
  cmp    %edi,%r11d
  jl     L22
  cmp    %ecx,%edi
  jge    L59
  lea    -0x4(%rbx,%rax,4),%rax
  cs nopw 0x0(%rax,%rax,1)
L176:
  mov    %rax,%rsi
  mov    (%rax),%ecx
  sub    $0x4,%rax
  sub    $0x1,%edx
  cmp    %edi,%ecx
  jg     L176
L59:
  cmp    %edx,%r8d
  jle    L55
L171:
  movd   %r15d,%xmm0
  movd   %r12d,%xmm1
  punpckldq %xmm1,%xmm0
  cmp    %ebp,%edx
  jle    L157
  movslq %r13d,%rax
  mov    %edx,0x14(%rsp,%rax,8)
  cmp    %r12d,%r15d
  jge    L1
  movslq %r14d,%rax
  add    $0x1,%r14d
  lea    -0x1(%r14),%r13d
L15:
  movq   %xmm0,0x10(%rsp,%rax,8)
L179:
  mov    0x10(%rsp,%rax,8),%ebp
  mov    %r12d,%r15d
  sub    %ebp,%r15d
  add    $0x1,%r15d
  cmp    $0x1,%r15d
  jg     L110
L140:
  test   %r13d,%r13d
  je     L41
  lea    -0x2(%r14),%eax
  mov    %r13d,%r14d
  sub    $0x1,%r13d
  cltq
  mov    0x14(%rsp,%rax,8),%r12d
  jmp    L179
  nopl   (%rax)
L55:
  sub    $0x1,%edx
  mov    %ecx,(%r9)
  mov    %r10d,%r15d
  mov    %r11d,(%rsi)
  cmp    %edx,%r10d
  jg     L171
  movslq %edx,%rax
L22:
  add    $0x4,%r9
  add    $0x1,%r10d
  add    $0x1,%r8d
  jmp    L148
L100:
  call   <rand@plt>
  cltd
  idiv   %r15d
  lea    (%rdx,%rbp,1),%eax
  cltq
  mov    (%rbx,%rax,4),%edi
  jmp    L107
L157:
  cmp    %r12d,%r15d
  jge    L140
  movslq %r13d,%rax
  jmp    L15
L1:
  mov    %edx,%r12d
  jmp    L179
L41:
  mov    0x218(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L75
  add    $0x228,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L75:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
void qsort_int(int v[], const size_t n) {
  int stack[64][2];
  int l, r, i, j, p;
  stack[0][0] = 0;
  stack[0][1] = n - 1;
  int depth = 1;
  int selements[3];
PARTITION:
  --depth;
  l = stack[depth][0];
  r = stack[depth][1];
  int psize = r - l + 1;
  if (psize < 2)
    goto NEXT_PARTITION;
  if (psize >= 16) {
    selements[0] = v[l + rand() % psize];
    selements[1] = v[l + rand() % psize];
    selements[2] = v[l + rand() % psize];
    if (selements[0] > selements[1]) {
      int t = selements[0];
      selements[0] = selements[1];
      selements[1] = t;
    };
    if (selements[1] > selements[2]) {
      int t = selements[1];
      selements[1] = selements[2];
      selements[2] = t;
    };
    if (selements[0] > selements[2]) {
      int t = selements[0];
      selements[0] = selements[2];
      selements[2] = t;
    };
    p = selements[1];
  } else
    p = v[l + rand() % psize];
  i = l;
  j = r;
  do {
    while (v[i] < p)
      ++i;
    while (v[j] > p)
      --j;
    if (i <= j) {
      {
        int t = v[i];
        v[i] = v[j];
        v[j] = t;
      };
      ++i;
      --j;
    }
  } while (i <= j);
  if (l < j) {
    stack[depth][0] = l;
    stack[depth][1] = j;
    depth++;
  }
  if (i < r) {
    stack[depth][0] = i;
    stack[depth][1] = r;
    depth++;
  }
NEXT_PARTITION:
  if (depth > 0)
    goto PARTITION;
}
```