user: 下面的汇编指令对应的C源代码是什么：

```asm
<test_pmfrand>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbx
  sub    $0x78,%rsp
  mov    %edi,-0x74(%rbp)
  mov    %rsi,-0x80(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  xor    %eax,%eax
  mov    %rsp,%rax
  mov    %rax,%rbx
  cmpl   $0x2,-0x74(%rbp)
  jg     L91
  mov    -0x80(%rbp),%rax
  mov    (%rax),%rax
  mov    %rax,%rsi
  lea    D46(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L141
L91:
  mov    -0x80(%rbp),%rax
  add    $0x8,%rax
  mov    (%rax),%rax
  mov    %rax,%rdi
  call   <atoi@plt>
  mov    %eax,-0x60(%rbp)
  mov    -0x60(%rbp),%eax
  add    $0x1,%eax
  cmp    %eax,-0x74(%rbp)
  jg     L12
  mov    -0x80(%rbp),%rax
  mov    (%rax),%rax
  mov    %rax,%rsi
  lea    D46(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L141
L12:
  mov    -0x60(%rbp),%eax
  movslq %eax,%rdx
  sub    $0x1,%rdx
  mov    %rdx,-0x58(%rbp)
  movslq %eax,%rdx
  mov    %rdx,-0x90(%rbp)
  movq   $0x0,-0x88(%rbp)
  movslq %eax,%rdx
  mov    %rdx,-0xa0(%rbp)
  movq   $0x0,-0x98(%rbp)
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    $0x10,%eax
  sub    $0x1,%rax
  add    %rdx,%rax
  mov    $0x10,%esi
  mov    $0x0,%edx
  div    %rsi
  imul   $0x10,%rax,%rax
  mov    %rax,%rcx
  and    $0xfffffffffffff000,%rcx
  mov    %rsp,%rdx
  sub    %rcx,%rdx
L218:
  cmp    %rdx,%rsp
  je     L63
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  jmp    L218
L63:
  mov    %rax,%rdx
  and    $0xfff,%edx
  sub    %rdx,%rsp
  mov    %rax,%rdx
  and    $0xfff,%edx
  test   %rdx,%rdx
  je     L11
  and    $0xfff,%eax
  sub    $0x8,%rax
  add    %rsp,%rax
  orq    $0x0,(%rax)
L11:
  mov    %rsp,%rax
  add    $0x7,%rax
  shr    $0x3,%rax
  shl    $0x3,%rax
  mov    %rax,-0x50(%rbp)
  movl   $0x0,-0x64(%rbp)
  jmp    L89
L19:
  mov    -0x64(%rbp),%eax
  cltq
  add    $0x2,%rax
  lea    0x0(,%rax,8),%rdx
  mov    -0x80(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rax
  mov    %rax,%rdi
  call   <atof@plt>
  movq   %xmm0,%rax
  mov    -0x50(%rbp),%rdx
  mov    -0x64(%rbp),%ecx
  movslq %ecx,%rcx
  mov    %rax,(%rdx,%rcx,8)
  addl   $0x1,-0x64(%rbp)
L89:
  mov    -0x64(%rbp),%eax
  cmp    -0x60(%rbp),%eax
  jl     L19
  movl   $0x2710,-0x5c(%rbp)
  mov    -0x5c(%rbp),%eax
  movslq %eax,%rdx
  sub    $0x1,%rdx
  mov    %rdx,-0x48(%rbp)
  movslq %eax,%rdx
  mov    %rdx,%r14
  mov    $0x0,%r15d
  movslq %eax,%rdx
  mov    %rdx,%r12
  mov    $0x0,%r13d
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    $0x10,%eax
  sub    $0x1,%rax
  add    %rdx,%rax
  mov    $0x10,%esi
  mov    $0x0,%edx
  div    %rsi
  imul   $0x10,%rax,%rax
  mov    %rax,%rcx
  and    $0xfffffffffffff000,%rcx
  mov    %rsp,%rdx
  sub    %rcx,%rdx
L116:
  cmp    %rdx,%rsp
  je     L28
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  jmp    L116
L28:
  mov    %rax,%rdx
  and    $0xfff,%edx
  sub    %rdx,%rsp
  mov    %rax,%rdx
  and    $0xfff,%edx
  test   %rdx,%rdx
  je     L27
  and    $0xfff,%eax
  sub    $0x8,%rax
  add    %rsp,%rax
  orq    $0x0,(%rax)
L27:
  mov    %rsp,%rax
  add    $0x3,%rax
  shr    $0x2,%rax
  shl    $0x2,%rax
  mov    %rax,-0x40(%rbp)
  movl   $0x0,-0x64(%rbp)
  jmp    L22
L14:
  mov    -0x60(%rbp),%edx
  mov    -0x50(%rbp),%rax
  mov    %edx,%esi
  mov    %rax,%rdi
  call   <pmfrand@plt>
  mov    -0x40(%rbp),%rdx
  mov    -0x64(%rbp),%ecx
  movslq %ecx,%rcx
  mov    %eax,(%rdx,%rcx,4)
  addl   $0x1,-0x64(%rbp)
L22:
  mov    -0x64(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L14
  movl   $0x0,-0x64(%rbp)
  jmp    L165
L107:
  mov    -0x50(%rbp),%rax
  mov    -0x64(%rbp),%edx
  movslq %edx,%rdx
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax,%rdx,8)
  addl   $0x1,-0x64(%rbp)
L165:
  mov    -0x64(%rbp),%eax
  cmp    -0x60(%rbp),%eax
  jl     L107
  movl   $0x0,-0x64(%rbp)
  jmp    L189
L187:
  mov    -0x40(%rbp),%rax
  mov    -0x64(%rbp),%edx
  movslq %edx,%rdx
  mov    (%rax,%rdx,4),%eax
  mov    -0x50(%rbp),%rdx
  movslq %eax,%rcx
  movsd  (%rdx,%rcx,8),%xmm1
  movsd  D39(%rip),%xmm0
  addsd  %xmm1,%xmm0
  mov    -0x50(%rbp),%rdx
  cltq
  movsd  %xmm0,(%rdx,%rax,8)
  addl   $0x1,-0x64(%rbp)
L189:
  mov    -0x64(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L187
  pxor   %xmm1,%xmm1
  cvtsi2sdl -0x5c(%rbp),%xmm1
  movsd  D39(%rip),%xmm0
  divsd  %xmm1,%xmm0
  cvttsd2si %xmm0,%edx
  mov    -0x60(%rbp),%ecx
  mov    -0x50(%rbp),%rsi
  mov    -0x50(%rbp),%rax
  mov    %rax,%rdi
  call   <mult@plt>
  lea    D0(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  movl   $0x0,-0x64(%rbp)
  jmp    L43
L71:
  mov    -0x50(%rbp),%rax
  mov    -0x64(%rbp),%edx
  movslq %edx,%rdx
  mov    (%rax,%rdx,8),%rax
  movq   %rax,%xmm0
  lea    D32(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  addl   $0x1,-0x64(%rbp)
L43:
  mov    -0x64(%rbp),%eax
  cmp    -0x60(%rbp),%eax
  jl     L71
  lea    D69(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  mov    %rbx,%rsp
  jmp    L167
L141:
  mov    %rbx,%rsp
L167:
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L169
  call   <__stack_chk_fail@plt>
L169:
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D46
data_type: string
name: extract_symbolic_data
arguments: data_tag: D39
data_type: byte[8]
name: extract_symbolic_data
arguments: data_tag: D0
data_type: string
name: extract_symbolic_data
arguments: data_tag: D32
data_type: string
name: extract_symbolic_data
arguments: data_tag: D69
data_type: string

tool: D46: usage: %s <n> <w1> ... <wn>


tool: {"D39": [0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x3f]}

tool: D0: w2 = [

tool: D32: %.2f, 

tool: D69: ]

assistant: ```c
void test_pmfrand(int argc, char *argv[]) {
  if (argc < 3) {
    printf("usage: %s <n> <w1> ... <wn>\n", argv[0]);
    return;
  }
  int n = atoi(argv[1]);
  if (argc < n + 2) {
    printf("usage: %s <n> <w1> ... <wn>\n", argv[0]);
    return;
  }
  int i;
  double w[n];
  for (i = 0; i < n; i++)
    w[i] = atof(argv[i + 2]);
  int nsamples = 10000;
  int x[nsamples];
  for (i = 0; i < nsamples; i++)
    x[i] = pmfrand(w, n);
  for (i = 0; i < n; i++)
    w[i] = 0;
  for (i = 0; i < nsamples; i++)
    w[x[i]]++;
  mult(w, w, 1 / (double)nsamples, n);
  printf("w2 = [");
  for (i = 0; i < n; i++)
    printf("%.2f, ", w[i]);
  printf("]\n");
}
```