user: Demonstrate the C code that generates the assembly output below:

```asm
<codegen>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x1000,%rsp
  orq    $0x0,(%rsp)
  sub    $0x1000,%rsp
  orq    $0x0,(%rsp)
  sub    $0x110,%rsp
  mov    %rdi,-0x2108(%rbp)
  mov    %esi,-0x210c(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movl   $0x5,-0x2090(%rbp)
  movl   $0x6,-0x208c(%rbp)
  movl   $0x7,-0x2088(%rbp)
  movl   $0x8,-0x2084(%rbp)
  movl   $0x11,-0x2080(%rbp)
  movl   $0x12,-0x207c(%rbp)
  movl   $0x8b,-0x2078(%rbp)
  movl   $0x8c,-0x2074(%rbp)
  movl   $0x8d,-0x2070(%rbp)
  movl   $0xfb,-0x206c(%rbp)
  movl   $0xfc,-0x2068(%rbp)
  movl   $0xfe,-0x2064(%rbp)
  movl   $0xff,-0x2060(%rbp)
  movl   $0x100,-0x205c(%rbp)
  movl   $0x101,-0x2058(%rbp)
  movl   $0x102,-0x2054(%rbp)
  movl   $0x1d5,-0x2050(%rbp)
  movl   $0x1d6,-0x204c(%rbp)
  movl   $0x1d7,-0x2048(%rbp)
  movl   $0x1d8,-0x2044(%rbp)
  movl   $0x1d9,-0x2040(%rbp)
  movl   $0x1da,-0x203c(%rbp)
  movl   $0x1fd,-0x2038(%rbp)
  movl   $0x200,-0x2034(%rbp)
  movl   $0x201,-0x2030(%rbp)
  movl   $0x202,-0x202c(%rbp)
  movl   $0x203,-0x2028(%rbp)
  movl   $0x204,-0x2024(%rbp)
  movl   $0x35b,-0x2020(%rbp)
  movl   $0x35c,-0x201c(%rbp)
  movl   $0x35d,-0x2018(%rbp)
  movl   $0x35e,-0x2014(%rbp)
  cmpl   $0x0,-0x210c(%rbp)
  jle    L111
  cmpl   $0x20,-0x210c(%rbp)
  jg     L111
  movl   $0x0,-0x2100(%rbp)
  jmp    L102
L84:
  mov    -0x2100(%rbp),%eax
  cltq
  movl   $0xffffffff,-0x20c0(%rbp,%rax,4)
  mov    -0x2100(%rbp),%eax
  cltq
  mov    -0x20c0(%rbp,%rax,4),%edx
  mov    -0x2100(%rbp),%eax
  cltq
  mov    %edx,-0x20f0(%rbp,%rax,4)
  addl   $0x1,-0x2100(%rbp)
L102:
  cmpl   $0x9,-0x2100(%rbp)
  jle    L84
  movl   $0x0,-0x2100(%rbp)
  jmp    L3
L20:
  mov    -0x20cc(%rbp),%edx
  mov    -0x2100(%rbp),%eax
  cltq
  mov    %edx,-0x2010(%rbp,%rax,4)
  mov    -0x209c(%rbp),%edx
  mov    -0x2100(%rbp),%eax
  cltq
  mov    %edx,-0x1010(%rbp,%rax,4)
  mov    -0x20e8(%rbp),%edx
  mov    -0x20cc(%rbp),%eax
  imul   %edx,%eax
  mov    %eax,-0x20f8(%rbp)
  mov    -0x20bc(%rbp),%edx
  mov    -0x20b8(%rbp),%eax
  imul   %eax,%edx
  mov    -0x20ac(%rbp),%eax
  imul   %eax,%edx
  mov    -0x20a4(%rbp),%eax
  imul   %eax,%edx
  mov    -0x20a0(%rbp),%eax
  imul   %eax,%edx
  mov    -0x209c(%rbp),%eax
  imul   %edx,%eax
  mov    %eax,-0x20f4(%rbp)
  movl   $0x9,-0x20fc(%rbp)
  jmp    L29
L6:
  mov    -0x20fc(%rbp),%eax
  sub    $0x1,%eax
  cltq
  mov    -0x20f0(%rbp,%rax,4),%edx
  mov    -0x20fc(%rbp),%eax
  cltq
  mov    %edx,-0x20f0(%rbp,%rax,4)
  mov    -0x20fc(%rbp),%eax
  sub    $0x1,%eax
  cltq
  mov    -0x20c0(%rbp,%rax,4),%edx
  mov    -0x20fc(%rbp),%eax
  cltq
  mov    %edx,-0x20c0(%rbp,%rax,4)
  subl   $0x1,-0x20fc(%rbp)
L29:
  cmpl   $0x0,-0x20fc(%rbp)
  jg     L6
  mov    -0x20f8(%rbp),%eax
  mov    %eax,-0x20f0(%rbp)
  mov    -0x20f4(%rbp),%eax
  mov    %eax,-0x20c0(%rbp)
  addl   $0x1,-0x2100(%rbp)
L3:
  cmpl   $0x3fe,-0x2100(%rbp)
  jle    L20
  movl   $0x0,-0x2100(%rbp)
  mov    -0x210c(%rbp),%eax
  sub    $0x1,%eax
  cltq
  mov    -0x2090(%rbp,%rax,4),%edx
  mov    $0x3ff,%eax
  sub    %edx,%eax
  mov    %eax,-0x20fc(%rbp)
  jmp    L72
L63:
  mov    -0x2100(%rbp),%eax
  cltq
  mov    -0x2010(%rbp,%rax,4),%esi
  mov    -0x20fc(%rbp),%eax
  movslq %eax,%rdx
  imul   $0xffffffff80200803,%rdx,%rdx
  shr    $0x20,%rdx
  add    %eax,%edx
  sar    $0x9,%edx
  mov    %eax,%ecx
  sar    $0x1f,%ecx
  sub    %ecx,%edx
  mov    %edx,%ecx
  shl    $0xa,%ecx
  sub    %edx,%ecx
  sub    %ecx,%eax
  mov    %eax,%edx
  movslq %edx,%rax
  mov    -0x1010(%rbp,%rax,4),%eax
  imul   %esi,%eax
  mov    $0x1,%edx
  sub    %eax,%edx
  mov    -0x2100(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rcx
  mov    -0x2108(%rbp),%rax
  add    %rcx,%rax
  mov    %edx,%ecx
  shr    $0x1f,%ecx
  add    %ecx,%edx
  sar    %edx
  mov    %edx,(%rax)
  addl   $0x1,-0x2100(%rbp)
  addl   $0x1,-0x20fc(%rbp)
L72:
  cmpl   $0x3fe,-0x2100(%rbp)
  jle    L63
  jmp    L91
L111:
  nop
L91:
  mov    -0x8(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L71
  call   <__stack_chk_fail@plt>
L71:
  leave
  ret
```

assistant: ```c
void codegen(int *ca, int prn) {
  int delay[] = {5, 6, 7, 8, 17, 18, 139, 140, 141, 251, 252, 254, 255, 256, 257, 258, 469, 470, 471, 472, 473, 474, 509, 512, 513, 514, 515, 516, 859, 860, 861, 862};
  int g1[1023], g2[1023], r1[10], r2[10], c1, c2;
  int i, j;
  if (prn < 1 || prn > 32)
    return;
  for (i = 0; i < 10; i++)
    r1[i] = r2[i] = -1;
  for (i = 0; i < 1023; i++) {
    g1[i] = r1[9];
    g2[i] = r2[9];
    c1 = r1[2] * r1[9];
    c2 = r2[1] * r2[2] * r2[5] * r2[7] * r2[8] * r2[9];
    for (j = 9; j > 0; j--) {
      r1[j] = r1[j - 1];
      r2[j] = r2[j - 1];
    }
    r1[0] = c1;
    r2[0] = c2;
  }
  for (i = 0, j = 1023 - delay[prn - 1]; i < 1023; i++, j++)
    ca[i] = (1 - g1[i] * g2[j % 1023]) / 2;
  return;
}
```