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

```asm
<pad_bin>:
  endbr64
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %esi,%ebp
  push   %rbx
  lea    0x1(%rbp),%r13d
  mov    %rdi,%rbx
  call   <strlen@plt>
  mov    %r13d,%edi
  mov    %rax,%r14
  call   <malloc@plt>
  xor    %esi,%esi
  mov    %r13d,%edx
  mov    %rax,%rdi
  mov    %rax,%r12
  call   <memset@plt>
  test   %ebp,%ebp
  je     L284
  js     L139
  mov    %ebp,%eax
  sub    %r14d,%eax
  test   %eax,%eax
  jle    L214
  cmp    %eax,%r13d
  mov    $0x1,%esi
  cmovle %r13d,%eax
  test   %eax,%eax
  mov    %eax,%edx
  cmovg  %eax,%esi
  cmp    $0xf,%eax
  jle    L9
  mov    %esi,%ecx
  movdqa D59(%rip),%xmm1
  movdqa D44(%rip),%xmm4
  mov    %r12,%rax
  shr    $0x4,%ecx
  movdqa D2(%rip),%xmm3
  movdqa D38(%rip),%xmm2
  sub    $0x1,%ecx
  shl    $0x4,%rcx
  lea    0x10(%r12,%rcx,1),%rcx
L167:
  movdqa %xmm1,%xmm0
  movups %xmm3,(%rax)
  add    $0x10,%rax
  paddd  %xmm4,%xmm1
  paddd  %xmm2,%xmm0
  cmp    %rcx,%rax
  jne    L167
  mov    %esi,%edi
  pshufd $0xff,%xmm0,%xmm0
  and    $0xfffffff0,%edi
  movd   %xmm0,%eax
  mov    %edi,%ecx
  cmp    %edi,%esi
  je     L32
L222:
  sub    %edi,%esi
  lea    -0x1(%rsi),%eax
  cmp    $0x6,%eax
  jbe    L199
  mov    D2(%rip),%rax
  movd   %ecx,%xmm0
  movq   D37(%rip),%xmm1
  mov    %rax,(%r12,%rdi,1)
  lea    0x1(%rcx),%eax
  mov    %esi,%edi
  movd   %eax,%xmm6
  and    $0xfffffff8,%edi
  punpckldq %xmm6,%xmm0
  add    %edi,%ecx
  paddd  %xmm1,%xmm0
  pshufd $0xe5,%xmm0,%xmm7
  movd   %xmm7,%eax
  cmp    %edi,%esi
  je     L32
L199:
  movslq %ecx,%rax
  movb   $0x30,(%r12,%rax,1)
  lea    0x1(%rcx),%eax
  cmp    %eax,%edx
  jle    L32
  cltq
  movb   $0x30,(%r12,%rax,1)
  lea    0x2(%rcx),%eax
  cmp    %eax,%edx
  jle    L32
  cltq
  movb   $0x30,(%r12,%rax,1)
  lea    0x3(%rcx),%eax
  cmp    %eax,%edx
  jle    L32
  cltq
  movb   $0x30,(%r12,%rax,1)
  lea    0x4(%rcx),%eax
  cmp    %eax,%edx
  jle    L32
  cltq
  movb   $0x30,(%r12,%rax,1)
  lea    0x5(%rcx),%eax
  cmp    %eax,%edx
  jle    L32
  cltq
  movb   $0x30,(%r12,%rax,1)
  lea    0x6(%rcx),%eax
  cmp    %eax,%edx
  jle    L32
  cltq
  movb   $0x30,(%r12,%rax,1)
  lea    0x7(%rcx),%eax
L32:
  cmp    %eax,%ebp
  jl     L139
L318:
  mov    %ebp,%esi
  movslq %eax,%rdx
  sub    %eax,%esi
  lea    (%r12,%rdx,1),%r8
  cmp    $0x6,%esi
  seta   %dil
  cmp    %eax,%ebp
  setge  %cl
  test   %cl,%dil
  je     L285
  lea    0x1(%rbx),%rdi
  mov    %r8,%rcx
  sub    %rdi,%rcx
  cmp    $0xe,%rcx
  jbe    L285
  lea    0x1(%rsi),%edx
  cmp    %eax,%ebp
  mov    $0x1,%ecx
  cmovge %edx,%ecx
  cmp    $0xe,%esi
  jbe    L134
  mov    %ecx,%esi
  xor    %edx,%edx
  shr    $0x4,%esi
  shl    $0x4,%rsi
L12:
  movdqu (%rbx,%rdx,1),%xmm5
  movups %xmm5,(%r8,%rdx,1)
  add    $0x10,%rdx
  cmp    %rdx,%rsi
  jne    L12
  mov    %ecx,%esi
  and    $0xfffffff0,%esi
  mov    %esi,%edi
  add    %esi,%eax
  cmp    %esi,%ecx
  je     L139
L251:
  mov    %ecx,%edx
  sub    %esi,%edx
  lea    -0x1(%rdx),%ecx
  cmp    $0x6,%ecx
  jbe    L278
  mov    (%rbx,%rsi,1),%rcx
  mov    %rcx,(%r8,%rsi,1)
  mov    %edx,%ecx
  and    $0xfffffff8,%ecx
  add    %ecx,%eax
  add    %ecx,%edi
  cmp    %ecx,%edx
  je     L139
L278:
  movslq %edi,%rdx
  lea    0x1(%rdi),%ecx
  movzbl (%rbx,%rdx,1),%esi
  movslq %eax,%rdx
  mov    %sil,(%r12,%rdx,1)
  lea    0x1(%rax),%edx
  cmp    %edx,%ebp
  jl     L139
  movslq %ecx,%rcx
  movslq %edx,%rdx
  movzbl (%rbx,%rcx,1),%esi
  lea    0x2(%rdi),%ecx
  mov    %sil,(%r12,%rdx,1)
  lea    0x2(%rax),%edx
  cmp    %edx,%ebp
  jl     L139
  movslq %ecx,%rcx
  movslq %edx,%rdx
  movzbl (%rbx,%rcx,1),%esi
  lea    0x3(%rdi),%ecx
  mov    %sil,(%r12,%rdx,1)
  lea    0x3(%rax),%edx
  cmp    %edx,%ebp
  jl     L139
  movslq %ecx,%rcx
  movslq %edx,%rdx
  movzbl (%rbx,%rcx,1),%esi
  lea    0x4(%rdi),%ecx
  mov    %sil,(%r12,%rdx,1)
  lea    0x4(%rax),%edx
  cmp    %ebp,%edx
  jg     L139
  movslq %ecx,%rcx
  movslq %edx,%rdx
  movzbl (%rbx,%rcx,1),%esi
  lea    0x5(%rdi),%ecx
  mov    %sil,(%r12,%rdx,1)
  lea    0x5(%rax),%edx
  cmp    %edx,%ebp
  jl     L139
  movslq %ecx,%rcx
  movslq %edx,%rdx
  add    $0x6,%eax
  add    $0x6,%edi
  movzbl (%rbx,%rcx,1),%ecx
  mov    %cl,(%r12,%rdx,1)
  cmp    %eax,%ebp
  jl     L139
  movslq %edi,%rdi
  cltq
  movzbl (%rbx,%rdi,1),%edx
  mov    %dl,(%r12,%rax,1)
L139:
  pop    %rbx
  mov    %r12,%rax
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  cs nopw 0x0(%rax,%rax,1)
L214:
  xor    %eax,%eax
  jmp    L318
  nopw   0x0(%rax,%rax,1)
L284:
  mov    %rbx,%r12
  pop    %rbx
  pop    %rbp
  mov    %r12,%rax
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  nop
L285:
  mov    %rdx,%rax
  sub    %rdx,%rbx
  cs nopw 0x0(%rax,%rax,1)
L125:
  movzbl (%rbx,%rax,1),%edx
  mov    %dl,(%r12,%rax,1)
  add    $0x1,%rax
  cmp    %eax,%ebp
  jge    L125
  pop    %rbx
  mov    %r12,%rax
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
L9:
  xor    %edi,%edi
  xor    %ecx,%ecx
  jmp    L222
L134:
  xor    %esi,%esi
  xor    %edi,%edi
  jmp    L251
```

tool_calls: name: disassemble_data
arguments: label: D59
data_type: byte[16]
name: disassemble_data
arguments: label: D44
data_type: byte[16]
name: disassemble_data
arguments: label: D2
data_type: byte[16]
name: disassemble_data
arguments: label: D38
data_type: byte[16]
name: disassemble_data
arguments: label: D37
data_type: byte[8]

tool: {"D59": [0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x03,0x00,0x00,0x00]}

tool: {"D44": [0x10,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x10,0x00,0x00,0x00]}

tool: {"D2": [0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30]}

tool: {"D38": [0x0d,0x00,0x00,0x00,0x0d,0x00,0x00,0x00,0x0d,0x00,0x00,0x00,0x0d,0x00,0x00,0x00]}

tool: {"D37": [0x07,0x00,0x00,0x00,0x07,0x00,0x00,0x00]}

assistant: ```c
char *pad_bin(char *bin, int n) {
  int bin_len = (int)strlen(bin);
  int dif = n - bin_len;
  char *new_bin = malloc(n + 1);
  int i = 0;
  int j = 0;
  memset(new_bin, 0, n + 1);
  if (false) {
    printf("-   pad_bin(%s)\n", bin);
    printf("\t\t-   binlen: %i\n", bin_len);
  }
  if (n == 0) {
    return bin;
  } else
    for (; i <= n; i++) {
      if (i < dif) {
        new_bin[i] = '0';
      } else {
        new_bin[i] = bin[j];
        j++;
      }
    }
  if (false)
    printf("-   after padding: %s\n", new_bin);
  return new_bin;
}
```