user: 请从给定的汇编指令推导出C源代码：

```asm
<random_walk>:
  endbr64
  push   %r14
  push   %r13
  mov    %rsi,%r13
  push   %r12
  push   %rbp
  push   %rbx
  test   %edi,%edi
  jle    L98
  mov    %edi,%r12d
  xor    %r14d,%r14d
  xor    %ebp,%ebp
  xor    %ebx,%ebx
  jmp    L115
  nop
L15:
  add    $0x1,%ebx
L44:
  add    $0x1,%r14d
  cmp    %r14d,%r12d
  je     L57
L115:
  xor    %eax,%eax
  call   <get_rn@plt>
  comisd D47(%rip),%xmm0
  ja     L15
  comisd D61(%rip),%xmm0
  jbe    L28
  add    $0x1,%r14d
  sub    $0x1,%ebx
  cmp    %r14d,%r12d
  jne    L115
L57:
  mov    %ebx,%eax
  or     %ebp,%eax
  jne    L54
L98:
  movupd 0x10(%r13),%xmm0
  movupd 0x0(%r13),%xmm2
  movapd D27(%rip),%xmm1
  pop    %rbx
  pop    %rbp
  pop    %r12
  addpd  %xmm1,%xmm0
  addpd  %xmm2,%xmm1
  movups %xmm0,0x10(%r13)
  movups %xmm1,0x0(%r13)
  pop    %r13
  pop    %r14
  ret
  nopl   0x0(%rax,%rax,1)
L28:
  lea    -0x1(%rbp),%eax
  add    $0x1,%ebp
  comisd D27(%rip),%xmm0
  cmovbe %eax,%ebp
  jmp    L44
  nopl   0x0(%rax,%rax,1)
L54:
  test   %ebx,%ebx
  je     L112
  mov    %ebx,%eax
  not    %eax
  shr    $0x1f,%eax
  test   %ebp,%ebp
  jne    L4
  movzbl %al,%eax
  movsd  D61(%rip),%xmm0
  movslq %ebx,%rbx
  shl    $0x4,%rax
  sar    $0x3f,%rbx
  add    %r13,%rax
  and    $0xfffffffffffffff0,%rbx
  movsd  (%rax),%xmm1
  addsd  %xmm0,%xmm1
  movsd  %xmm1,(%rax)
  lea    0x18(%r13,%rbx,1),%rax
  addsd  (%rax),%xmm0
  movsd  %xmm0,(%rax)
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  nopw   0x0(%rax,%rax,1)
L112:
  test   %ebp,%ebp
  js     L90
  movsd  0x8(%r13),%xmm1
  movsd  D61(%rip),%xmm0
  mov    $0x18,%eax
  addsd  %xmm0,%xmm1
  movsd  %xmm1,0x8(%r13)
L81:
  add    %r13,%rax
  addsd  (%rax),%xmm0
  movsd  %xmm0,(%rax)
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  nopl   (%rax)
L4:
  not    %ebp
  movsd  D54(%rip),%xmm0
  shr    $0x1f,%ebp
  lea    0x0(%rbp,%rax,2),%eax
  cltq
  lea    0x0(%r13,%rax,8),%rax
  addsd  (%rax),%xmm0
  movsd  %xmm0,(%rax)
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  nopl   0x0(%rax)
L90:
  movsd  0x0(%r13),%xmm1
  movsd  D61(%rip),%xmm0
  mov    $0x10,%eax
  addsd  %xmm0,%xmm1
  movsd  %xmm1,0x0(%r13)
  jmp    L81
```

tool_calls: name: extract_symbolic_data
arguments: tag: D47
data_type: f64[2]
name: extract_symbolic_data
arguments: tag: D61
data_type: f64[2]
name: extract_symbolic_data
arguments: tag: D27
data_type: f64[2]
name: extract_symbolic_data
arguments: tag: D54
data_type: f64

tool: {"D47": [0.75,0.5]}

tool: {"D61": [0.5,1.0]}

tool: {"D27": [0.25,0.25]}

tool: D54: 1

assistant: ```c
void random_walk(int walk_length, double *quadrant) {
  int x, y, i, j;
  double rn;
  x = y = 0;
  for (i = 0; i < walk_length; i++) {
    rn = get_rn();
    if (rn > 0.75)
      x++;
    else if (rn > 0.5)
      x--;
    else if (rn > 0.25)
      y++;
    else
      y--;
  }
  if (x == 0 && y == 0) {
    quadrant[0] += 0.25;
    quadrant[1] += 0.25;
    quadrant[2] += 0.25;
    quadrant[3] += 0.25;
  } else if (x == 0) {
    quadrant[((y < 0) ? 0 : 1)] += 0.5;
    quadrant[2 + ((y < 0) ? 0 : 1)] += 0.5;
  } else if (y == 0) {
    quadrant[2 * ((x < 0) ? 0 : 1)] += 0.5;
    quadrant[2 * ((x < 0) ? 0 : 1) + 1] += 0.5;
  } else
    quadrant[2 * ((x < 0) ? 0 : 1) + ((y < 0) ? 0 : 1)] += 1.0;
}
```