user: Please show me the C implementation that matches the assembly code listed below:

```asm
<PeriLargeCalcSide>:
  endbr64
  sub    $0x68,%rsp
  mov    %edi,%eax
  mov    %edx,%r11d
  mov    D67(%rip),%rdi
  mov    %ecx,%edx
  movsd  D76(%rip),%xmm2
  movsd  D59(%rip),%xmm0
  mov    %fs:0x28,%rcx
  mov    %rcx,0x58(%rsp)
  xor    %ecx,%ecx
  cmp    %eax,%r11d
  mov    %rdi,0x48(%rsp)
  setl   %dil
  cmp    %r9d,%eax
  movsd  %xmm0,0x10(%rsp)
  setle  %cl
  cmp    %edx,%eax
  movsd  %xmm0,0x18(%rsp)
  setl   %r10b
  movsd  %xmm2,0x20(%rsp)
  movsd  %xmm2,0x28(%rsp)
  movsd  %xmm0,0x30(%rsp)
  movsd  %xmm2,0x38(%rsp)
  movsd  %xmm2,0x40(%rsp)
  test   %cl,%r10b
  je     L134
  test   %dil,%dil
  je     L134
  movsd  D39(%rip),%xmm1
  cmp    %esi,%eax
  jge    L73
  pxor   %xmm2,%xmm2
L145:
  cmp    %r8d,%eax
  jg     L116
  subsd  D69(%rip),%xmm1
L116:
  cmp    %edx,%eax
  setle  %dl
  cmp    %r8d,%eax
  setle  %al
  movzbl %dl,%edx
  movzbl %al,%eax
  add    %eax,%eax
  lea    (%rax,%rdx,4),%eax
  add    %rcx,%rax
  and    $0x1f,%eax
  movsd  0x10(%rsp,%rax,8),%xmm0
  ucomisd %xmm0,%xmm2
  ja     L72
  sqrtsd %xmm0,%xmm0
L80:
  addsd  %xmm1,%xmm0
  nopl   0x0(%rax,%rax,1)
L237:
  mov    0x58(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L1
  add    $0x68,%rsp
  ret
L189:
  je     L140
  pxor   %xmm1,%xmm1
L73:
  cmp    %esi,%eax
  jle    L279
  cmp    %r9d,%edx
  cmovle %edx,%r9d
  cmp    %r9d,%eax
  jg     L13
  addsd  D12(%rip),%xmm1
  movapd %xmm1,%xmm0
  jmp    L237
  nopl   0x0(%rax)
L134:
  cmp    %esi,%eax
  jl     L278
L201:
  cmp    %eax,%r11d
  jle    L189
  cmp    %edx,%eax
  jle    L251
  movsd  D56(%rip),%xmm0
  cmp    %r9d,%eax
  jge    L251
L117:
  cmp    %esi,%edx
  mov    %esi,%ecx
  cmovge %edx,%ecx
  cmp    %ecx,%eax
  jge    L4
  cmp    %r8d,%r9d
  mov    %r8d,%ecx
  cmovge %r9d,%ecx
  cmp    %ecx,%eax
  jge    L4
  cmp    %esi,%r9d
  cmovl  %esi,%r9d
  cmp    %r9d,%eax
  jge    L4
  cmp    %r8d,%edx
  cmovge %edx,%r8d
  cmp    %r8d,%eax
  jl     L237
  nopl   0x0(%rax,%rax,1)
L4:
  subsd  %xmm2,%xmm0
  jmp    L237
  nopl   0x0(%rax)
L251:
  cmp    %r8d,%esi
  mov    %r8d,%ecx
  pxor   %xmm0,%xmm0
  cmovle %esi,%ecx
  cmp    %eax,%ecx
  jle    L117
  cmp    %r9d,%edx
  mov    %r9d,%ecx
  movsd  D72(%rip),%xmm0
  cmovle %edx,%ecx
  cmp    %ecx,%eax
  jl     L117
  movsd  D61(%rip),%xmm0
  jmp    L117
  nopl   0x0(%rax,%rax,1)
L13:
  addsd  %xmm2,%xmm1
  movapd %xmm1,%xmm0
  jmp    L237
  nopl   (%rax)
L278:
  test   %dil,%dil
  je     L201
  pxor   %xmm2,%xmm2
  movapd %xmm2,%xmm1
  jmp    L145
L1:
  call   <__stack_chk_fail@plt>
L72:
  movsd  %xmm1,0x8(%rsp)
  call   <sqrt@plt>
  movsd  0x8(%rsp),%xmm1
  jmp    L80
L140:
  pxor   %xmm0,%xmm0
  jmp    L237
L279:
  pxor   %xmm2,%xmm2
  jmp    L116
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D67
type_infered: f64
name: extract_symbolic_data
arguments: data_tag: D76
type_infered: f64
name: extract_symbolic_data
arguments: data_tag: D59
type_infered: f64
name: extract_symbolic_data
arguments: data_tag: D39
type_infered: byte[8]
name: extract_symbolic_data
arguments: data_tag: D69
type_infered: byte[8]
name: extract_symbolic_data
arguments: data_tag: D12
type_infered: byte[8]
name: extract_symbolic_data
arguments: data_tag: D56
type_infered: byte[8]
name: extract_symbolic_data
arguments: data_tag: D72
type_infered: byte[8]
name: extract_symbolic_data
arguments: data_tag: D61
type_infered: byte[8]

tool: D67: 2.7017787186

tool: D76: 2

tool: D59: 4

tool: {"D39": [0x66,0x88,0x01,0x33,0xc3,0xbe,0xe2,0xbf]}

tool: {"D69": [0x66,0x88,0x01,0x33,0xc3,0xbe,0xe2,0x3f]}

tool: {"D12": [0xcd,0x3b,0x7f,0x66,0x9e,0xa0,0xf6,0x3f]}

tool: {"D56": [0x66,0x88,0x01,0x33,0xc3,0xbe,0xf2,0xbf]}

tool: {"D72": [0x06,0x5b,0x61,0xa1,0xa1,0x4c,0xfa,0xbf]}

tool: {"D61": [0xcd,0x3b,0x7f,0x66,0x9e,0xa0,0x06,0xc0]}

assistant: ```c
double PeriLargeCalcSide(int h, int a, int b, int c, int d, int e) {
  double addarray[8] = {4.0, 4.0, 2.0, 2.0, 4.0, 2.0, 2.0, 2.7017787186};
  double l = 0.0;
  if ((b < h) && (c > h) && (e >= h))
    l += sqrt(2.0) - 2.0;
  if ((b < h) && (a > h) && (d >= h))
    l += sqrt(2.0) - 2.0;
  if (b > h) {
    if ((c < h) && (e > h))
      l += sqrt(8.0) - 4.0;
    else if ((a > h) && (d > h)) {
      if ((c > h) && (e > h))
        l -= sqrt(20.0) - sqrt(8.0);
      else
        l -= sqrt(8.0);
    }
    if ((a <= h) && (c <= h))
      l -= 2.0;
    else if ((d <= h) && (e <= h))
      l -= 2.0;
    else if ((a <= h) && (e <= h))
      l -= 2.0;
    else if ((c <= h) && (d <= h))
      l -= 2.0;
  }
  if (b >= h)
    return (l);
  else {
    if (a < h) {
      if ((c >= h) && (e >= h))
        return (l + sqrt(2.0));
      return (l + 2.0);
    } else
      return (l + sqrt(addarray[(((c) >= (h) ? 1 : 0) << 2) + (((d) >= (h) ? 1 : 0) << 1) + ((e) >= (h) ? 1 : 0)]));
  }
}
```