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

```asm
<decode_base64>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x30,%rsp
  mov    %rdi,-0x28(%rbp)
  mov    %rsi,-0x30(%rbp)
  cmpq   $0x0,-0x30(%rbp)
  je     L18
  mov    -0x30(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L18
  mov    -0x28(%rbp),%rax
  mov    %rax,-0x10(%rbp)
  mov    -0x30(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  add    $0x1,%eax
  mov    %eax,-0x14(%rbp)
  mov    -0x14(%rbp),%eax
  mov    $0x1,%esi
  mov    %eax,%edi
  call   <calloc@plt>
  mov    %rax,-0x8(%rbp)
  movl   $0x0,-0x18(%rbp)
  movl   $0x0,-0x14(%rbp)
  jmp    L102
L61:
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <is_base64@plt>
  test   %rax,%rax
  je     L13
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%ecx
  mov    -0x14(%rbp),%eax
  lea    0x1(%rax),%edx
  mov    %edx,-0x14(%rbp)
  movslq %eax,%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  mov    %ecx,%edx
  mov    %dl,(%rax)
L13:
  addl   $0x1,-0x18(%rbp)
L102:
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L61
  movl   $0x0,-0x18(%rbp)
  jmp    L113
L57:
  movb   $0x41,-0x1d(%rbp)
  movb   $0x41,-0x20(%rbp)
  movb   $0x41,-0x1f(%rbp)
  movb   $0x41,-0x1e(%rbp)
  movb   $0x0,-0x1c(%rbp)
  movb   $0x0,-0x1b(%rbp)
  movb   $0x0,-0x1a(%rbp)
  movb   $0x0,-0x19(%rbp)
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  mov    %al,-0x1d(%rbp)
  mov    -0x18(%rbp),%eax
  add    $0x1,%eax
  cmp    %eax,-0x14(%rbp)
  jle    L45
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x1(%rax),%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  mov    %al,-0x20(%rbp)
L45:
  mov    -0x18(%rbp),%eax
  add    $0x2,%eax
  cmp    %eax,-0x14(%rbp)
  jle    L98
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x2(%rax),%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  mov    %al,-0x1f(%rbp)
L98:
  mov    -0x18(%rbp),%eax
  add    $0x3,%eax
  cmp    %eax,-0x14(%rbp)
  jle    L30
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x3(%rax),%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  mov    %al,-0x1e(%rbp)
L30:
  movsbl -0x1d(%rbp),%eax
  mov    %eax,%edi
  call   <decode@plt>
  mov    %al,-0x1c(%rbp)
  movsbl -0x20(%rbp),%eax
  mov    %eax,%edi
  call   <decode@plt>
  mov    %al,-0x1b(%rbp)
  movsbl -0x1f(%rbp),%eax
  mov    %eax,%edi
  call   <decode@plt>
  mov    %al,-0x1a(%rbp)
  movsbl -0x1e(%rbp),%eax
  mov    %eax,%edi
  call   <decode@plt>
  mov    %al,-0x19(%rbp)
  movzbl -0x1c(%rbp),%eax
  shl    $0x2,%eax
  mov    %eax,%edx
  movzbl -0x1b(%rbp),%eax
  shr    $0x4,%al
  mov    %edx,%ecx
  or     %eax,%ecx
  mov    -0x10(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x10(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
  cmpb   $0x3d,-0x1f(%rbp)
  je     L94
  movzbl -0x1b(%rbp),%eax
  shl    $0x4,%eax
  mov    %eax,%edx
  movzbl -0x1a(%rbp),%eax
  shr    $0x2,%al
  mov    %edx,%ecx
  or     %eax,%ecx
  mov    -0x10(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x10(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
L94:
  cmpb   $0x3d,-0x1e(%rbp)
  je     L46
  movzbl -0x1a(%rbp),%eax
  shl    $0x6,%eax
  mov    %eax,%edx
  movzbl -0x19(%rbp),%eax
  mov    %edx,%ecx
  or     %eax,%ecx
  mov    -0x10(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x10(%rbp)
  mov    %ecx,%edx
  mov    %dl,(%rax)
L46:
  addl   $0x4,-0x18(%rbp)
L113:
  mov    -0x18(%rbp),%eax
  cmp    -0x14(%rbp),%eax
  jl     L57
  mov    -0x8(%rbp),%rax
  mov    %rax,%rdi
  call   <free@plt>
  mov    -0x10(%rbp),%rax
  sub    -0x28(%rbp),%rax
  jmp    L5
L18:
  mov    $0x0,%eax
L5:
  leave
  ret
```

assistant: ```c
int decode_base64(unsigned char *dest, const char *src) {
  if (src && *src) {
    unsigned char *p = dest;
    int k, l = strlen(src) + 1;
    unsigned char *buf = calloc(l, sizeof(unsigned char));
    for (k = 0, l = 0; src[k]; k++) {
      if (is_base64(src[k])) {
        buf[l++] = src[k];
      }
    }
    for (k = 0; k < l; k += 4) {
      char c1 = 'A', c2 = 'A', c3 = 'A', c4 = 'A';
      unsigned char b1 = 0, b2 = 0, b3 = 0, b4 = 0;
      c1 = buf[k];
      if (k + 1 < l) {
        c2 = buf[k + 1];
      }
      if (k + 2 < l) {
        c3 = buf[k + 2];
      }
      if (k + 3 < l) {
        c4 = buf[k + 3];
      }
      b1 = decode(c1);
      b2 = decode(c2);
      b3 = decode(c3);
      b4 = decode(c4);
      *p++ = ((b1 << 2) | (b2 >> 4));
      if (c3 != '=') {
        *p++ = (((b2 & 0xf) << 4) | (b3 >> 2));
      }
      if (c4 != '=') {
        *p++ = (((b3 & 0x3) << 6) | b4);
      }
    }
    free(buf);
    return (p - dest);
  }
  return 0;
}
```