user: What would the C source look like for the assembly code provided here:

```asm
<b64_decode>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x28(%rbp)
  movl   $0x0,-0x18(%rbp)
  mov    -0x18(%rbp),%eax
  mov    %eax,-0x1c(%rbp)
  mov    -0x1c(%rbp),%eax
  mov    %eax,-0x14(%rbp)
  mov    -0x28(%rbp),%rax
  mov    %rax,-0x8(%rbp)
  mov    -0x28(%rbp),%rax
  mov    %rax,-0x10(%rbp)
  jmp    L5
L7:
  mov    -0x10(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0xa,%al
  je     L138
  mov    -0x10(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0xd,%al
  jne    L2
L138:
  movl   $0x0,-0x1c(%rbp)
  mov    -0x1c(%rbp),%eax
  mov    %eax,-0x18(%rbp)
  jmp    L41
L2:
  mov    -0x10(%rbp),%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  lea    D1(%rip),%rax
  mov    (%rdx,%rax,1),%eax
  mov    %eax,-0x14(%rbp)
  cmpl   $0xffffffff,-0x14(%rbp)
  je     L41
  cmpl   $0x3,-0x18(%rbp)
  je     L34
  cmpl   $0x3,-0x18(%rbp)
  jg     L147
  cmpl   $0x2,-0x18(%rbp)
  je     L46
  cmpl   $0x2,-0x18(%rbp)
  jg     L147
  cmpl   $0x0,-0x18(%rbp)
  je     L77
  cmpl   $0x1,-0x18(%rbp)
  je     L83
  jmp    L147
L77:
  addl   $0x1,-0x18(%rbp)
  jmp    L147
L83:
  mov    -0x1c(%rbp),%eax
  shl    $0x2,%eax
  mov    %eax,%edx
  mov    -0x14(%rbp),%eax
  sar    $0x4,%eax
  and    $0x3,%eax
  or     %edx,%eax
  mov    %al,-0x1d(%rbp)
  mov    -0x28(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x28(%rbp)
  movzbl -0x1d(%rbp),%edx
  mov    %dl,(%rax)
  addl   $0x1,-0x18(%rbp)
  jmp    L147
L46:
  mov    -0x1c(%rbp),%eax
  shl    $0x4,%eax
  mov    %eax,%edx
  mov    -0x14(%rbp),%eax
  sar    $0x2,%eax
  and    $0xf,%eax
  or     %edx,%eax
  mov    %al,-0x1d(%rbp)
  mov    -0x28(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x28(%rbp)
  movzbl -0x1d(%rbp),%edx
  mov    %dl,(%rax)
  addl   $0x1,-0x18(%rbp)
  jmp    L147
L34:
  mov    -0x1c(%rbp),%eax
  shl    $0x6,%eax
  mov    %eax,%edx
  mov    -0x14(%rbp),%eax
  or     %edx,%eax
  mov    %al,-0x1d(%rbp)
  mov    -0x28(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x28(%rbp)
  movzbl -0x1d(%rbp),%edx
  mov    %dl,(%rax)
  movl   $0x0,-0x18(%rbp)
  nop
L147:
  mov    -0x14(%rbp),%eax
  mov    %eax,-0x1c(%rbp)
L41:
  addq   $0x1,-0x10(%rbp)
L5:
  mov    -0x10(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L7
  mov    -0x28(%rbp),%rax
  movb   $0x0,(%rax)
  mov    -0x28(%rbp),%rax
  sub    -0x8(%rbp),%rax
  pop    %rbp
  ret
```

assistant: ```c
int b64_decode(unsigned char *str) {
  unsigned char *cur, *start;
  int d, dlast, phase;
  unsigned char c;
  static int table[256] = {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 62, -1, -1, -1, 63, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, -1, -1, -1, -1, -1, -1, -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, -1, -1, -1, -1, -1, -1, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1};
  d = dlast = phase = 0;
  start = str;
  for (cur = str; *cur != '\0'; ++cur) {
    if (*cur == '\n' || *cur == '\r') {
      phase = dlast = 0;
      continue;
    }
    d = table[(int)*cur];
    if (d != -1) {
      switch (phase) {
      case 0:
        ++phase;
        break;
      case 1:
        c = ((dlast << 2) | ((d & 0x30) >> 4));
        *str++ = c;
        ++phase;
        break;
      case 2:
        c = (((dlast & 0xf) << 4) | ((d & 0x3c) >> 2));
        *str++ = c;
        ++phase;
        break;
      case 3:
        c = (((dlast & 0x03) << 6) | d);
        *str++ = c;
        phase = 0;
        break;
      }
      dlast = d;
    }
  }
  *str = '\0';
  return str - start;
}
```