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

```asm
<decode_alpha_block_DXT5>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x28(%rbp)
  mov    %rsi,-0x30(%rbp)
  mov    %edx,-0x34(%rbp)
  mov    %ecx,-0x38(%rbp)
  mov    %r8d,-0x3c(%rbp)
  mov    %r9d,-0x40(%rbp)
  mov    -0x30(%rbp),%rax
  movzbl (%rax),%eax
  mov    %al,-0x1e(%rbp)
  mov    -0x30(%rbp),%rax
  movzbl 0x1(%rax),%eax
  mov    %al,-0x1d(%rbp)
  mov    -0x30(%rbp),%rax
  movzbl (%rax),%eax
  movzbl %al,%edx
  mov    -0x30(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  shl    $0x8,%rax
  or     %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    $0x2,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  shl    $0x10,%rax
  or     %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    $0x3,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  shl    $0x18,%rax
  or     %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    $0x4,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  shl    $0x20,%rax
  or     %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    $0x5,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  shl    $0x28,%rax
  or     %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    $0x6,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  shl    $0x30,%rax
  or     %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    $0x7,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  shl    $0x38,%rax
  or     %rdx,%rax
  shr    $0x10,%rax
  mov    %rax,-0x8(%rbp)
  movl   $0x0,-0x18(%rbp)
  jmp    L127
L83:
  mov    -0x18(%rbp),%eax
  imul   -0x40(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x28(%rbp),%rax
  add    %rdx,%rax
  mov    %rax,-0x10(%rbp)
  movl   $0x0,-0x1c(%rbp)
  jmp    L98
L81:
  mov    -0x8(%rbp),%rax
  and    $0x7,%eax
  mov    %eax,-0x14(%rbp)
  cmpl   $0x0,-0x14(%rbp)
  jne    L45
  mov    -0x10(%rbp),%rax
  movzbl -0x1e(%rbp),%edx
  mov    %dl,(%rax)
  jmp    L140
L45:
  cmpl   $0x1,-0x14(%rbp)
  jne    L10
  mov    -0x10(%rbp),%rax
  movzbl -0x1d(%rbp),%edx
  mov    %dl,(%rax)
  jmp    L140
L10:
  movzbl -0x1e(%rbp),%eax
  cmp    -0x1d(%rbp),%al
  jbe    L76
  mov    $0x8,%eax
  sub    -0x14(%rbp),%eax
  mov    %eax,%edx
  movzbl -0x1e(%rbp),%eax
  mov    %edx,%ecx
  imul   %eax,%ecx
  mov    -0x14(%rbp),%eax
  lea    -0x1(%rax),%edx
  movzbl -0x1d(%rbp),%eax
  imul   %edx,%eax
  add    %ecx,%eax
  movslq %eax,%rdx
  imul   $0xffffffff92492493,%rdx,%rdx
  shr    $0x20,%rdx
  add    %eax,%edx
  sar    $0x2,%edx
  sar    $0x1f,%eax
  mov    %eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  mov    %eax,%edx
  mov    -0x10(%rbp),%rax
  mov    %dl,(%rax)
  jmp    L140
L76:
  cmpl   $0x5,-0x14(%rbp)
  jle    L141
  cmpl   $0x6,-0x14(%rbp)
  jne    L41
  mov    $0x0,%edx
  jmp    L50
L41:
  mov    $0xffffffff,%edx
L50:
  mov    -0x10(%rbp),%rax
  mov    %dl,(%rax)
  jmp    L140
L141:
  mov    $0x6,%eax
  sub    -0x14(%rbp),%eax
  mov    %eax,%edx
  movzbl -0x1e(%rbp),%eax
  mov    %edx,%ecx
  imul   %eax,%ecx
  mov    -0x14(%rbp),%eax
  lea    -0x1(%rax),%edx
  movzbl -0x1d(%rbp),%eax
  imul   %edx,%eax
  add    %ecx,%eax
  movslq %eax,%rdx
  imul   $0x66666667,%rdx,%rdx
  shr    $0x20,%rdx
  sar    %edx
  sar    $0x1f,%eax
  mov    %eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  mov    %eax,%edx
  mov    -0x10(%rbp),%rax
  mov    %dl,(%rax)
L140:
  shrq   $0x3,-0x8(%rbp)
  mov    -0x3c(%rbp),%eax
  cltq
  add    %rax,-0x10(%rbp)
  addl   $0x1,-0x1c(%rbp)
L98:
  mov    -0x1c(%rbp),%eax
  cmp    -0x34(%rbp),%eax
  jl     L81
  cmpl   $0x3,-0x34(%rbp)
  jg     L117
  mov    $0x4,%eax
  sub    -0x34(%rbp),%eax
  mov    %eax,%edx
  mov    %edx,%eax
  add    %eax,%eax
  add    %edx,%eax
  mov    %eax,%ecx
  shrq   %cl,-0x8(%rbp)
L117:
  addl   $0x1,-0x18(%rbp)
L127:
  mov    -0x18(%rbp),%eax
  cmp    -0x38(%rbp),%eax
  jl     L83
  nop
  nop
  pop    %rbp
  ret
```

assistant: ```c
void decode_alpha_block_DXT5(unsigned char *dst, unsigned char *src, int w, int h, int bpp, int rowbytes) {
  int x, y, code;
  unsigned char *d;
  unsigned char a0 = src[0];
  unsigned char a1 = src[1];
  unsigned long long bits = (((unsigned long long)(src)[0]) | ((unsigned long long)(src)[1] << 8) | ((unsigned long long)(src)[2] << 16) | ((unsigned long long)(src)[3] << 24) | ((unsigned long long)(src)[4] << 32) | ((unsigned long long)(src)[5] << 40) | ((unsigned long long)(src)[6] << 48) | ((unsigned long long)(src)[7] << 56)) >> 16;
  for (y = 0; y < h; ++y) {
    d = dst + (y * rowbytes);
    for (x = 0; x < w; ++x) {
      code = ((unsigned int)bits) & 0x07;
      if (code == 0)
        d[0] = a0;
      else if (code == 1)
        d[0] = a1;
      else if (a0 > a1)
        d[0] = ((8 - code) * a0 + (code - 1) * a1) / 7;
      else if (code >= 6)
        d[0] = (code == 6) ? 0 : 255;
      else
        d[0] = ((6 - code) * a0 + (code - 1) * a1) / 5;
      bits >>= 3;
      d += bpp;
    }
    if (w < 4)
      bits >>= (3 * (4 - w));
  }
}
```