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

```asm
<gen_ucsb_stf>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x38,%rsp
  mov    %rdi,0x28(%rsp)
  mov    %rsi,%r13
  mov    %rdx,%rbx
  mov    %ecx,%ebp
  mov    %r8,%r12
  mov    %ecx,%esi
  mov    %rdx,%rdi
  call   <zapit@plt>
  movss  0x0(%r13),%xmm6
  movss  %xmm6,0x20(%rsp)
  movaps %xmm6,%xmm0
  divss  (%r12),%xmm0
  cvtss2sd %xmm0,%xmm0
  addsd  D100(%rip),%xmm0
  cvttsd2si %xmm0,%r13d
  cmp    %ebp,%r13d
  cmovg  %ebp,%r13d
  test   %r13d,%r13d
  jle    L19
  pxor   %xmm0,%xmm0
  cvtss2sd %xmm6,%xmm0
  mulsd  D30(%rip),%xmm0
  pxor   %xmm4,%xmm4
  cvtsd2ss %xmm0,%xmm4
  movss  %xmm4,0xc(%rsp)
  movaps %xmm6,%xmm7
  subss  %xmm4,%xmm7
  movss  %xmm7,0x24(%rsp)
  addss  %xmm4,%xmm4
  movss  %xmm4,0x18(%rsp)
  lea    -0x1(%r13),%r15d
  mov    %r13d,%r14d
  mov    $0x0,%ebp
  jmp    L8
L73:
  mulss  D106(%rip),%xmm0
  divss  %xmm3,%xmm0
  movss  %xmm0,0x1c(%rsp)
  call   <cos@plt>
  movsd  %xmm0,0x10(%rsp)
  movss  0x1c(%rsp),%xmm0
  mulss  D78(%rip),%xmm0
  call   <sin@plt>
  movapd %xmm0,%xmm1
  movsd  D39(%rip),%xmm0
  movsd  0x10(%rsp),%xmm2
  mulsd  %xmm0,%xmm2
  subsd  %xmm2,%xmm0
  mulsd  D40(%rip),%xmm1
  addsd  %xmm1,%xmm0
  cvtsd2ss %xmm0,%xmm0
L125:
  movss  %xmm0,(%rbx,%rbp,4)
  add    $0x1,%rbp
  cmp    %r14,%rbp
  je     L104
L8:
  pxor   %xmm0,%xmm0
  cvtsi2ss %ebp,%xmm0
  mulss  (%r12),%xmm0
  movss  0xc(%rsp),%xmm3
  comiss %xmm0,%xmm3
  ja     L73
  movss  0x18(%rsp),%xmm4
  comiss %xmm0,%xmm4
  ja     L117
  movss  0x20(%rsp),%xmm5
  comiss %xmm0,%xmm5
  ja     L88
  pxor   %xmm0,%xmm0
  jmp    L125
L117:
  movaps %xmm0,%xmm1
  movss  0xc(%rsp),%xmm7
  subss  %xmm7,%xmm1
  mulss  D106(%rip),%xmm1
  divss  0x24(%rsp),%xmm1
  movss  %xmm1,0x1c(%rsp)
  mulss  D106(%rip),%xmm0
  divss  %xmm7,%xmm0
  call   <cos@plt>
  movsd  %xmm0,0x10(%rsp)
  movss  0x1c(%rsp),%xmm0
  call   <cos@plt>
  movsd  0x10(%rsp),%xmm2
  mulsd  D39(%rip),%xmm2
  movsd  D135(%rip),%xmm1
  subsd  %xmm2,%xmm1
  mulsd  D97(%rip),%xmm0
  addsd  %xmm0,%xmm1
  pxor   %xmm0,%xmm0
  cvtsd2ss %xmm1,%xmm0
  jmp    L125
L88:
  subss  0xc(%rsp),%xmm0
  mulss  D106(%rip),%xmm0
  divss  0x24(%rsp),%xmm0
  call   <cos@plt>
  mulsd  D97(%rip),%xmm0
  addsd  D97(%rip),%xmm0
  cvtsd2ss %xmm0,%xmm0
  jmp    L125
L104:
  movss  (%r12),%xmm2
  mov    %rbx,%rax
  lea    0x4(%rbx,%r15,4),%rdx
  pxor   %xmm0,%xmm0
L35:
  movaps %xmm2,%xmm1
  mulss  (%rbx),%xmm1
  addss  %xmm1,%xmm0
  add    $0x4,%rbx
  cmp    %rdx,%rbx
  jne    L35
  pxor   %xmm1,%xmm1
  comiss %xmm0,%xmm1
  jae    L12
  mov    0x28(%rsp),%rcx
  movss  (%rcx),%xmm1
  divss  %xmm0,%xmm1
L80:
  movaps %xmm1,%xmm0
  mulss  (%rax),%xmm0
  movss  %xmm0,(%rax)
  add    $0x4,%rax
  cmp    %rdx,%rax
  jne    L80
L97:
  mov    %r13d,%eax
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L19:
  mov    $0x0,%r13d
  jmp    L97
L12:
  mov    $0x0,%r13d
  jmp    L97
```

tool_calls: name: parse_data
arguments: data_label: D100
type_infered: f64
name: parse_data
arguments: data_label: D30
type_infered: f64
name: parse_data
arguments: data_label: D106
type_infered: f32
name: parse_data
arguments: data_label: D78
type_infered: byte[4]
name: parse_data
arguments: data_label: D39
type_infered: f64
name: parse_data
arguments: data_label: D40
type_infered: f64
name: parse_data
arguments: data_label: D135
type_infered: f64
name: parse_data
arguments: data_label: D97
type_infered: f64

tool: D100: 0.5

tool: D30: 0.13

tool: D106: 3.141592654

tool: {"D78": [0x00,0x00,0x00,0x3f]}

tool: D39: 0.7

tool: D40: 0.6

tool: D135: 1

tool: D97: 0.3

assistant: ```c
int gen_ucsb_stf(float *slip, float *t0, float *stf, int nt, float *dt, float *z0) {
  int it, nstf;
  float tau, tau1, tau2, tau1x2, arg1, arg2;
  float sum, t, alpha;
  float pi = 3.141592654;
  zapit(stf, nt);
  tau = (*t0);
  tau1 = 0.13 * tau;
  tau2 = tau - tau1;
  tau1x2 = 2.0 * tau1;
  nstf = (int)((tau) / (*dt) + 0.5);
  if (nstf > nt)
    nstf = nt;
  if (nstf == 0)
    return (0);
  for (it = 0; it < nstf; it++) {
    t = it * (*dt);
    alpha = 0.0;
    if (t < tau1) {
      arg1 = pi * t / tau1;
      arg2 = 0.5 * arg1;
      alpha = 0.7 - 0.7 * cos(arg1) + 0.6 * sin(arg2);
    } else if (t < tau1x2) {
      arg1 = pi * t / tau1;
      arg2 = pi * (t - tau1) / tau2;
      alpha = 1.0 - 0.7 * cos(arg1) + 0.3 * cos(arg2);
    } else if (t < tau) {
      arg1 = pi * (t - tau1) / tau2;
      alpha = 0.3 + 0.3 * cos(arg1);
    }
    stf[it] = alpha;
  }
  sum = 0.0;
  for (it = 0; it < nstf; it++)
    sum = sum + (*dt) * stf[it];
  if (sum <= 0.0)
    return (0);
  sum = (*slip) / sum;
  for (it = 0; it < nstf; it++)
    stf[it] = stf[it] * sum;
  return (nstf);
}
```