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

```asm
<base64Decode>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbx
  sub    $0xa8,%rsp
  mov    %rdx,-0xb8(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  xor    %eax,%eax
  test   %rsi,%rsi
  je     L225
  mov    %rdi,%r13
  test   %rdi,%rdi
  je     L225
  movdqa D47(%rip),%xmm0
  mov    %rdx,%rbx
  mov    %rsi,%r15
  movb   $0x0,-0x40(%rbp)
  movaps %xmm0,-0x90(%rbp)
  movdqa D55(%rip),%xmm0
  movaps %xmm0,-0x80(%rbp)
  movdqa D57(%rip),%xmm0
  movaps %xmm0,-0x70(%rbp)
  movdqa D17(%rip),%xmm0
  movaps %xmm0,-0x60(%rbp)
  movdqa D67(%rip),%xmm0
  movaps %xmm0,-0x50(%rbp)
  call   <strlen@plt>
  movl   $0x0,(%rbx)
  mov    $0x2000,%edi
  mov    %eax,%r14d
  call   <malloc@plt>
  lea    D63(%rip),%rsi
  mov    %rax,(%r15)
  mov    %rax,%rdi
  call   <strcpy@plt>
  mov    %r14d,%eax
  mov    %rsp,%rdx
  lea    0xf(,%rax,4),%rax
  shr    $0x4,%rax
  shl    $0x4,%rax
  mov    %rax,%rsi
  and    $0xfffffffffffff000,%rsi
  sub    %rsi,%rdx
  cmp    %rdx,%rsp
  je     L168
L5:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rdx,%rsp
  jne    L5
L168:
  and    $0xfff,%eax
  sub    %rax,%rsp
  test   %rax,%rax
  je     L244
  orq    $0x0,-0x8(%rsp,%rax,1)
L244:
  mov    %rsp,-0xc8(%rbp)
  xor    %r9d,%r9d
  xor    %r12d,%r12d
  xor    %ebx,%ebx
  movl   $0x0,-0xa8(%rbp)
  xor    %edx,%edx
  nopl   0x0(%rax)
L163:
  cmp    %ebx,%r14d
  jae    L182
  jmp    L281
  nop
L280:
  sub    $0x2b,%eax
  cltq
  movzbl -0x90(%rbp,%rax,1),%eax
  test   %al,%al
  je     L63
  cmp    $0x24,%al
  je     L63
  sub    $0x3d,%al
  sete   %sil
  cmp    %ebx,%r14d
  jb     L281
L123:
  test   %sil,%sil
  je     L132
L182:
  mov    %ebx,%eax
  add    $0x1,%ebx
  movzbl 0x0(%r13,%rax,1),%eax
  lea    -0x2b(%rax),%esi
  cmp    $0x4f,%sil
  jbe    L280
L63:
  mov    $0x1,%esi
  xor    %eax,%eax
  cmp    %ebx,%r14d
  jae    L123
L281:
  movb   $0x0,-0x94(%rbp,%rdx,1)
L50:
  test   %r12d,%r12d
  jne    L59
L21:
  cmp    %ebx,%r14d
  jb     L30
  xor    %r12d,%r12d
  xor    %edx,%edx
  jmp    L163
L225:
  mov    $0x1,%eax
L304:
  mov    -0x38(%rbp),%rdx
  sub    %fs:0x28,%rdx
  jne    L147
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
  nopl   0x0(%rax)
L132:
  cmp    %ebx,%r14d
  jb     L281
  add    $0x1,%r12d
  test   %al,%al
  je     L36
  mov    %edx,%esi
  sub    $0x1,%eax
  mov    %al,-0x94(%rbp,%rsi,1)
L36:
  add    $0x1,%edx
  cmp    $0x3,%edx
  jbe    L163
  jmp    L50
  nopw   0x0(%rax,%rax,1)
L59:
  movzbl -0x93(%rbp),%esi
  movzbl -0x94(%rbp),%edx
  mov    %esi,%eax
  shl    $0x2,%edx
  shr    $0x4,%al
  shl    $0x4,%esi
  or     %edx,%eax
  movzbl -0x92(%rbp),%edx
  mov    %edx,%edi
  shl    $0x6,%edx
  or     -0x91(%rbp),%dl
  shr    $0x2,%dil
  mov    %dl,-0x98(%rbp)
  or     %edi,%esi
  sub    $0x1,%r12d
  mov    %sil,-0x99(%rbp)
  mov    %r12d,-0xac(%rbp)
  je     L17
  xor    %r12d,%r12d
  test   %al,%al
  jne    L143
L164:
  mov    -0xb8(%rbp),%rdi
  mov    -0xa8(%rbp),%eax
  add    $0x1,%r9d
  mov    (%rdi),%edx
  mov    -0xc8(%rbp),%rdi
  add    %r12d,%edx
  mov    %edx,(%rdi,%rax,4)
  lea    0x1(%rax),%eax
  mov    %eax,-0xa8(%rbp)
L101:
  add    $0x1,%r12
  cmp    %r12d,-0xac(%rbp)
  jbe    L17
L29:
  movzbl -0x9a(%rbp,%r12,1),%eax
  test   %al,%al
  je     L164
L143:
  movzbl %al,%edx
  lea    -0x97(%rbp),%rax
  lea    D35(%rip),%rsi
  mov    %r9d,-0xa4(%rbp)
  mov    %rax,%rdi
  mov    %rax,-0xc0(%rbp)
  call   <sprintf@plt>
  mov    -0xc0(%rbp),%rsi
  mov    (%r15),%rdi
  call   <strcat@plt>
  mov    -0xa4(%rbp),%r9d
  test   %r9d,%r9d
  je     L101
  nopl   0x0(%rax)
L86:
  mov    -0xc0(%rbp),%rsi
  mov    (%r15),%rdi
  mov    %r9d,-0xa4(%rbp)
  call   <strcat@plt>
  mov    -0xa4(%rbp),%r9d
  sub    $0x1,%r9d
  jne    L86
  add    $0x1,%r12
  cmp    %r12d,-0xac(%rbp)
  ja     L29
L17:
  mov    -0xb8(%rbp),%rax
  mov    -0xac(%rbp),%ecx
  add    %ecx,(%rax)
  jmp    L21
L30:
  mov    -0xa8(%rbp),%eax
  test   %eax,%eax
  je     L321
  mov    -0xa8(%rbp),%ecx
  mov    -0xc8(%rbp),%rax
  lea    -0x1(%rcx),%edx
  lea    0x4(%rax,%rdx,4),%rdi
  nop
L167:
  mov    (%rax),%edx
  mov    (%r15),%rsi
  add    $0x4,%rax
  movb   $0x0,(%rsi,%rdx,1)
  cmp    %rax,%rdi
  jne    L167
L321:
  lea    -0x1(%r14),%eax
  xor    %edx,%edx
  cmpb   $0x3d,0x0(%r13,%rax,1)
  jne    L117
  lea    -0x2(%r14),%eax
  xor    %edx,%edx
  cmpb   $0x3d,0x0(%r13,%rax,1)
  sete   %dl
  add    $0x1,%edx
L117:
  lea    (%r14,%r14,2),%eax
  mov    -0xb8(%rbp),%rcx
  shr    $0x2,%eax
  sub    %edx,%eax
  mov    %eax,(%rcx)
  xor    %eax,%eax
  jmp    L304
L147:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: unpack_data
arguments: data_tag: D47
type_guessed: byte[16]
name: unpack_data
arguments: data_tag: D55
type_guessed: byte[16]
name: unpack_data
arguments: data_tag: D57
type_guessed: byte[16]
name: unpack_data
arguments: data_tag: D17
type_guessed: byte[16]
name: unpack_data
arguments: data_tag: D67
type_guessed: byte[16]
name: unpack_data
arguments: data_tag: D63
type_guessed: string
name: unpack_data
arguments: data_tag: D35
type_guessed: string

tool: {"D47": [0x7c,0x24,0x24,0x24,0x7d,0x72,0x73,0x74,0x75,0x76,0x77,0x78,0x79,0x7a,0x7b,0x24]}

tool: {"D55": [0x24,0x24,0x24,0x24,0x24,0x24,0x3e,0x3f,0x40,0x41,0x42,0x43,0x44,0x45,0x46,0x47]}

tool: {"D57": [0x48,0x49,0x4a,0x4b,0x4c,0x4d,0x4e,0x4f,0x50,0x51,0x52,0x53,0x54,0x55,0x56,0x57]}

tool: {"D17": [0x24,0x24,0x24,0x24,0x24,0x24,0x58,0x59,0x5a,0x5b,0x5c,0x5d,0x5e,0x5f,0x60,0x61]}

tool: {"D67": [0x62,0x63,0x64,0x65,0x66,0x67,0x68,0x69,0x6a,0x6b,0x6c,0x6d,0x6e,0x6f,0x70,0x71]}

tool: 

tool: D35: %c

assistant: ```c
int base64Decode(const char *encoded, char **decoded, int *decodedLen) {
  if (decoded == NULL || encoded == NULL) {
    return 1;
  }
  unsigned char in[4], out[3], v;
  char temp[3], chars[] = "|$$$}rstuvwxyz{$$$$$$$>?@ABCDEFGHIJKLMNOPQRSTUVW$$$$$$XYZ[\\]^_`abcdefghijklmnopq";
  unsigned int i, j = 0, pos, length = strlen(encoded);
  (*decodedLen) = 0;
  *decoded = (char *)malloc(sizeof(char) * 8192);
  strcpy((*decoded), "");
  int isNullTerminator = 0;
  unsigned int numNullTerminators = 0;
  unsigned nullTerminators[length];
  while (j <= length) {
    for (pos = 0, i = 0; i < 4 && j <= length; i++) {
      v = 0;
      while (j <= length && v == 0) {
        v = (unsigned char)encoded[j++];
        v = (unsigned char)((v < 43 || v > 122) ? 0 : chars[v - 43]);
        if (v) {
          v = (unsigned char)((v == '$') ? 0 : v - 61);
        }
      }
      if (j <= length) {
        pos++;
        if (v) {
          in[i] = (unsigned char)(v - 1);
        }
      } else {
        in[i] = 0;
      }
    }
    if (pos) {
      out[0] = (unsigned char)(in[0] << 2 | in[1] >> 4);
      out[1] = (unsigned char)(in[1] << 4 | in[2] >> 2);
      out[2] = (unsigned char)(((in[2] << 6) & 0xc0) | in[3]);
      for (i = 0; i < pos - 1; i++) {
        if (out[i] != '\0') {
          sprintf(temp, "%c", out[i]);
          strcat(*decoded, temp);
          while (isNullTerminator) {
            strcat(*decoded, temp);
            isNullTerminator--;
          }
        } else {
          isNullTerminator++;
          nullTerminators[numNullTerminators++] = *decodedLen + i;
        }
      }
      (*decodedLen) += i;
    }
  }
  for (i = 0; i < numNullTerminators; i++) {
    (*decoded)[nullTerminators[i]] = '\0';
  }
  int correction = 0;
  if (encoded[length - 1] == '=') {
    correction++;
    if (encoded[length - 2] == '=') {
      correction++;
    }
  }
  (*decodedLen) = (length * 3) / 4 - correction;
  return 0;
}
```