user: 请将以下的汇编代码转换成C语言代码：

```asm
<extremum>:
  endbr64
  push   %r15
  movapd %xmm0,%xmm3
  pxor   %xmm1,%xmm1
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  mov    %rcx,%rbx
  sub    $0xf8,%rsp
  mov    %rdx,0x20(%rsp)
  mov    0x20(%rsp),%rdx
  lea    0x30(%rsp),%r13
  mov    %rdi,0x18(%rsp)
  mov    %esi,0x2c(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0xe8(%rsp)
  xor    %eax,%eax
  mov    %eax,(%rdx)
  cmp    %eax,0x2c(%rsp)
  jle    L14
  nopw   0x0(%rax,%rax,1)
L29:
  lea    0x90(%rsp),%r15
  xor    %r14d,%r14d
  mov    %r15,%r12
  jmp    L121
L71:
  movsd  %xmm2,0x40(%rsp)
  movapd %xmm0,%xmm1
  movsd  %xmm0,0x90(%rsp)
L137:
  add    $0x1,%r14
  add    $0x8,%r12
L121:
  mov    %r14d,%ebp
  movapd %xmm1,%xmm0
  cmp    $0x2,%r14
  ja     L141
  mov    0x18(%rsp),%rax
  pxor   %xmm0,%xmm0
  cvtsi2sd %r14d,%xmm0
  mulsd  D58(%rip),%xmm0
  addsd  (%rax),%xmm0
L141:
  movsd  %xmm3,0x8(%rsp)
  mov    %r13,%rdi
  mov    $0x1,%eax
  movsd  %xmm1,(%rsp)
  movsd  %xmm0,0x10(%rsp)
  call   *%rbx
  movsd  0x38(%rsp),%xmm2
  movq   D69(%rip),%xmm4
  movsd  0x8(%rsp),%xmm3
  movsd  (%rsp),%xmm1
  movapd %xmm2,%xmm6
  andpd  %xmm4,%xmm6
  comisd %xmm6,%xmm3
  ja     L56
  test   %r14,%r14
  movsd  0x10(%rsp),%xmm0
  movq   D47(%rip),%xmm5
  je     L71
  lea    0x40(%rsp),%rsi
  xor    %eax,%eax
  movsd  %xmm2,(%rsi,%r14,8)
  jmp    L59
  xchg   %ax,%ax
L101:
  movapd %xmm2,%xmm0
  subsd  (%rsi,%rax,8),%xmm0
  add    $0x1,%rax
  divsd  %xmm1,%xmm0
  movsd  %xmm0,(%r12)
  cmp    %eax,%ebp
  jle    L90
L59:
  movapd %xmm0,%xmm1
  subsd  (%r15,%rax,8),%xmm1
  movapd %xmm1,%xmm0
  andpd  %xmm4,%xmm0
  comisd %xmm0,%xmm3
  jbe    L101
  mov    D50(%rip),%rax
  mov    %rax,(%r12)
  movq   %rax,%xmm0
L90:
  lea    -0x1(%r14),%rax
  pxor   %xmm1,%xmm1
  jmp    L57
  nopl   (%rax)
L50:
  movsd  0x8(%r15,%rax,8),%xmm0
L57:
  addsd  %xmm1,%xmm0
  movsd  (%rsi,%rax,8),%xmm1
  sub    $0x1,%rax
  xorpd  %xmm5,%xmm1
  divsd  %xmm0,%xmm1
  cmp    $0xffffffff,%eax
  jne    L50
  addsd  0x90(%rsp),%xmm1
  cmp    $0x7,%r14
  jne    L137
  mov    0x18(%rsp),%rax
  mov    0x20(%rsp),%rdx
  movsd  %xmm1,(%rax)
  mov    0x20(%rsp),%rax
  mov    (%rax),%eax
  mov    %eax,(%rsp)
  add    $0x1,%eax
  mov    %eax,(%rdx)
  cmp    %eax,0x2c(%rsp)
  jg     L29
L14:
  mov    0x18(%rsp),%rax
  movsd  (%rax),%xmm1
  jmp    L73
  cs nopw 0x0(%rax,%rax,1)
L56:
  mov    0x18(%rsp),%rax
  movsd  %xmm1,(%rax)
  mov    0x20(%rsp),%rax
  addl   $0x1,(%rax)
L73:
  movapd %xmm1,%xmm0
  mov    $0x1,%eax
  mov    %r13,%rdi
  call   *%rbx
  movsd  0x30(%rsp),%xmm0
  mov    0x18(%rsp),%rax
  movq   D69(%rip),%xmm4
  movsd  D32(%rip),%xmm3
  movsd  %xmm0,0x8(%rax)
  movsd  (%rax),%xmm0
  movsd  D29(%rip),%xmm1
  movapd %xmm0,%xmm2
  andpd  %xmm4,%xmm2
  comisd %xmm2,%xmm3
  jae    L63
  mulsd  %xmm0,%xmm1
  andpd  %xmm4,%xmm1
L63:
  subsd  %xmm1,%xmm0
  movsd  %xmm1,(%rsp)
  mov    %r13,%rdi
  mov    $0x1,%eax
  call   *%rbx
  mov    0x18(%rsp),%r14
  movsd  (%rsp),%xmm1
  mov    %r13,%rdi
  mov    0x30(%rsp),%rbp
  mov    $0x1,%eax
  addsd  (%r14),%xmm1
  movapd %xmm1,%xmm0
  call   *%rbx
  movq   %rbp,%xmm0
  pxor   %xmm7,%xmm7
  mov    0x20(%rsp),%rdx
  movsd  0x8(%r14),%xmm1
  addsd  0x30(%rsp),%xmm0
  addsd  %xmm1,%xmm1
  subsd  %xmm1,%xmm0
  comisd %xmm0,%xmm7
  sbb    %eax,%eax
  or     $0x1,%eax
  mov    %eax,0x4(%rdx)
  mov    0xe8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L38
  add    $0xf8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L38:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: label: D58
type: f64
name: disassemble_data
arguments: label: D69
type: qword
name: disassemble_data
arguments: label: D47
type: f32[2]
name: disassemble_data
arguments: label: D50
type: byte[8]
name: disassemble_data
arguments: label: D32
type: f64
name: disassemble_data
arguments: label: D29
type: byte[8]

tool: D58: 0.01

tool: D69: 9223372036854775807

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

tool: {"D50": [0x82,0x4d,0xc7,0x72,0x61,0x42,0x33,0x47]}

tool: D32: 1

tool: {"D29": [0xf1,0x68,0xe3,0x88,0xb5,0xf8,0xe4,0x3e]}

assistant: ```c
void extremum(double x[], double eps, int k, int js[], void (*f)()) {
  int i, j, done = 0;
  double t, h1, h2, dx, y[10], b[10], z[2];
  js[0] = 0;
  h2 = 0.0;
  while (!done && js[0] < k) {
    for (j = 0; j <= 7; j++) {
      if (j <= 2)
        t = x[0] + 0.01 * j;
      else
        t = h2;
      (*f)(t, z);
      if (fabs(z[1]) < eps) {
        done = 1;
        break;
      } else {
        h1 = z[1];
        h2 = t;
        if (j == 0) {
          y[0] = h1;
          b[0] = h2;
        } else {
          y[j] = h1;
          for (i = 0; i < j; i++) {
            if (fabs(h2 - b[i]) < eps) {
              b[j] = 1.0e+35;
              break;
            }
            b[j] = h2 = (h1 - y[i]) / (h2 - b[i]);
          }
          h2 = 0.0;
          for (i = j - 1; i >= 0; i--)
            h2 = -y[i] / (b[i + 1] + h2);
          h2 = h2 + b[0];
        }
      }
    }
    x[0] = h2;
    js[0]++;
  }
  t = x[0];
  (*f)(t, z);
  x[1] = z[0];
  if (fabs(x[0]) <= 1.0)
    dx = 1.0e-05;
  else
    dx = fabs(x[0] * 1.0e-05);
  t = x[0] - dx;
  (*f)(t, z);
  h1 = z[0];
  t = x[0] + dx;
  (*f)(t, z);
  h2 = z[0];
  if ((h1 + h2 - 2.0 * x[1]) <= 0.0)
    js[1] = 1;
  else
    js[1] = -1;
}
```