user: 请从给定的汇编指令推导出C源代码:

```asm
<base32_encode>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x68,%rsp
  movdqa D13(%rip),%xmm0
  mov    %rsi,0x8(%rsp)
  mov    %edx,%esi
  mov    %edx,0x18(%rsp)
  mov    %esi,%ebx
  mov    %rdi,0x10(%rsp)
  mov    %ecx,0x1c(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0x58(%rsp)
  xor    %eax,%eax
  mov    %edx,%eax
  mov    $0xcccccccd,%edx
  movaps %xmm0,0x30(%rsp)
  imul   %rdx,%rax
  movdqa D16(%rip),%xmm0
  movaps %xmm0,0x40(%rsp)
  shr    $0x22,%rax
  lea    (%rax,%rax,4),%eax
  sub    %eax,%ebx
  mov    %ebx,0x2c(%rsp)
  test   %ecx,%ecx
  je     L38
  test   %esi,%esi
  je     L38
  xor    %ebp,%ebp
  mov    %ebp,%r12d
  jmp    L66
  nopl   0x0(%rax)
L134:
  mov    0x8(%rsp),%rsi
  lea    0x1(%rbp),%r14d
  movsbl (%rsi,%rax,1),%edi
  call   <uchar@plt>
  movzbl %al,%edx
  cmp    %r14d,0x18(%rsp)
  jbe    L83
  mov    0x8(%rsp),%rax
  mov    %dl,0x20(%rsp)
  lea    0x2(%rbp),%r15d
  movsbl (%rax,%r14,1),%edi
  call   <uchar@plt>
  movzbl 0x20(%rsp),%r14d
  mov    %eax,%r9d
  mov    %r14d,%ecx
  shr    $0x6,%cl
  movzbl %cl,%ecx
  or     %r13d,%ecx
  mov    %r14d,%r13d
  shl    $0x4,%r14d
  sar    %r13d
  and    $0x10,%r14d
  and    $0x1f,%r13d
  cmp    %r15d,0x18(%rsp)
  jbe    L205
  mov    %al,0x24(%rsp)
  mov    0x8(%rsp),%rax
  lea    0x3(%rbp),%r10d
  mov    %ecx,0x28(%rsp)
  movsbl (%rax,%r15,1),%edi
  mov    %r10d,0x20(%rsp)
  call   <uchar@plt>
  movzbl 0x24(%rsp),%r9d
  mov    0x20(%rsp),%r10d
  mov    0x28(%rsp),%ecx
  movzbl %al,%edx
  mov    %r9d,%r15d
  shr    $0x4,%r15b
  movzbl %r15b,%r15d
  or     %r14d,%r15d
  lea    (%r9,%r9,1),%r14d
  and    $0x1e,%r14d
  cmp    %r10d,0x18(%rsp)
  jbe    L72
  mov    0x8(%rsp),%rax
  mov    %ecx,0x24(%rsp)
  movslq %r13d,%r13
  movslq %r15d,%r15
  mov    %dl,0x20(%rsp)
  add    $0x4,%ebp
  movsbl (%rax,%r10,1),%edi
  call   <uchar@plt>
  movzbl 0x20(%rsp),%edx
  movzbl 0x30(%rsp,%r15,1),%edi
  mov    %eax,%r10d
  movzbl 0x30(%rsp,%r13,1),%eax
  mov    0x24(%rsp),%ecx
  mov    %edx,%r9d
  mov    %r10d,%r13d
  mov    %edx,%r11d
  shl    $0x3,%edx
  shr    $0x7,%r9b
  shr    $0x5,%r13b
  and    $0x18,%edx
  and    $0x1f,%r10d
  movzbl %r13b,%r13d
  movzbl %r9b,%r9d
  sar    $0x2,%r11d
  or     %r13d,%edx
  or     %r14d,%r9d
  and    $0x1f,%r11d
  movslq %edx,%rdx
  movslq %r9d,%r9
  movzbl 0x30(%rsp,%r11,1),%r11d
  movzbl 0x30(%rsp,%rdx,1),%r13d
  movzbl 0x30(%rsp,%r9,1),%r9d
  movzbl 0x30(%rsp,%r10,1),%edx
L150:
  shl    $0x8,%rdx
  movslq %ecx,%rcx
  mov    0x10(%rsp),%rsi
  mov    %r12d,%r10d
  or     %r13,%rdx
  lea    0x7(%r12),%r14d
  add    $0x8,%r12d
  shl    $0x8,%rdx
  or     %r11,%rdx
  shl    $0x8,%rdx
  or     %r9,%rdx
  movzbl %dil,%r9d
  mov    %rdx,%rdi
  movzbl %al,%edx
  shl    $0x8,%rdi
  or     %r9,%rdi
  mov    %rdi,%rax
  shl    $0x8,%rax
  or     %rdx,%rax
  movzbl 0x30(%rsp,%rcx,1),%edx
  shl    $0x8,%rax
  or     %rdx,%rax
  movzbl 0x30(%rsp,%rbx,1),%edx
  shl    $0x8,%rax
  or     %rdx,%rax
  mov    %rax,(%rsi,%r10,1)
  cmp    0x18(%rsp),%ebp
  jae    L85
  cmp    %r12d,0x1c(%rsp)
  jbe    L85
L66:
  mov    0x8(%rsp),%rsi
  mov    %ebp,%eax
  xor    %r13d,%r13d
  xor    %ebx,%ebx
  movsbl (%rsi,%rax,1),%edi
  cmp    %ebp,0x18(%rsp)
  jbe    L134
  call   <uchar@plt>
  add    $0x1,%ebp
  mov    %eax,%ebx
  shr    $0x3,%bl
  movzbl %bl,%ebx
  cmp    %ebp,0x18(%rsp)
  ja     L55
  mov    $0x79,%edx
  lea    0x0(,%rax,4),%ecx
  mov    $0x79,%r13d
  mov    $0x79,%r11d
  and    $0x1c,%ecx
  mov    $0x79,%r9d
  mov    $0x79,%edi
  mov    $0x79,%eax
  jmp    L150
  nopl   0x0(%rax)
L38:
  mov    $0xffffffff,%r14d
  cs nopw 0x0(%rax,%rax,1)
L85:
  mov    0x2c(%rsp),%ecx
  cmp    $0x1,%ecx
  je     L39
  cmp    $0x2,%ecx
  je     L215
  cmp    $0x3,%cl
  je     L206
  cmp    $0x4,%cl
  jne    L216
  mov    0x10(%rsp),%rax
  movb   $0x3d,(%rax,%r14,1)
  jmp    L216
  nopl   0x0(%rax,%rax,1)
L39:
  mov    0x10(%rsp),%rbx
  mov    %r14d,%eax
  movb   $0x3d,(%rbx,%rax,1)
  lea    -0x1(%r14),%eax
  movb   $0x3d,(%rbx,%rax,1)
  lea    -0x2(%r14),%eax
  movb   $0x3d,(%rbx,%rax,1)
  lea    -0x3(%r14),%eax
  movb   $0x3d,(%rbx,%rax,1)
  lea    -0x4(%r14),%eax
  movb   $0x3d,(%rbx,%rax,1)
  lea    -0x5(%r14),%eax
  movb   $0x3d,(%rbx,%rax,1)
L216:
  mov    0x58(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L210
  add    $0x68,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   (%rax)
L215:
  mov    0x10(%rsp),%rsi
  mov    %r14d,%eax
  movb   $0x3d,(%rsi,%rax,1)
  lea    -0x1(%r14),%eax
  movb   $0x3d,(%rsi,%rax,1)
  lea    -0x2(%r14),%eax
  movb   $0x3d,(%rsi,%rax,1)
  lea    -0x3(%r14),%eax
  movb   $0x3d,(%rsi,%rax,1)
  jmp    L216
  xchg   %ax,%ax
L206:
  mov    0x10(%rsp),%rbx
  mov    %r14d,%eax
  movb   $0x3d,(%rbx,%rax,1)
  lea    -0x1(%r14),%eax
  movb   $0x3d,(%rbx,%rax,1)
  lea    -0x2(%r14),%eax
  movb   $0x3d,(%rbx,%rax,1)
  jmp    L216
L210:
  call   <__stack_chk_fail@plt>
L55:
  shl    $0x2,%eax
  and    $0x1c,%eax
  mov    %eax,%r13d
  mov    %ebp,%eax
  jmp    L134
L72:
  mov    %edx,%esi
  movslq %r13d,%r13
  movslq %r15d,%r15
  mov    %r10d,%ebp
  shr    $0x7,%sil
  movzbl 0x30(%rsp,%r13,1),%eax
  movzbl 0x30(%rsp,%r15,1),%edi
  movzbl %sil,%esi
  or     %r14d,%esi
  movslq %esi,%rsi
  movzbl 0x30(%rsp,%rsi,1),%r9d
  mov    %edx,%esi
  shl    $0x3,%edx
  sar    $0x2,%esi
  and    $0x18,%edx
  and    $0x1f,%esi
  movzbl 0x30(%rsp,%rdx,1),%r13d
  mov    $0x79,%edx
  movzbl 0x30(%rsp,%rsi,1),%r11d
  jmp    L150
L205:
  mov    %r9d,%edx
  movslq %r13d,%r13
  mov    %r15d,%ebp
  mov    $0x79,%r11d
  shr    $0x4,%dl
  movzbl 0x30(%rsp,%r13,1),%eax
  mov    $0x79,%r13d
  movzbl %dl,%edx
  or     %r14d,%edx
  movslq %edx,%rdx
  movzbl 0x30(%rsp,%rdx,1),%edi
  lea    (%r9,%r9,1),%edx
  and    $0x1e,%edx
  movzbl 0x30(%rsp,%rdx,1),%r9d
  mov    $0x79,%edx
  jmp    L150
L83:
  mov    %edx,%ecx
  mov    %edx,%eax
  shl    $0x4,%edx
  mov    %r14d,%ebp
  shr    $0x6,%cl
  sar    %eax
  and    $0x10,%edx
  mov    $0x79,%r11d
  movzbl %cl,%ecx
  and    $0x1f,%eax
  movzbl 0x30(%rsp,%rdx,1),%edi
  mov    $0x79,%r9d
  or     %r13d,%ecx
  movzbl 0x30(%rsp,%rax,1),%eax
  mov    $0x79,%edx
  mov    $0x79,%r13d
  jmp    L150
```

tool_calls: name: parse_data
arguments: data_tag: D13
datatype: byte[16]
name: parse_data
arguments: data_tag: D16
datatype: byte[16]

tool: {"D13": [0x79,0x62,0x6e,0x64,0x72,0x66,0x67,0x38,0x65,0x6a,0x6b,0x6d,0x63,0x70,0x71,0x78]}

tool: {"D16": [0x6f,0x74,0x31,0x75,0x77,0x69,0x73,0x7a,0x61,0x33,0x34,0x35,0x68,0x37,0x36,0x39]}

assistant: ```c
int base32_encode(char *dest, const char *src, unsigned int srclen, unsigned int outlen) {
  const char table[32] = "ybndrfg8ejkmcpqxot1uwisza345h769";
  unsigned int i = 0;
  unsigned int j = 0;
  unsigned char a = 0;
  unsigned char b = 0;
  unsigned char c = 0;
  unsigned char d = 0;
  unsigned char e = 0;
  unsigned char leftover_bytes = (srclen % 5);
  unsigned char replace_bytes = 0;
  const char padding[1] = "=";
  unsigned int iters = (srclen / 5);
  while (i < srclen && j < outlen) {
    a = i < srclen ? uchar(src[i++]) : 0;
    b = i < srclen ? uchar(src[i++]) : 0;
    c = i < srclen ? uchar(src[i++]) : 0;
    d = i < srclen ? uchar(src[i++]) : 0;
    e = i < srclen ? uchar(src[i++]) : 0;
    dest[j++] = table[(a >> 3)];
    dest[j++] = table[(((a & 0x07) << 2) | (b >> 6))];
    dest[j++] = table[(((b & 0x3F) >> 1))];
    dest[j++] = table[(((b & 0x01) << 4) | (c >> 4))];
    dest[j++] = table[(((c & 0x0F) << 1) | (d >> 7))];
    dest[j++] = table[(((d & 0x7F) >> 2))];
    dest[j++] = table[(((d & 0x03) << 3) | (e >> 5))];
    dest[j++] = table[(((e & 0x1F)))];
  }
  if (leftover_bytes == 1)
    replace_bytes = 6;
  else if (leftover_bytes == 2)
    replace_bytes = 4;
  else if (leftover_bytes == 3)
    replace_bytes = 3;
  else if (leftover_bytes == 4)
    replace_bytes = 1;
  j--;
  for (i = 0; i < replace_bytes; i++) {
    dest[j--] = padding[0];
  }
  return 0;
}
```