user: 请显示与下面列出的汇编代码相匹配的C语言实现:

```asm
<_bucket_sort>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r15
  mov    %esi,%r15d
  push   %r14
  push   %r13
  push   %r12
  push   %rbx
  sub    $0x48,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  mov    (%rdi),%eax
  mov    %rsp,%rcx
  mov    %eax,-0x64(%rbp)
  movslq %esi,%rax
  lea    0xf(,%rax,4),%rax
  mov    %rax,%rdx
  and    $0xfffffffffffff000,%rax
  sub    %rax,%rcx
  and    $0xfffffffffffffff0,%rdx
  cmp    %rcx,%rsp
  je     L175
L39:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rcx,%rsp
  jne    L39
L175:
  and    $0xfff,%edx
  sub    %rdx,%rsp
  test   %rdx,%rdx
  jne    L144
L53:
  mov    %rsp,%r13
  test   %r15d,%r15d
  jle    L44
  lea    -0x1(%r15),%eax
  cmp    $0x2,%eax
  jbe    L24
  mov    %r15d,%edx
  movd   -0x64(%rbp),%xmm3
  mov    %rdi,%rax
  shr    $0x2,%edx
  sub    $0x1,%edx
  pshufd $0x0,%xmm3,%xmm2
  shl    $0x4,%rdx
  lea    0x10(%rdi,%rdx,1),%rdx
  nopl   0x0(%rax)
L105:
  movdqu (%rax),%xmm0
  add    $0x10,%rax
  movdqa %xmm0,%xmm1
  pcmpgtd %xmm2,%xmm1
  pand   %xmm1,%xmm0
  pandn  %xmm2,%xmm1
  movdqa %xmm1,%xmm2
  por    %xmm0,%xmm2
  cmp    %rdx,%rax
  jne    L105
  movdqa %xmm2,%xmm1
  mov    %r15d,%eax
  psrldq $0x8,%xmm1
  and    $0xfffffffc,%eax
  movdqa %xmm1,%xmm0
  pcmpgtd %xmm2,%xmm0
  pand   %xmm0,%xmm1
  pandn  %xmm2,%xmm0
  por    %xmm1,%xmm0
  movdqa %xmm0,%xmm2
  psrldq $0x4,%xmm2
  movdqa %xmm2,%xmm1
  pcmpgtd %xmm0,%xmm1
  pand   %xmm1,%xmm2
  pandn  %xmm0,%xmm1
  por    %xmm2,%xmm1
  movd   %xmm1,-0x64(%rbp)
  test   $0x3,%r15b
  je     L44
L37:
  movslq %eax,%rdx
  mov    -0x64(%rbp),%esi
  lea    0x0(,%rdx,4),%rcx
  mov    (%rdi,%rdx,4),%edx
  cmp    %edx,%esi
  cmovge %esi,%edx
  mov    %edx,-0x64(%rbp)
  mov    %edx,%esi
  lea    0x1(%rax),%edx
  cmp    %edx,%r15d
  jle    L44
  mov    0x4(%rdi,%rcx,1),%edx
  cmp    %edx,%esi
  cmovge %esi,%edx
  add    $0x2,%eax
  mov    %edx,-0x64(%rbp)
  cmp    %eax,%r15d
  jle    L44
  mov    0x8(%rdi,%rcx,1),%eax
  cmp    %eax,%edx
  cmovge %edx,%eax
  mov    %eax,-0x64(%rbp)
L44:
  mov    -0x64(%rbp),%eax
  test   %eax,%eax
  jle    L143
  lea    -0x1(%r15),%eax
  mov    $0x1,%ebx
  mov    %rax,%r12
  lea    0x4(%rdi,%rax,4),%r14
  lea    0x4(,%rax,4),%rax
  mov    %rax,-0x70(%rbp)
  nopl   0x0(%rax,%rax,1)
L118:
  pxor   %xmm0,%xmm0
  movq   $0x0,-0x40(%rbp)
  movaps %xmm0,-0x60(%rbp)
  movaps %xmm0,-0x50(%rbp)
  test   %r15d,%r15d
  jle    L196
  mov    %rdi,%rcx
L51:
  mov    (%rcx),%eax
  add    $0x4,%rcx
  cltd
  idiv   %ebx
  movslq %eax,%rdx
  mov    %eax,%r9d
  imul   $0x66666667,%rdx,%rdx
  sar    $0x1f,%r9d
  sar    $0x22,%rdx
  sub    %r9d,%edx
  lea    (%rdx,%rdx,4),%r9d
  add    %r9d,%r9d
  sub    %r9d,%eax
  movslq %eax,%rdx
  addl   $0x1,-0x60(%rbp,%rdx,4)
  cmp    %r14,%rcx
  jne    L51
  mov    -0x58(%rbp),%ecx
  mov    -0x60(%rbp),%r10d
  mov    -0x54(%rbp),%r11d
  add    -0x5c(%rbp),%r10d
  add    %r10d,%ecx
  mov    -0x50(%rbp),%eax
  mov    -0x4c(%rbp),%r9d
  movd   %r10d,%xmm4
  add    %ecx,%r11d
  mov    -0x48(%rbp),%edx
  movd   -0x60(%rbp),%xmm0
  movd   %ecx,%xmm1
  add    %r11d,%eax
  mov    -0x44(%rbp),%ecx
  movd   %r11d,%xmm3
  movdqu -0x5c(%rbp),%xmm2
  add    %eax,%r9d
  punpckldq %xmm3,%xmm1
  punpckldq %xmm4,%xmm0
  movdqu -0x4c(%rbp),%xmm7
  add    %r9d,%edx
  punpcklqdq %xmm1,%xmm0
  movd   %r9d,%xmm6
  add    %edx,%ecx
  paddd  %xmm0,%xmm2
  movd   %edx,%xmm1
  movd   %eax,%xmm0
  movd   %ecx,%xmm5
  punpckldq %xmm5,%xmm1
  punpckldq %xmm6,%xmm0
  punpcklqdq %xmm1,%xmm0
  paddd  %xmm7,%xmm0
  pshufd $0xff,%xmm0,%xmm1
  movd   %xmm1,%eax
  add    -0x3c(%rbp),%eax
L7:
  mov    %eax,-0x3c(%rbp)
  movslq %r12d,%rcx
  movups %xmm2,-0x5c(%rbp)
  movups %xmm0,-0x4c(%rbp)
  test   %r12d,%r12d
  js     L56
  nopw   0x0(%rax,%rax,1)
L4:
  mov    (%rdi,%rcx,4),%r9d
  sub    $0x1,%rcx
  mov    %r9d,%eax
  cltd
  idiv   %ebx
  movslq %eax,%rdx
  mov    %eax,%r10d
  imul   $0x66666667,%rdx,%rdx
  sar    $0x1f,%r10d
  sar    $0x22,%rdx
  sub    %r10d,%edx
  lea    (%rdx,%rdx,4),%r10d
  add    %r10d,%r10d
  sub    %r10d,%eax
  movslq %eax,%rdx
  mov    -0x60(%rbp,%rdx,4),%eax
  sub    $0x1,%eax
  mov    %eax,-0x60(%rbp,%rdx,4)
  cltq
  mov    %r9d,0x0(%r13,%rax,4)
  test   %ecx,%ecx
  jns    L4
L56:
  test   %r15d,%r15d
  jle    L168
  mov    -0x70(%rbp),%rdx
  mov    %r13,%rsi
  call   <memcpy@plt>
  mov    %rax,%rdi
L168:
  mov    -0x64(%rbp),%eax
  lea    (%rbx,%rbx,4),%ebx
  add    %ebx,%ebx
  cltd
  idiv   %ebx
  test   %eax,%eax
  jne    L118
L143:
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  jne    L89
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
  cs nopw 0x0(%rax,%rax,1)
L196:
  pxor   %xmm0,%xmm0
  xor    %eax,%eax
  movdqa %xmm0,%xmm2
  jmp    L7
L144:
  orq    $0x0,-0x8(%rsp,%rdx,1)
  jmp    L53
L24:
  xor    %eax,%eax
  jmp    L37
L89:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
void _bucket_sort(int *vet, int s) {
  int i;
  int max = vet[0];
  int exp = 1;
  int sorted[s];
  for (i = 0; i < s; i++)
    if (vet[i] > max)
      max = vet[i];
  while (max / exp > 0) {
    int buckets[10] = {0};
    for (i = 0; i < s; i++)
      buckets[(vet[i] / exp) % 10]++;
    for (i = 1; i < 10; i++)
      buckets[i] += buckets[i - 1];
    for (i = s - 1; i >= 0; i--)
      sorted[--buckets[(vet[i] / exp) % 10]] = vet[i];
    for (i = 0; i < s; i++)
      vet[i] = sorted[i];
    exp *= 10;
  }
}
```