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

```asm
<YUV422_to_RGB>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  mov    %rcx,-0x20(%rsp)
  mov    %r8d,-0x18(%rsp)
  mov    %r9d,-0x14(%rsp)
  test   %r9d,%r9d
  jle    L67
  mov    %rdi,%r11
  mov    %rsi,%rbx
  mov    %rdx,%rbp
  lea    -0x1(%r8),%eax
  shr    %eax
  lea    0x1(%rax),%r13d
  lea    0x0(%r13,%r13,1),%rax
  mov    %rax,-0x10(%rsp)
  add    %r13,%rax
  add    %rax,%rax
  mov    %rax,-0x8(%rsp)
  mov    $0x0,%r14d
  mov    $0x0,%ecx
  mov    $0xffffffff,%r12d
  jmp    L27
L0:
  add    $0x6,%rdx
  mov    %sil,-0x1(%rdx)
  add    $0x1,%rax
  cmp    %r13,%rax
  je     L94
L32:
  movzbl (%rbx,%rax,1),%r8d
  add    $0xffffff80,%r8d
  movzbl 0x0(%rbp,%rax,1),%edi
  add    $0xffffff80,%edi
  movzbl (%r11,%rax,2),%r9d
  imul   $0x12a,%r9d,%r9d
  imul   $0x199,%edi,%esi
  lea    0x80(%r9,%rsi,1),%esi
  imul   $0xffffff9c,%r8d,%r10d
  add    %r9d,%r10d
  imul   $0xffffff30,%edi,%r15d
  lea    0x80(%r10,%r15,1),%r10d
  sar    $0x8,%r10d
  imul   $0x204,%r8d,%r15d
  lea    0x80(%r9,%r15,1),%r9d
  sar    $0x8,%r9d
  mov    %ecx,%r15d
  sar    $0x8,%esi
  js     L84
  cmp    $0xff,%esi
  mov    %esi,%r15d
  cmovg  %r12d,%r15d
L84:
  mov    %r15b,(%rdx)
  mov    %ecx,%esi
  test   %r10d,%r10d
  js     L21
  cmp    $0xff,%r10d
  mov    %r10d,%esi
  cmovg  %r12d,%esi
L21:
  mov    %sil,0x1(%rdx)
  mov    %ecx,%esi
  test   %r9d,%r9d
  js     L68
  cmp    $0xff,%r9d
  mov    %r9d,%esi
  cmovg  %r12d,%esi
L68:
  mov    %sil,0x2(%rdx)
  movzbl (%rbx,%rax,1),%esi
  lea    -0x80(%r8,%rsi,1),%esi
  sar    %esi
  movzbl 0x0(%rbp,%rax,1),%r8d
  lea    -0x80(%rdi,%r8,1),%edi
  sar    %edi
  movzbl 0x1(%r11,%rax,2),%r10d
  imul   $0x12a,%r10d,%r10d
  imul   $0x199,%edi,%r8d
  lea    0x80(%r10,%r8,1),%r8d
  imul   $0xffffff9c,%esi,%r9d
  add    %r10d,%r9d
  imul   $0xffffff30,%edi,%edi
  lea    0x80(%r9,%rdi,1),%r10d
  sar    $0x8,%r10d
  imul   $0x268,%esi,%edi
  lea    0x80(%r9,%rdi,1),%edi
  sar    $0x8,%edi
  mov    %ecx,%r9d
  mov    %r8d,%esi
  sar    $0x8,%esi
  js     L6
  cmp    $0xff,%esi
  mov    %esi,%r9d
  cmovg  %r12d,%r9d
L6:
  mov    %r9b,0x3(%rdx)
  mov    %ecx,%esi
  test   %r10d,%r10d
  js     L35
  cmp    $0xff,%r10d
  mov    %r10d,%esi
  cmovg  %r12d,%esi
L35:
  mov    %sil,0x4(%rdx)
  mov    %ecx,%esi
  test   %edi,%edi
  js     L0
  cmp    $0xff,%edi
  mov    %edi,%esi
  cmovg  %r12d,%esi
  jmp    L0
L94:
  add    -0x10(%rsp),%r11
  add    %r13,%rbx
  add    %r13,%rbp
  mov    -0x8(%rsp),%rdx
  add    %rdx,-0x20(%rsp)
L57:
  add    $0x1,%r14d
  cmp    %r14d,-0x14(%rsp)
  je     L67
L27:
  mov    -0x20(%rsp),%rdx
  mov    $0x0,%eax
  cmpl   $0x0,-0x18(%rsp)
  jg     L32
  jmp    L57
L67:
  mov    $0x0,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

assistant: ```c
int YUV422_to_RGB(unsigned char *y_input, unsigned char *u_input, unsigned char *v_input, unsigned char *rgb_output, int width, int height) {
  int R, G, B;
  int Y, U, V;
  int row;
  int col;
  for (row = 0; row < height; row++) {
    for (col = 0; col < width; col = col + 2) {
      Y = (int)(*(y_input++));
      U = (int)(*(u_input)) - 128;
      V = (int)(*(v_input)) - 128;
      R = ((298 * Y + 409 * V + 128) >> 8);
      G = ((298 * Y - 100 * U - 208 * V + 128) >> 8);
      B = ((298 * Y + 516 * U + 128) >> 8);
      *(rgb_output++) = (unsigned char)((R < 0) ? 0 : ((R > 255) ? 255 : R));
      *(rgb_output++) = (unsigned char)((G < 0) ? 0 : ((G > 255) ? 255 : G));
      *(rgb_output++) = (unsigned char)((B < 0) ? 0 : ((B > 255) ? 255 : B));
      Y = (int)(*(y_input++));
      U = (U + (int)(*(u_input++)) - 128) >> 1;
      V = (V + (int)(*(v_input++)) - 128) >> 1;
      R = ((298 * Y + 409 * V + 128) >> 8);
      G = ((298 * Y - 100 * U - 208 * V + 128) >> 8);
      B = ((298 * Y + 516 * U + 128) >> 8);
      *(rgb_output++) = (unsigned char)((R < 0) ? 0 : ((R > 255) ? 255 : R));
      *(rgb_output++) = (unsigned char)((G < 0) ? 0 : ((G > 255) ? 255 : G));
      *(rgb_output++) = (unsigned char)((B < 0) ? 0 : ((B > 255) ? 255 : B));
    }
  }
  return 0;
}
```