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

```asm
<MAC_GEN>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0xd8,%rsp
  mov    %rsi,0x30(%rsp)
  mov    %rdx,0x38(%rsp)
  mov    %rcx,0x40(%rsp)
  mov    %r8,0x48(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0xc8(%rsp)
  mov    %rdx,%rax
  shr    $0x5,%rax
  mov    %rax,(%rsp)
  mov    %edx,%eax
  and    $0x1f,%eax
  mov    %eax,0x2c(%rsp)
  jne    L182
  test   %rdx,%rdx
  je     L182
  pxor   %xmm0,%xmm0
  cmpq   $0x1,(%rsp)
  movq   $0x0,0x53(%rsp)
  movl   $0x0,0x5b(%rsp)
  movb   $0x0,0x5f(%rsp)
  movaps %xmm0,0xa0(%rsp)
  movaps %xmm0,0xb0(%rsp)
  jbe    L322
L12:
  mov    %rdi,0x18(%rsp)
  mov    $0x1,%r14d
  lea    0x60(%rsp),%r9
  lea    0xa0(%rsp),%rbp
  mov    0x30(%rsp),%r13
  mov    %rbp,0x20(%rsp)
  lea    0x53(%rsp),%r15
  mov    %r14,%rbp
  lea    0x80(%rsp),%r12
  lea    0xc0(%rsp),%rbx
  mov    %r9,%r14
  nop
L143:
  movdqu 0x0(%r13),%xmm1
  sub    $0x8,%rsp
  mov    %r14,%r9
  mov    %r15,%rdx
  movdqu 0x10(%r13),%xmm2
  xor    %r8d,%r8d
  mov    %rbp,%rcx
  mov    $0x80,%esi
  movaps %xmm1,0x68(%rsp)
  movaps %xmm2,0x78(%rsp)
  push   %r12
  mov    0x28(%rsp),%rdi
  call   <TEM_ENC@plt>
  mov    0x30(%rsp),%rax
  mov    %r12,%rdx
  pop    %r9
  pop    %r10
  nopl   0x0(%rax,%rax,1)
L79:
  movzbl (%rdx),%ecx
  xor    %cl,(%rax)
  add    $0x1,%rax
  add    $0x1,%rdx
  cmp    %rax,%rbx
  jne    L79
  lea    0x1(%rbp),%rax
  add    $0x20,%r13
  cmp    %rax,(%rsp)
  je     L335
  mov    %rax,%rbp
  jmp    L143
L335:
  mov    %r14,%r9
  mov    %rbp,%r14
  mov    0x18(%rsp),%rdi
  mov    0x20(%rsp),%rbp
  mov    %r14,%rax
  shl    $0x5,%rax
  add    %rax,0x30(%rsp)
L21:
  mov    0x2c(%rsp),%ebx
  test   %ebx,%ebx
  sete   %sil
  cmpq   $0x0,0x38(%rsp)
  setne  %al
  and    %al,%sil
  jne    L319
  test   %ebx,%ebx
  je     L144
  mov    0x30(%rsp),%rcx
  mov    0x2c(%rsp),%ebx
  mov    %r9,%r8
  mov    %rcx,%rax
  cmp    $0x8,%ebx
  jae    L167
L159:
  xor    %ecx,%ecx
  testb  $0x4,0x2c(%rsp)
  jne    L211
  testb  $0x2,0x2c(%rsp)
  jne    L222
L7:
  testb  $0x1,0x2c(%rsp)
  jne    L69
L144:
  mov    0x2c(%rsp),%ebx
  movslq %ebx,%rax
  lea    0x1(%rbx),%ecx
  movb   $0x80,0x60(%rsp,%rax,1)
  cmp    $0x1f,%ebx
  je     L284
  mov    $0x1f,%eax
  movslq %ecx,%rcx
  sub    0x2c(%rsp),%eax
  xor    %r10d,%r10d
  add    %r9,%rcx
  cmp    $0x8,%eax
  jae    L81
  test   $0x4,%al
  jne    L41
  test   %eax,%eax
  jne    L300
L284:
  mov    %r9,%rax
  cs nopw 0x0(%rax,%rax,1)
L192:
  movzbl 0x0(%rbp),%edx
  xor    %dl,(%rax)
  add    $0x1,%rax
  add    $0x1,%rbp
  cmp    %r12,%rax
  jne    L192
  test   %sil,%sil
  je     L227
  sub    $0x8,%rsp
  mov    $0x1,%r8d
  push   %rax
L209:
  mov    %r15,%rdx
  mov    %r14,%rcx
  mov    $0x80,%esi
  call   <TEM_ENC@plt>
  pop    %rax
  pop    %rdx
  movdqa 0x80(%rsp),%xmm3
  mov    0x40(%rsp),%rax
  movups %xmm3,(%rax)
  mov    0x48(%rsp),%rax
  movq   $0x10,(%rax)
  mov    0xc8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L349
  add    $0xd8,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L322:
  xor    %r14d,%r14d
  lea    0x60(%rsp),%r9
  lea    0x53(%rsp),%r15
  lea    0x80(%rsp),%r12
  lea    0xa0(%rsp),%rbp
L319:
  mov    0x30(%rsp),%rax
  mov    $0x1,%esi
  movdqu (%rax),%xmm4
  movdqu 0x10(%rax),%xmm6
  movaps %xmm4,(%rsp)
  movaps %xmm4,0x60(%rsp)
  movaps %xmm6,0x70(%rsp)
  jmp    L284
L182:
  addq   $0x1,(%rsp)
  mov    (%rsp),%rax
  pxor   %xmm0,%xmm0
  movq   $0x0,0x53(%rsp)
  movl   $0x0,0x5b(%rsp)
  movb   $0x0,0x5f(%rsp)
  movaps %xmm0,0xa0(%rsp)
  movaps %xmm0,0xb0(%rsp)
  cmp    $0x1,%rax
  jne    L12
  xor    %r14d,%r14d
  lea    0x60(%rsp),%r9
  lea    0x53(%rsp),%r15
  lea    0x80(%rsp),%r12
  lea    0xa0(%rsp),%rbp
  jmp    L21
L227:
  sub    $0x8,%rsp
  mov    $0x2,%r8d
  push   %rax
  jmp    L209
L81:
  mov    %eax,%r8d
  movq   $0x0,(%rcx)
  movq   $0x0,-0x8(%rcx,%r8,1)
  lea    0x8(%rcx),%r8
  and    $0xfffffffffffffff8,%r8
  sub    %r8,%rcx
  add    %ecx,%eax
  and    $0xfffffff8,%eax
  cmp    $0x8,%eax
  jb     L284
  and    $0xfffffff8,%eax
  xor    %ecx,%ecx
L117:
  mov    %ecx,%edx
  add    $0x8,%ecx
  mov    %r10,(%r8,%rdx,1)
  cmp    %eax,%ecx
  jb     L117
  jmp    L284
L69:
  movzbl (%rax,%rcx,1),%eax
  mov    %al,(%r8,%rcx,1)
  jmp    L144
L222:
  movzwl (%rax,%rcx,1),%r10d
  mov    %r10w,(%r8,%rcx,1)
  add    $0x2,%rcx
  testb  $0x1,0x2c(%rsp)
  je     L144
  jmp    L69
L211:
  mov    (%rax),%ecx
  mov    %ecx,(%r8)
  mov    $0x4,%ecx
  testb  $0x2,0x2c(%rsp)
  je     L7
  jmp    L222
L300:
  movb   $0x0,(%rcx)
  test   $0x2,%al
  je     L284
  xor    %r8d,%r8d
  mov    %r8w,-0x2(%rcx,%rax,1)
  jmp    L284
  xchg   %ax,%ax
L167:
  and    $0xfffffff8,%ebx
  xor    %eax,%eax
  mov    %rcx,%r8
  mov    %ebx,%r10d
L281:
  mov    %eax,%edx
  add    $0x8,%eax
  mov    (%r8,%rdx,1),%rcx
  mov    %rcx,(%r9,%rdx,1)
  cmp    %r10d,%eax
  jb     L281
  lea    (%r9,%rax,1),%r8
  add    0x30(%rsp),%rax
  jmp    L159
L41:
  movl   $0x0,(%rcx)
  movl   $0x0,-0x4(%rcx,%rax,1)
  jmp    L284
L349:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
int MAC_GEN(const unsigned char *_K, const unsigned char *_M, unsigned long long _mlen, unsigned char *C_, unsigned long long *clen_) {
  int d, pad;
  unsigned long long i, blocknum;
  const unsigned char *mp;
  unsigned char *cp, in[32], out[32], t[32], zero[13];
  i = 1;
  mp = _M;
  cp = C_;
  pad = _mlen % 32;
  blocknum = _mlen / 32;
  if ((pad != 0) || (_mlen == 0))
    blocknum += 1;
  do {
    int u;
    for (u = 0; u < 32; u++)
      (t)[u] = 0x00;
  } while (0);
  do {
    int u;
    for (u = 0; u < 13; u++)
      (zero)[u] = 0x00;
  } while (0);
  while (blocknum > 1) {
    do {
      int u;
      for (u = 0; u < 32; u++)
        (in)[u] = (mp)[u];
    } while (0);
    TEM_ENC(_K, 0x80, zero, i, 0, in, out);
    do {
      int u;
      for (u = 0; u < 32; u++)
        (t)[u] ^= (out)[u];
    } while (0);
    i++;
    blocknum--;
    mp += 32;
  }
  if ((pad == 0) && (_mlen != 0)) {
    do {
      int u;
      for (u = 0; u < 32; u++)
        (in)[u] = (mp)[u];
    } while (0);
  } else {
    do {
      int u;
      for (u = 0; u < pad; u++)
        (in)[u] = (mp)[u];
    } while (0);
    in[pad] = 0x80;
    for (d = pad + 1; d < 32; d++)
      in[d] = 0x00;
  }
  do {
    int u;
    for (u = 0; u < 32; u++)
      (in)[u] ^= (t)[u];
  } while (0);
  if ((pad == 0) && (_mlen != 0)) {
    TEM_ENC(_K, 0x80, zero, i - 1, 1, in, out);
  } else {
    TEM_ENC(_K, 0x80, zero, i - 1, 2, in, out);
  }
  do {
    int u;
    for (u = 0; u < 16; u++)
      (cp)[u] = (out)[u];
  } while (0);
  *clen_ = 16;
  return 0;
}
```