user: Demonstrate the C code that generates the assembly output below:

```asm
<_change_freq>:
  endbr64
  push   %r15
  pxor   %xmm0,%xmm0
  movslq %esi,%rsi
  push   %r14
  cvtsi2sd %edx,%xmm0
  push   %r13
  push   %r12
  push   %rbp
  mov    $0x800,%ebp
  push   %rbx
  mov    %rdi,%rbx
  sub    $0x48,%rsp
  divsd  D11(%rip),%xmm0
  mov    %fs:0x28,%rax
  mov    %rax,0x38(%rsp)
  movabs $0x180000001000,%rax
  mulsd  D14(%rip),%xmm0
  lea    0x14(%rsp),%r15
  cvttsd2si %xmm0,%ecx
  mov    %rax,0x18(%rsp)
  movabs $0x8000000000,%rax
  mov    %rax,0x20(%rsp)
  movabs $0x18000000100,%rax
  mov    %rax,0x28(%rsp)
  lea    0x20(%rsp),%rax
  mov    0x20(%rsp,%rsi,4),%r13d
  mov    %rax,0x8(%rsp)
  mov    %ecx,%r14d
  movswl %cx,%r12d
  sar    $0x10,%r14d
L28:
  add    %r13d,%ebp
  mov    %r12d,%edx
  mov    %rbx,%rdi
  add    $0x4,%r15
  lea    0x62(%rbp),%esi
  call   <write16@plt>
  lea    0x64(%rbp),%esi
  mov    %r14d,%edx
  mov    %rbx,%rdi
  call   <write16@plt>
  cmp    %r15,0x8(%rsp)
  je     L10
  mov    (%r15),%ebp
  jmp    L28
  nopw   0x0(%rax,%rax,1)
L10:
  mov    $0x152,%edx
  mov    $0x210,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x310,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x350,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x390,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x3d0,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x410,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x450,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x490,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x4d0,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x510,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x550,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x590,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x152,%edx
  mov    $0x5d0,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  mov    $0x10000,%edx
  mov    $0x11c,%esi
  mov    %rbx,%rdi
  call   <write32@plt>
  orl    $0x40040,0x100(%rbx)
  mov    0x38(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L3
  add    $0x48,%rsp
  mov    $0x1,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L3:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: unpack_data
arguments: label: D11
type: byte[8]
name: unpack_data
arguments: label: D14
type: f64

tool: {"D11": [0x00,0x00,0x00,0x00,0x84,0xd7,0x97,0x41]}

tool: D14: 4294967296

assistant: ```c
int _change_freq(char *BASE, int channel, int freq) {
  int FREQ, i;
  double freq_frac;
  unsigned int GC314FS_GCoffset[3] = {0x800, 0x1000, 0x1800};
  unsigned int chan_control_map[4] = {0x00, 0x80, 0x100, 0x180};
  freq_frac = (double)freq / (double)100000000;
  FREQ = 4294967296.0 * freq_frac;
  for (i = 0; i < 3; i++) {
    write16(BASE, GC314FS_GCoffset[i] + chan_control_map[channel] + 0x62, (short)(FREQ & 0x0000ffff));
    write16(BASE, GC314FS_GCoffset[i] + chan_control_map[channel] + 0x64, (short)((FREQ >> 16) & 0x0000ffff));
  }
  write32(BASE, 0x210, 0x152);
  write32(BASE, 0x310, 0x152);
  write32(BASE, 0x350, 0x152);
  write32(BASE, 0x390, 0x152);
  write32(BASE, 0x3d0, 0x152);
  write32(BASE, 0x410, 0x152);
  write32(BASE, 0x450, 0x152);
  write32(BASE, 0x490, 0x152);
  write32(BASE, 0x4d0, 0x152);
  write32(BASE, 0x510, 0x152);
  write32(BASE, 0x550, 0x152);
  write32(BASE, 0x590, 0x152);
  write32(BASE, 0x5d0, 0x152);
  write32(BASE, 0x11c, 0x00010000);
  *((unsigned int *)(BASE + 0x100)) |= 0x00000040;
  *((unsigned int *)(BASE + 0x100)) |= 0x00040000;
  return 1;
}
```