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

```asm
<generate_tune1>:
  endbr64
  push   %r12
  lea    D46(%rip),%rdi
  mov    $0x2f6,%r12d
  push   %rbp
  lea    D81(%rip),%rbp
  push   %rbx
  mov    $0x88888889,%ebx
  call   <puts@plt>
  movsd  D126(%rip),%xmm1
  xchg   %ax,%ax
L3:
  lea    (%r12,%r12,1),%eax
  pxor   %xmm0,%xmm0
  pxor   %xmm2,%xmm2
  mov    %r12d,%ecx
  cvtsi2sd %eax,%xmm0
  divsd  D51(%rip),%xmm0
  lea    0xe(%r12),%edx
  mov    %rbp,%rdi
  mulsd  D64(%rip),%xmm0
  imul   %rbx,%rcx
  imul   %rbx,%rdx
  shr    $0x23,%rcx
  mov    %ecx,%esi
  shr    $0x23,%rdx
  addsd  %xmm1,%xmm0
  shl    $0x4,%esi
  sub    $0x30,%edx
  sub    %ecx,%esi
  mov    %r12d,%ecx
  shl    $0x4,%edx
  sub    %esi,%ecx
  mov    %r12d,%esi
  cvttsd2si %xmm0,%eax
  pxor   %xmm0,%xmm0
  or     %ecx,%edx
  cvtsi2sd %r12d,%xmm0
  mulsd  D102(%rip),%xmm0
  add    $0x1,%r12d
  divsd  D99(%rip),%xmm0
  cvtsi2sd %eax,%xmm2
  shl    $0x9,%eax
  and    $0x7e00,%eax
  or     %eax,%edx
  xor    %eax,%eax
  divsd  %xmm2,%xmm0
  mulsd  %xmm1,%xmm0
  mulsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  mulsd  D85(%rip),%xmm0
  mulsd  D52(%rip),%xmm0
  divsd  D104(%rip),%xmm0
  mulsd  D29(%rip),%xmm0
  cvttsd2si %xmm0,%r8d
  mov    %r8d,%ecx
  call   <printf@plt>
  mov    D126(%rip),%rax
  cmp    $0x43b,%r12d
  movq   %rax,%xmm1
  jne    L3
  pop    %rbx
  lea    D54(%rip),%rdi
  pop    %rbp
  pop    %r12
  jmp    1060 <puts@plt>
```

tool_calls: name: unpack_data
arguments: data_label: D46
data_type: string
name: unpack_data
arguments: data_label: D81
data_type: string
name: unpack_data
arguments: data_label: D126
data_type: f64
name: unpack_data
arguments: data_label: D51
data_type: f64
name: unpack_data
arguments: data_label: D64
data_type: byte[8]
name: unpack_data
arguments: data_label: D102
data_type: f64
name: unpack_data
arguments: data_label: D99
data_type: f64
name: unpack_data
arguments: data_label: D85
data_type: f64
name: unpack_data
arguments: data_label: D52
data_type: f64
name: unpack_data
arguments: data_label: D104
data_type: f64
name: unpack_data
arguments: data_label: D29
data_type: byte[8]
name: unpack_data
arguments: data_label: D54
data_type: string

tool: D46: const struct stfm1000_tune1
stfm1000_tune1_table[STFM1000_FREQUENCY_100KHZ_RANGE] = {

tool: D81: 	[%d - STFM1000_FREQUENCY_100KHZ_MIN] = { .tune1 = 0x%08x, .sdnom = 0x%08x },


tool: D126: 0.5

tool: D51: 3

tool: {"D64": [0x00,0x00,0x00,0x00,0x00,0x00,0xb0,0x3f]}

tool: D102: 100000

tool: D99: 1.5

tool: D85: 8

tool: D52: 256

tool: D104: 228000

tool: {"D29": [0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x40]}

tool: D54: };

assistant: ```c
void generate_tune1(void) {
  int start, end;
  int ndiv;
  int incr;
  int cicosr;
  int sdnominal;
  int i, temp;
  start = 758;
  end = start + 325;
  printf("const struct stfm1000_tune1\n"
         "stfm1000_tune1_table[STFM1000_FREQUENCY_100KHZ_RANGE] = {\n");
  for (i = start; i < end; i++) {
    ndiv = (int)((i + 14) / 15) - 48;
    incr = i - (int)(i / 15) * 15;
    cicosr = (int)(i * 2 / 3.0 / 16.0 + 0.5);
    sdnominal = (int)(i * 100.0e3 / 1.5 / (double)cicosr / 2.0 / 2.0 * 2.0 * 8.0 * 256.0 / 228.0e3 * 65536);
    temp = 0x00000000;
    temp = temp | ((cicosr << 9) & 0x00007E00);
    temp = temp | ((ndiv << 4) & 0x000001FF);
    temp = temp | ((incr)&0x000001FF);
    printf("\t[%d - STFM1000_FREQUENCY_100KHZ_MIN] = "
           "{ .tune1 = 0x%08x, .sdnom = 0x%08x },\n",
           i, temp, sdnominal);
  }
  printf("};\n");
}
```