user: What is the c source code of the assembly code below?

```asm
<_next_permutation>:
  endbr64
  mov    %esi,%edx
  sub    $0x2,%edx
  js     L10
  push   %r13
  mov    %rdi,%r8
  push   %r12
  push   %rbp
  push   %rbx
  movslq %esi,%rbx
  shl    $0x2,%rbx
  lea    -0x8(%rbx),%r11
  mov    -0x4(%rdi,%rbx,1),%eax
  lea    (%rdi,%r11,1),%rcx
  jmp    L73
  nopl   (%rax)
L44:
  sub    $0x1,%edx
  sub    $0x4,%rcx
  cmp    $0xffffffff,%edx
  je     L145
L73:
  mov    %eax,%edi
  mov    (%rcx),%eax
  cmp    %edi,%eax
  jle    L44
  lea    -0x4(%r8,%rbx,1),%r12
  lea    -0x1(%rsi),%r10d
  mov    (%r12),%r9d
  movslq %r10d,%rbp
  lea    -0x4(%r8,%rbp,4),%rdi
  cmp    %r9d,%eax
  jg     L85
  nopw   0x0(%rax,%rax,1)
L17:
  mov    %rdi,%r12
  mov    (%rdi),%r9d
  sub    $0x4,%rdi
  cmp    %r9d,%eax
  jle    L17
L85:
  mov    %r9d,(%rcx)
  mov    %eax,(%r12)
  lea    0x1(%rdx),%eax
  cmp    %eax,%r10d
  jle    L71
  sub    $0x3,%esi
  movslq %eax,%rdi
  sub    %edx,%esi
  lea    0x0(,%rdi,4),%rdx
  mov    %esi,%r12d
  shr    %r12d
  lea    0x1(%r12),%ecx
  lea    (%rcx,%rdi,1),%r13
  mov    %rcx,%r9
  neg    %rcx
  shl    $0x2,%r13
  lea    (%rbx,%rcx,4),%rcx
  cmp    %rcx,%r13
  setle  %cl
  cmp    %rbx,%rdx
  setge  %r13b
  or     %r13b,%cl
  je     L77
  cmp    $0x1,%esi
  jbe    L77
  cmp    $0x5,%esi
  jbe    L67
  mov    %r9d,%ecx
  lea    (%r8,%rdx,1),%rsi
  lea    -0x10(%r8,%rbx,1),%rdx
  shr    $0x2,%ecx
  lea    -0x1(%rcx),%ebx
  lea    0x10(%rsi),%rcx
  shl    $0x4,%rbx
  add    %rcx,%rbx
  jmp    L175
  xchg   %ax,%ax
L156:
  add    $0x10,%rcx
L175:
  movdqu (%rsi),%xmm0
  movdqu (%rdx),%xmm2
  sub    $0x10,%rdx
  pshufd $0x1b,%xmm2,%xmm1
  pshufd $0x1b,%xmm0,%xmm0
  movups %xmm1,(%rsi)
  mov    %rcx,%rsi
  movups %xmm0,0x10(%rdx)
  cmp    %rbx,%rcx
  jne    L156
  mov    %r9d,%edx
  and    $0xfffffffc,%edx
  add    %edx,%eax
  sub    %edx,%r10d
  cmp    %edx,%r9d
  je     L71
L100:
  sub    %edx,%r9d
  cmp    %edx,%r12d
  je     L43
  add    %rdx,%rdi
  neg    %rdx
  lea    (%r11,%rdx,4),%rdx
  lea    (%r8,%rdi,4),%rcx
  add    %r8,%rdx
  movq   (%rcx),%xmm0
  movq   (%rdx),%xmm1
  pshufd $0xe1,%xmm0,%xmm0
  pshufd $0xe1,%xmm1,%xmm1
  movq   %xmm1,(%rcx)
  movq   %xmm0,(%rdx)
  mov    %r9d,%edx
  and    $0xfffffffe,%edx
  add    %edx,%eax
  sub    %edx,%r10d
  cmp    %edx,%r9d
  je     L71
L43:
  cltq
  movslq %r10d,%r10
  lea    (%r8,%rax,4),%rdx
  lea    (%r8,%r10,4),%rax
  mov    (%rdx),%ecx
  mov    (%rax),%esi
  mov    %esi,(%rdx)
  mov    %ecx,(%rax)
L71:
  pop    %rbx
  mov    $0x1,%eax
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
  nopl   (%rax)
L77:
  mov    (%r8,%rdi,4),%eax
  mov    (%r8,%rbp,4),%edx
  mov    %edx,(%r8,%rdi,4)
  add    $0x1,%rdi
  mov    %eax,(%r8,%rbp,4)
  sub    $0x1,%rbp
  cmp    %edi,%ebp
  jg     L77
  jmp    L71
  xchg   %ax,%ax
L145:
  pop    %rbx
  xor    %eax,%eax
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
L10:
  xor    %eax,%eax
  ret
L67:
  xor    %edx,%edx
  jmp    L100
```

assistant: ```c
int _next_permutation(int *vetor, int n) {
  int i, j;
  for (i = n - 2; i >= 0; --i) {
    if (vetor[i] > vetor[i + 1]) {
      for (j = n - 1;; --j) {
        if (vetor[j] < vetor[i]) {
          int t = vetor[i];
          vetor[i] = vetor[j];
          vetor[j] = t;
          for (++i, j = n - 1; i < j; ++i, --j) {
            t = vetor[i];
            vetor[i] = vetor[j];
            vetor[j] = t;
          }
          return 1;
        }
      }
    }
  }
  return 0;
}
```