user: What would the C source look like for the assembly code provided here?

```asm
<set_ts_record>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  mov    %rdx,-0x28(%rbp)
  mov    %rcx,-0x30(%rbp)
  mov    %r8d,-0x34(%rbp)
  movl   $0x0,-0x4(%rbp)
  jmp    L74
L32:
  mov    -0x4(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L74:
  cmpl   $0x6,-0x4(%rbp)
  jle    L32
  movl   $0x0,-0x4(%rbp)
  jmp    L27
L71:
  mov    -0x4(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x4(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x28(%rbp),%rax
  add    %rcx,%rax
  mov    (%rax),%rax
  cmp    %rax,%rdx
  jb     L29
  mov    -0x4(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rax
  mov    -0x4(%rbp),%edx
  movslq %edx,%rdx
  lea    0x0(,%rdx,8),%rcx
  mov    -0x28(%rbp),%rdx
  add    %rcx,%rdx
  mov    (%rdx),%rdx
  sub    %rdx,%rax
  test   %rax,%rax
  js     L50
  pxor   %xmm0,%xmm0
  cvtsi2sd %rax,%xmm0
  jmp    L101
L50:
  mov    %rax,%rdx
  shr    %rdx
  and    $0x1,%eax
  or     %rax,%rdx
  pxor   %xmm0,%xmm0
  cvtsi2sd %rdx,%xmm0
  addsd  %xmm0,%xmm0
L101:
  pxor   %xmm1,%xmm1
  cvtsi2sdl -0x34(%rbp),%xmm1
  mov    -0x4(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  divsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
L29:
  addl   $0x1,-0x4(%rbp)
L27:
  cmpl   $0x4,-0x4(%rbp)
  jle    L71
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0x28(%rbp),%rax
  mov    (%rax),%rax
  cmp    %rax,%rdx
  jb     L59
  mov    -0x30(%rbp),%rax
  add    $0x8,%rax
  mov    (%rax),%rdx
  mov    -0x28(%rbp),%rax
  add    $0x8,%rax
  mov    (%rax),%rax
  cmp    %rax,%rdx
  jbe    L59
  mov    -0x20(%rbp),%rax
  movsd  (%rax),%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x8,%rax
  movsd  (%rax),%xmm1
  mov    -0x20(%rbp),%rax
  add    $0x30,%rax
  divsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
L59:
  mov    -0x30(%rbp),%rax
  add    $0x20,%rax
  mov    (%rax),%rdx
  mov    -0x28(%rbp),%rax
  add    $0x20,%rax
  mov    (%rax),%rax
  cmp    %rax,%rdx
  jb     L9
  mov    -0x30(%rbp),%rax
  add    $0x18,%rax
  mov    (%rax),%rdx
  mov    -0x28(%rbp),%rax
  add    $0x8,%rax
  mov    (%rax),%rax
  cmp    %rax,%rdx
  jbe    L9
  mov    -0x20(%rbp),%rax
  add    $0x20,%rax
  movsd  (%rax),%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x18,%rax
  movsd  (%rax),%xmm1
  divsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x28,%rax
  movsd  D2(%rip),%xmm1
  divsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
L9:
  nop
  pop    %rbp
  ret
```

tool_calls: name: retrieve_data
arguments: data_label: D2
type: f64

tool: D2: 1000000

assistant: ```c
void set_ts_record(struct module *mod, double st_array[], unsigned long long pre_array[], unsigned long long cur_array[], int inter) {
  int i;
  for (i = 0; i < 7; ++i) {
    st_array[i] = 0;
  }
  for (i = 0; i < 5; ++i) {
    if (cur_array[i] >= pre_array[i]) {
      st_array[i] = (cur_array[i] - pre_array[i]) * 1.0 / inter;
    }
  }
  if (cur_array[0] >= pre_array[0] && cur_array[1] > pre_array[1]) {
    st_array[6] = st_array[0] / st_array[1];
  }
  if (cur_array[4] >= pre_array[4] && cur_array[3] > pre_array[1]) {
    st_array[5] = (st_array[4] / st_array[3]) / 1000000.0;
  }
}
```