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

```asm
<binary_ks>:
  endbr64
  cmp    $0x1,%edi
  jle    L358
  push   %rbp
  mov    %edi,%ebp
  push   %rbx
  sub    $0x68,%rsp
L64:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x8(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x8(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L65
  jne    L65
  mulsd  D176(%rip),%xmm0
L65:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x8(%rsp)
  movsd  %xmm1,0x28(%rsp)
  call   <add_to_array@plt>
  movsd  0x8(%rsp),%xmm0
  movsd  0x28(%rsp),%xmm1
  mov    %ebp,%edi
  call   <make_hdl@plt>
  movsd  0x8(%rsp),%xmm0
  cvttsd2si %xmm0,%ebp
  cmp    $0x1,%ebp
  jle    L207
L84:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x8(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x8(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L257
  jne    L257
  mulsd  D176(%rip),%xmm0
L257:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x8(%rsp)
  movsd  %xmm1,0x30(%rsp)
  call   <add_to_array@plt>
  movsd  0x8(%rsp),%xmm0
  movsd  0x30(%rsp),%xmm1
  mov    %ebp,%edi
  call   <make_hdl@plt>
  movsd  0x8(%rsp),%xmm0
  cvttsd2si %xmm0,%ebp
  cmp    $0x1,%ebp
  jle    L337
L192:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x8(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x8(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L39
  jne    L39
  mulsd  D176(%rip),%xmm0
L39:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x8(%rsp)
  movsd  %xmm1,0x38(%rsp)
  call   <add_to_array@plt>
  movsd  0x8(%rsp),%xmm0
  movsd  0x38(%rsp),%xmm1
  mov    %ebp,%edi
  call   <make_hdl@plt>
  movsd  0x8(%rsp),%xmm0
  cvttsd2si %xmm0,%ebp
  cmp    $0x1,%ebp
  jle    L333
L348:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x8(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x8(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L164
  jne    L164
  mulsd  D176(%rip),%xmm0
L164:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x8(%rsp)
  movsd  %xmm1,0x40(%rsp)
  call   <add_to_array@plt>
  movsd  0x8(%rsp),%xmm0
  movsd  0x40(%rsp),%xmm1
  mov    %ebp,%edi
  call   <make_hdl@plt>
  movsd  0x8(%rsp),%xmm0
  cvttsd2si %xmm0,%ebp
  cmp    $0x1,%ebp
  jle    L353
L187:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x8(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x8(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L8
  jne    L8
  mulsd  D176(%rip),%xmm0
L8:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x10(%rsp)
  movsd  %xmm1,0x8(%rsp)
  call   <add_to_array@plt>
  movsd  0x10(%rsp),%xmm0
  movsd  0x8(%rsp),%xmm1
  mov    %ebp,%edi
  call   <make_hdl@plt>
  movsd  0x10(%rsp),%xmm0
  cvttsd2si %xmm0,%ebp
  cmp    $0x1,%ebp
  jle    L49
L184:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x10(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x10(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L158
  jne    L158
  mulsd  D176(%rip),%xmm0
L158:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x10(%rsp)
  movsd  %xmm1,0x20(%rsp)
  call   <add_to_array@plt>
  movsd  0x10(%rsp),%xmm0
  movsd  0x20(%rsp),%xmm1
  mov    %ebp,%edi
  call   <make_hdl@plt>
  movsd  0x10(%rsp),%xmm0
  cvttsd2si %xmm0,%ebp
  cmp    $0x1,%ebp
  jle    L341
L167:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x10(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x10(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L202
  jne    L202
  mulsd  D176(%rip),%xmm0
L202:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x10(%rsp)
  movsd  %xmm1,0x48(%rsp)
  call   <add_to_array@plt>
  movsd  0x10(%rsp),%xmm0
  movsd  0x48(%rsp),%xmm1
  mov    %ebp,%edi
  call   <make_hdl@plt>
  movsd  0x10(%rsp),%xmm0
  cvttsd2si %xmm0,%ebp
  cmp    $0x1,%ebp
  jle    L93
L103:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x10(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x10(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L208
  jne    L208
  mulsd  D176(%rip),%xmm0
L208:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x18(%rsp)
  movsd  %xmm1,0x10(%rsp)
  call   <add_to_array@plt>
  movsd  0x18(%rsp),%xmm0
  movsd  0x10(%rsp),%xmm1
  mov    %ebp,%edi
  call   <make_hdl@plt>
  movsd  0x18(%rsp),%xmm0
  cvttsd2si %xmm0,%ebp
  cmp    $0x1,%ebp
  jle    L347
L55:
  pxor   %xmm1,%xmm1
  cvtsi2sd %ebp,%xmm1
  movapd %xmm1,%xmm0
  movsd  %xmm1,0x18(%rsp)
  call   <log@plt>
  mov    %eax,%ebx
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <log@plt>
  mov    %eax,%r8d
  mov    %ebx,%eax
  cltd
  idiv   %r8d
  mov    %eax,%edi
  call   <floor@plt>
  mov    %eax,%edi
  mov    D181(%rip),%rax
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  0x18(%rsp),%xmm1
  ucomisd %xmm0,%xmm1
  jp     L148
  jne    L148
  mulsd  D176(%rip),%xmm0
L148:
  subsd  %xmm0,%xmm1
  mov    %ebp,%edi
  movsd  %xmm0,0x58(%rsp)
  movsd  %xmm1,0x18(%rsp)
  call   <add_to_array@plt>
  movsd  0x18(%rsp),%xmm1
  movsd  0x58(%rsp),%xmm0
  mov    %ebp,%edi
  movsd  %xmm1,0x50(%rsp)
  movsd  %xmm0,0x18(%rsp)
  call   <make_hdl@plt>
  movsd  0x18(%rsp),%xmm0
  cvttsd2si %xmm0,%edi
  call   <binary_ks>
  movsd  0x50(%rsp),%xmm1
  cvttsd2si %xmm1,%ebp
  cmp    $0x1,%ebp
  jg     L55
L347:
  cvttsd2si 0x10(%rsp),%ebp
  cmp    $0x1,%ebp
  jg     L103
L93:
  cvttsd2si 0x48(%rsp),%ebp
  cmp    $0x1,%ebp
  jg     L167
L341:
  cvttsd2si 0x20(%rsp),%ebp
  cmp    $0x1,%ebp
  jg     L184
L49:
  cvttsd2si 0x8(%rsp),%ebp
  cmp    $0x1,%ebp
  jg     L187
L353:
  cvttsd2si 0x40(%rsp),%ebp
  cmp    $0x1,%ebp
  jg     L348
L333:
  cvttsd2si 0x38(%rsp),%ebp
  cmp    $0x1,%ebp
  jg     L192
L337:
  cvttsd2si 0x30(%rsp),%ebp
  cmp    $0x1,%ebp
  jg     L84
L207:
  cvttsd2si 0x28(%rsp),%ebp
  cmp    $0x1,%ebp
  jg     L64
  add    $0x68,%rsp
  pop    %rbx
  pop    %rbp
  ret
L358:
  ret
```

tool_calls: name: disassemble_data
arguments: label: D181
datatype: f64
name: disassemble_data
arguments: label: D176
datatype: byte[8]

tool: D181: 2

tool: {"D176": [0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x3f]}

assistant: ```c
void binary_ks(int n) {
  double l;
  double h;
  if (n < 2)
    return;
  l = pow(2.0, floor(log(n) / log(2.0)));
  if (l == n)
    l = l / 2;
  h = n - l;
  add_to_array(n);
  make_hdl(n, l, h);
  binary_ks(l);
  binary_ks(h);
}
```