user: 请从给定的汇编指令推导出C源代码:

```asm
<Mutation_HitAndRun>:
  endbr64
  push   %r15
  mov    %edx,%r15d
  mov    %r9d,%edx
  push   %r14
  mov    %r8,%r14
  push   %r13
  push   %r12
  mov    %r9d,%r12d
  push   %rbp
  mov    %rsi,%rbp
  mov    %r8,%rsi
  push   %rbx
  mov    %rdi,%rbx
  sub    $0x38,%rsp
  mov    0x70(%rsp),%rax
  mov    %rcx,0x8(%rsp)
  lea    0x20(%rsp),%rdi
  movsd  %xmm0,0x10(%rsp)
  mov    0x78(%rsp),%r13
  movsd  0x0(%rbp),%xmm0
  mov    %rax,0x18(%rsp)
  movsd  %xmm1,(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0x28(%rsp)
  xor    %eax,%eax
  call   <self_adj_index_search@plt>
  mov    %r15d,%esi
  mov    %r13,%rdi
  call   <uniformdirectionrng@plt>
  xor    %eax,%eax
  call   <normalrng@plt>
  mulsd  (%rsp),%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2sd %r12d,%xmm1
  addsd  D33(%rip),%xmm1
  movsd  %xmm0,(%rsp)
  pxor   %xmm0,%xmm0
  cvtsi2sdl 0x20(%rsp),%xmm0
  divsd  %xmm1,%xmm0
  cvttsd2si %xmm0,%edi
  movsd  D6(%rip),%xmm0
  call   <pow@plt>
  mulsd  (%rsp),%xmm0
  test   %r15d,%r15d
  jle    L112
  lea    0x8(%r13),%rdx
  lea    0x10(%rbx),%rax
  cmp    %rax,%rdx
  je     L72
  cmp    $0x1,%r15d
  je     L72
  mov    %r15d,%eax
  movapd %xmm0,%xmm2
  shr    %eax
  unpcklpd %xmm2,%xmm2
  lea    -0x1(%rax),%edx
  mov    $0x8,%eax
  shl    $0x4,%rdx
  add    $0x18,%rdx
  nopw   0x0(%rax,%rax,1)
L66:
  movupd 0x0(%r13,%rax,1),%xmm1
  movupd (%rbx,%rax,1),%xmm3
  mulpd  %xmm2,%xmm1
  addpd  %xmm3,%xmm1
  movups %xmm1,0x0(%r13,%rax,1)
  add    $0x10,%rax
  cmp    %rdx,%rax
  jne    L66
  mov    %r15d,%eax
  or     $0x1,%eax
  test   $0x1,%r15b
  je     L112
  cltq
  lea    0x0(%r13,%rax,8),%rdx
  mulsd  (%rdx),%xmm0
  addsd  (%rbx,%rax,8),%xmm0
  movsd  %xmm0,(%rdx)
L112:
  mov    %r15d,%esi
  mov    %r13,%rdi
  call   <cost@plt>
  lea    0x24(%rsp),%rdi
  mov    %r12d,%edx
  mov    %r14,%rsi
  movsd  %xmm0,(%rsp)
  call   <self_adj_index_search@plt>
  movsd  0x10(%rsp),%xmm6
  movsd  (%rsp),%xmm1
  movslq 0x24(%rsp),%rax
  mov    0x8(%rsp),%rcx
  divsd  %xmm6,%xmm1
  movsd  (%rcx,%rax,8),%xmm0
  xorpd  D39(%rip),%xmm0
  movslq 0x20(%rsp),%rax
  subsd  %xmm1,%xmm0
  movsd  0x0(%rbp),%xmm1
  addsd  (%rcx,%rax,8),%xmm0
  mov    D33(%rip),%rax
  divsd  %xmm6,%xmm1
  addsd  %xmm1,%xmm0
  comisd D24(%rip),%xmm0
  movq   %rax,%xmm1
  jbe    L8
L179:
  mov    0x18(%rsp),%r14
  xor    %eax,%eax
  movsd  %xmm1,(%r14)
  call   <uniformrng@plt>
  movsd  (%r14),%xmm1
  comisd %xmm0,%xmm1
  jbe    L79
  movsd  (%rsp),%xmm5
  movsd  %xmm5,0x0(%rbp)
  test   %r15d,%r15d
  jle    L79
  lea    0x10(%r13),%rdx
  lea    0x8(%rbx),%rax
  cmp    %rax,%rdx
  je     L43
  lea    -0x1(%r15),%eax
  cmp    $0x2,%eax
  jbe    L43
  mov    %r15d,%eax
  shr    %eax
  lea    -0x1(%rax),%edx
  mov    $0x8,%eax
  shl    $0x4,%rdx
  add    $0x18,%rdx
  nopl   0x0(%rax)
L25:
  movupd 0x0(%r13,%rax,1),%xmm4
  movups %xmm4,(%rbx,%rax,1)
  add    $0x10,%rax
  cmp    %rdx,%rax
  jne    L25
  mov    %r15d,%eax
  or     $0x1,%eax
  and    $0x1,%r15d
  je     L79
  cltq
  movsd  0x0(%r13,%rax,8),%xmm0
  movsd  %xmm0,(%rbx,%rax,8)
L79:
  mov    0x28(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L171
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   (%rax)
L8:
  call   <exp@plt>
  movapd %xmm0,%xmm1
  jmp    L179
  xchg   %ax,%ax
L72:
  lea    0x1(%r15),%edx
  mov    $0x1,%eax
  nopl   0x0(%rax)
L161:
  movsd  0x0(%r13,%rax,8),%xmm1
  mulsd  %xmm0,%xmm1
  addsd  (%rbx,%rax,8),%xmm1
  movsd  %xmm1,0x0(%r13,%rax,8)
  add    $0x1,%rax
  cmp    %rdx,%rax
  jne    L161
  jmp    L112
L43:
  lea    0x1(%r15),%edx
  mov    $0x1,%eax
  xchg   %ax,%ax
L62:
  movsd  0x0(%r13,%rax,8),%xmm0
  movsd  %xmm0,(%rbx,%rax,8)
  add    $0x1,%rax
  cmp    %rax,%rdx
  jne    L62
  jmp    L79
L171:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: retrieve_data
arguments: tag: D33
datatype: f64
name: retrieve_data
arguments: tag: D6
datatype: f64
name: retrieve_data
arguments: tag: D39
datatype: f32[4]
name: retrieve_data
arguments: tag: D24
datatype: f32

tool: D33: 1

tool: D6: 0.5

tool: {"D39": [0.0,-0.0,0.0,0.0]}

tool: D24: 0

assistant: ```c
void Mutation_HitAndRun(double *z, double *fz, int N_dimension, double *theta, double *grid_points, int grid_size, double temp, double scl, double *accpr_pop, double *z_new) {
  int k_old;
  int k_new;
  int i;
  double fz_new;
  double rat;
  double un;
  self_adj_index_search(&k_old, *fz, grid_points, grid_size);
  uniformdirectionrng(z_new, N_dimension);
  un = normalrng() * scl * pow(k_old / (grid_size + 1.0), 0.5);
  for (i = 1; i <= N_dimension; i++)
    z_new[i] = z[i] + z_new[i] * un;
  fz_new = cost(z_new, N_dimension);
  self_adj_index_search(&k_new, fz_new, grid_points, grid_size);
  rat = -theta[k_new] - fz_new / temp + theta[k_old] + *fz / temp;
  *accpr_pop = ((rat > 0.0) ? 1.0 : exp(rat));
  un = uniformrng();
  if (*accpr_pop > un) {
    *fz = fz_new;
    for (i = 1; i <= N_dimension; i++)
      z[i] = z_new[i];
  }
}
```