user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<benchmark>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbx
  sub    $0x28,%rsp
  mov    %edi,%r13d
  mov    %esi,%r12d
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  xor    %eax,%eax
  movslq %esi,%rax
  lea    0xf(,%rax,8),%rax
  mov    %rax,%rcx
  and    $0xfffffffffffffff0,%rcx
  and    $0xfffffffffffff000,%rax
  mov    %rsp,%rdx
  sub    %rax,%rdx
L51:
  cmp    %rdx,%rsp
  je     L13
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  jmp    L51
L13:
  mov    %rcx,%rax
  and    $0xfff,%eax
  sub    %rax,%rsp
  test   %rax,%rax
  je     L30
  orq    $0x0,-0x8(%rsp,%rax,1)
L30:
  mov    %rsp,%r14
  test   %r12d,%r12d
  jle    L69
  mov    %r14,%rbx
  mov    %r12d,%eax
  lea    (%r14,%rax,8),%r15
  jmp    L142
L130:
  mov    $0x0,%eax
  call   <rand_double@plt>
  mulsd  D37(%rip),%xmm0
  subsd  D3(%rip),%xmm0
L27:
  movsd  %xmm0,(%rbx)
  add    $0x8,%rbx
  cmp    %r15,%rbx
  je     L69
L142:
  mov    $0x0,%eax
  call   <rand_double@plt>
  movsd  D47(%rip),%xmm1
  comisd %xmm0,%xmm1
  jbe    L130
  pxor   %xmm0,%xmm0
  divsd  %xmm0,%xmm0
  jmp    L27
L69:
  mov    $0x0,%eax
  call   <tic@plt>
  movsd  %xmm0,-0x48(%rbp)
  test   %r13d,%r13d
  jle    L31
  mov    $0x0,%ebx
  lea    -0x40(%rbp),%r15
L8:
  mov    %r15,%rcx
  mov    $0x1,%edx
  mov    %r14,%rsi
  mov    %r12d,%edi
  call   <stdlib_strided_dnannsumkbn@plt>
  ucomisd %xmm0,%xmm0
  jp     L24
  cmpq   $0x0,-0x40(%rbp)
  js     L157
  add    $0x1,%ebx
  cmp    %ebx,%r13d
  jne    L8
L31:
  mov    $0x0,%eax
  call   <tic@plt>
  subsd  -0x48(%rbp),%xmm0
  movq   %xmm0,%rbx
L106:
  cmpq   $0x0,-0x40(%rbp)
  jns    L152
  jmp    L84
L24:
  lea    D38(%rip),%rdi
  call   <printf@plt>
  mov    $0x0,%eax
  call   <tic@plt>
  subsd  -0x48(%rbp),%xmm0
  movq   %xmm0,%rbx
L84:
  lea    D38(%rip),%rdi
  call   <printf@plt>
L152:
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  jne    L77
  movq   %rbx,%xmm0
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
L157:
  lea    D38(%rip),%rdi
  call   <printf@plt>
  mov    $0x0,%eax
  call   <tic@plt>
  subsd  -0x48(%rbp),%xmm0
  movq   %xmm0,%rbx
  jmp    L106
L77:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D37
type_guessed: f64
name: extract_symbolic_data
arguments: data_label: D3
type_guessed: f64
name: extract_symbolic_data
arguments: data_label: D47
type_guessed: f64
name: extract_symbolic_data
arguments: data_label: D38
type_guessed: string

tool: D37: 20000

tool: D3: 10000

tool: D47: 0.2

tool: D38: should not return NaN


assistant: ```c
double benchmark(int iterations, int len) {
  double elapsed;
  double x[len];
  int64_t n;
  double v;
  double t;
  int i;
  for (i = 0; i < len; i++) {
    if (rand_double() < 0.2) {
      x[i] = 0.0 / 0.0;
    } else {
      x[i] = (rand_double() * 20000.0) - 10000.0;
    }
  }
  v = 0.0;
  t = tic();
  for (i = 0; i < iterations; i++) {
    v = stdlib_strided_dnannsumkbn(len, x, 1, &n);
    if (v != v || n < 0) {
      printf("should not return NaN\n");
      break;
    }
  }
  elapsed = tic() - t;
  if (v != v || n < 0) {
    printf("should not return NaN\n");
  }
  return elapsed;
}
```