user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<print_multi_set_permutation>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  mov    %ecx,%r13d
  push   %r12
  push   %rbp
  push   %rbx
  mov    %rdx,%rbx
  sub    $0x38,%rsp
  cmp    %edi,%ecx
  je     L266
  test   %edi,%edi
  jle    L274
  movslq %ecx,%rax
  mov    %edi,%r9d
  mov    %rsi,%r12
  mov    %edi,%r8d
  lea    (%rdx,%rax,4),%rax
  and    $0xfffffffc,%r9d
  xor    %ebp,%ebp
  mov    %rax,0x10(%rsp)
  lea    -0x1(%rdi),%eax
  mov    %eax,0x8(%rsp)
  lea    -0x1(%rcx),%eax
  mov    %eax,0xc(%rsp)
  mov    %ecx,%eax
  shr    $0x2,%eax
  sub    $0x1,%eax
  shl    $0x4,%rax
  lea    0x10(%rdx,%rax,1),%r15
  mov    %ecx,%eax
  and    $0xfffffffc,%eax
  mov    %eax,0x18(%rsp)
  mov    %edi,%eax
  shr    $0x2,%eax
  sub    $0x1,%eax
  shl    $0x4,%rax
  lea    0x10(%rsi,%rax,1),%r14
  lea    0x1(%rcx),%eax
  mov    %eax,0x1c(%rsp)
L165:
  mov    (%r12,%rbp,4),%eax
  test   %rbp,%rbp
  je     L98
  cmp    %eax,-0x4(%r12,%rbp,4)
  jne    L98
L91:
  add    $0x1,%rbp
  cmp    %r8,%rbp
  jne    L165
L274:
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopw   0x0(%rax,%rax,1)
L98:
  test   %r13d,%r13d
  jle    L47
  cmpl   $0x2,0xc(%rsp)
  jbe    L306
  movd   %eax,%xmm4
  mov    %rbx,%rdx
  pxor   %xmm1,%xmm1
  pshufd $0x0,%xmm4,%xmm2
  nopl   0x0(%rax)
L178:
  movdqu (%rdx),%xmm0
  add    $0x10,%rdx
  pcmpeqd %xmm2,%xmm0
  psubd  %xmm0,%xmm1
  cmp    %rdx,%r15
  jne    L178
  movdqa %xmm1,%xmm0
  mov    0x18(%rsp),%esi
  psrldq $0x8,%xmm0
  paddd  %xmm0,%xmm1
  mov    %esi,%edx
  movdqa %xmm1,%xmm0
  psrldq $0x4,%xmm0
  paddd  %xmm0,%xmm1
  movd   %xmm1,%ecx
  cmp    %esi,%r13d
  je     L179
L114:
  movslq %edx,%rsi
  cmp    %eax,(%rbx,%rsi,4)
  lea    0x0(,%rsi,4),%r10
  sete   %sil
  movzbl %sil,%esi
  add    %esi,%ecx
  lea    0x1(%rdx),%esi
  cmp    %esi,%r13d
  jle    L179
  cmp    %eax,0x4(%rbx,%r10,1)
  je     L142
L130:
  add    $0x2,%edx
  cmp    %r13d,%edx
  jge    L179
  cmp    0x8(%rbx,%r10,1),%eax
  je     L287
L179:
  cmpl   $0x2,0x8(%rsp)
  jbe    L150
L97:
  movd   %eax,%xmm3
  mov    %r12,%rdx
  pxor   %xmm1,%xmm1
  pshufd $0x0,%xmm3,%xmm2
  nop
L140:
  movdqu (%rdx),%xmm0
  add    $0x10,%rdx
  pcmpeqd %xmm2,%xmm0
  psubd  %xmm0,%xmm1
  cmp    %rdx,%r14
  jne    L140
  movdqa %xmm1,%xmm0
  mov    %r9d,%esi
  psrldq $0x8,%xmm0
  paddd  %xmm0,%xmm1
  movdqa %xmm1,%xmm0
  psrldq $0x4,%xmm0
  paddd  %xmm0,%xmm1
  movd   %xmm1,%edx
  cmp    %edi,%r9d
  je     L138
L57:
  movslq %esi,%r10
  cmp    %eax,(%r12,%r10,4)
  lea    0x0(,%r10,4),%r11
  sete   %r10b
  movzbl %r10b,%r10d
  add    %r10d,%edx
  lea    0x1(%rsi),%r10d
  cmp    %edi,%r10d
  jge    L138
  cmp    %eax,0x4(%r12,%r11,1)
  jne    L123
  add    $0x1,%edx
L123:
  add    $0x2,%esi
  cmp    %esi,%edi
  jle    L138
  cmp    %eax,0x8(%r12,%r11,1)
  je     L279
L138:
  cmp    %edx,%ecx
  jge    L91
L155:
  mov    0x10(%rsp),%rcx
  mov    %rbx,%rdx
  mov    %r12,%rsi
  mov    %r8,0x28(%rsp)
  mov    %r9d,0x24(%rsp)
  mov    %eax,(%rcx)
  mov    0x1c(%rsp),%ecx
  mov    %edi,0x20(%rsp)
  call   <print_multi_set_permutation>
  mov    0x28(%rsp),%r8
  mov    0x24(%rsp),%r9d
  mov    0x20(%rsp),%edi
  jmp    L91
  nopl   (%rax)
L279:
  add    $0x1,%edx
  cmp    %edx,%ecx
  jge    L91
  jmp    L155
  nopl   (%rax)
L142:
  add    $0x1,%ecx
  jmp    L130
L287:
  add    $0x1,%ecx
  cmpl   $0x2,0x8(%rsp)
  ja     L97
  xchg   %ax,%ax
L150:
  xor    %edx,%edx
  xor    %esi,%esi
  jmp    L57
  nopl   0x0(%rax)
L266:
  test   %ecx,%ecx
  jle    L81
  lea    -0x1(%rcx),%eax
  lea    D9(%rip),%rbp
  lea    0x4(%rdx,%rax,4),%r12
  nopl   0x0(%rax,%rax,1)
L242:
  mov    (%rbx),%esi
  mov    %rbp,%rdi
  add    $0x4,%rbx
  call   <printf@plt>
  cmp    %rbx,%r12
  jne    L242
L81:
  add    $0x38,%rsp
  mov    $0xa,%edi
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1060 <putchar@plt>
  nopl   0x0(%rax,%rax,1)
L47:
  xor    %ecx,%ecx
  jmp    L179
L306:
  xor    %ecx,%ecx
  xor    %edx,%edx
  jmp    L114
```

tool_calls: name: parse_data
arguments: data_label: D9
type_infered: string

tool: D9: %3d

assistant: ```c
void print_multi_set_permutation(int n, int b[], int a[], int cur) {
  int i, j;
  if (cur == n) {
    for (i = 0; i < n; ++i)
      printf("%3d", a[i]);
    putchar('\n');
  } else
    for (i = 0; i < n; ++i) {
      if (!i || b[i] != b[i - 1]) {
        int c1, c2;
        c1 = c2 = 0;
        for (j = 0; j < cur; ++j)
          if (a[j] == b[i])
            c1++;
        for (j = 0; j < n; ++j)
          if (b[j] == b[i])
            c2++;
        if (c1 < c2) {
          a[cur] = b[i];
          print_multi_set_permutation(n, b, a, cur + 1);
        }
      }
    }
}
```