user: Converte this assembly snippet into its equivalent C code:

```asm
<randf>:
  endbr64
  movslq D144(%rip),%rdx
  movslq D70(%rip),%rsi
  push   %rbx
  mov    %edx,%ebx
  or     %esi,%ebx
  je     L2
  mov    D105(%rip),%ebx
  movss  D87(%rip),%xmm1
  lea    0x1(%rbx),%eax
  movslq %eax,%r8
  mov    %eax,%ecx
  imul   $0x94f2095,%r8,%r8
  sar    $0x1f,%ecx
  sar    $0x21,%r8
  sub    %ecx,%r8d
  imul   $0x37,%r8d,%ecx
  sub    %ecx,%eax
  mov    %eax,%r8d
  lea    0x1(%rdx),%eax
  movslq %eax,%rdi
  mov    %eax,%ecx
  imul   $0x94f2095,%rdi,%rdi
  sar    $0x1f,%ecx
  sar    $0x21,%rdi
  sub    %ecx,%edi
  imul   $0x37,%edi,%ecx
  sub    %ecx,%eax
  lea    0x1(%rsi),%ecx
  mov    %eax,%edi
  movslq %ecx,%rax
  mov    %ecx,%r9d
  imul   $0x94f2095,%rax,%rax
  sar    $0x1f,%r9d
  sar    $0x21,%rax
  sub    %r9d,%eax
  imul   $0x37,%eax,%r9d
  mov    %ecx,%eax
  lea    D40(%rip),%rcx
  sub    %r9d,%eax
L4:
  movss  (%rcx,%rsi,4),%xmm0
  addss  (%rcx,%rdx,4),%xmm0
  pxor   %xmm2,%xmm2
  comiss %xmm1,%xmm0
  cvtss2sd %xmm0,%xmm2
  jbe    L29
  subsd  D123(%rip),%xmm2
  pxor   %xmm0,%xmm0
  movsd  %xmm2,D49(%rip)
  cvtsd2ss %xmm2,%xmm0
L20:
  movslq %ebx,%rbx
  mov    %r8d,D143(%rip)
  movss  %xmm0,(%rcx,%rbx,4)
  pop    %rbx
  mov    %edi,D143(%rip)
  mov    %eax,D143(%rip)
  ret
  nopl   0x0(%rax,%rax,1)
L29:
  movsd  %xmm2,D143(%rip)
  jmp    L20
  nopw   0x0(%rax,%rax,1)
L2:
  lea    D143(%rip),%rdi
  xor    %eax,%eax
  call   <get_i_variable@plt>
  lea    D40(%rip),%rcx
  pxor   %xmm2,%xmm2
  movss  D46(%rip),%xmm3
  movss  D87(%rip),%xmm1
  mov    %rcx,%rsi
  lea    0xdc(%rcx),%r8
  nopl   0x0(%rax,%rax,1)
L55:
  imul   $0x92d,%eax,%eax
  pxor   %xmm0,%xmm0
  lea    0x3a13(%rax),%edx
  movslq %edx,%rax
  mov    %edx,%edi
  imul   $0xffffffff80010003,%rax,%rax
  sar    $0x1f,%edi
  shr    $0x20,%rax
  add    %edx,%eax
  sar    $0xe,%eax
  sub    %edi,%eax
  mov    %eax,%edi
  shl    $0xf,%edi
  sub    %eax,%edi
  mov    %edx,%eax
  sub    %edi,%eax
  cvtsi2ss %eax,%xmm0
  divss  %xmm3,%xmm0
  comiss %xmm1,%xmm0
  jbe    L25
  subss  %xmm1,%xmm0
L25:
  comiss %xmm0,%xmm2
  movss  %xmm0,(%rsi)
  jbe    L34
  addss  %xmm1,%xmm0
  movss  %xmm0,(%rsi)
L34:
  add    $0x4,%rsi
  cmp    %r8,%rsi
  jne    L55
  mov    $0x20,%eax
  mov    $0x19,%edi
  mov    $0x1,%r8d
  mov    $0x18,%edx
  mov    $0x1f,%esi
  jmp    L4
```

tool_calls: name: parse_data
arguments: data_tag: D87
type: f32
name: parse_data
arguments: data_tag: D123
type: f32[2]
name: parse_data
arguments: data_tag: D143
type: string
name: parse_data
arguments: data_tag: D46
type: f32

tool: D87: 1

tool: {"D123": [0.0,1.875]}

tool: D143: seed

tool: D46: 32767

assistant: ```c
float randf() {
  static float buff[55];
  static int ip = 0, jp = 0, kp;
  int i, seed, get_i_variable();
  static double xva;
  if (ip == 0 && jp == 0) {
    seed = get_i_variable("seed");
    for (ip = 0; ip < 55; ip++) {
      seed = (seed * 2349 + 14867) % 32767;
      buff[ip] = (float)seed / 32767.;
      if (buff[ip] > 1.)
        buff[ip] = buff[ip] - 1.;
      if (buff[ip] < 0.)
        buff[ip] = buff[ip] + 1.;
    }
    ip = 24;
    jp = 55 - ip;
    kp = 0;
  }
  i = kp;
  xva = buff[jp] + buff[ip];
  if (xva > 1.)
    xva = xva - 1.;
  buff[kp] = xva;
  kp = (kp + 1) % 55;
  ip = (ip + 1) % 55;
  jp = (jp + 1) % 55;
  return buff[i];
}
```