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

```asm
<main>:
  endbr64
  push   %r15
  push   %r14
  xor    %r14d,%r14d
  push   %r13
  push   %r12
  lea    D63(%rip),%r12
  push   %rbp
  lea    D51(%rip),%rbp
  push   %rbx
  sub    $0x98,%rsp
  mov    0x8(%rsi),%rdi
  mov    0x10(%rsi),%r13
  lea    D96(%rip),%rsi
  mov    %fs:0x28,%rax
  mov    %rax,0x88(%rsp)
  xor    %eax,%eax
  lea    0x30(%rsp),%rbx
  call   <fopen@plt>
  lea    0x10(%rsp),%rdx
  mov    %rbx,%rcx
  mov    %rbp,%rsi
  mov    %rax,%r15
  mov    %rax,%rdi
  xor    %eax,%eax
  call   <fscanf@plt>
  mov    %r12,%rsi
  lea    0x20(%rsp),%rdx
  mov    %rbx,%rcx
  mov    %r15,%rdi
  xor    %eax,%eax
  call   <fscanf@plt>
  mov    %r12,%rsi
  lea    0x18(%rsp),%rdx
  mov    %rbx,%rcx
  mov    %r15,%rdi
  xor    %eax,%eax
  lea    0x28(%rsp),%r12
  call   <fscanf@plt>
  mov    %rbx,%rcx
  lea    0x14(%rsp),%rdx
  mov    %rbp,%rsi
  mov    %r15,%rdi
  xor    %eax,%eax
  call   <fscanf@plt>
  mov    0x14(%rsp),%ecx
  test   %ecx,%ecx
  jle    L62
  cs nopw 0x0(%rax,%rax,1)
L97:
  lea    (%r12,%r14,4),%rdx
  mov    %rbx,%rcx
  mov    %rbp,%rsi
  mov    %r15,%rdi
  xor    %eax,%eax
  add    $0x1,%r14
  call   <fscanf@plt>
  cmp    %r14d,0x14(%rsp)
  jg     L97
L62:
  mov    %r15,%rdi
  call   <fclose@plt>
  cmpl   $0x1,0x28(%rsp)
  jne    L66
  movsd  0x18(%rsp),%xmm2
  movsd  D76(%rip),%xmm1
  movsd  D23(%rip),%xmm0
  mulsd  %xmm2,%xmm1
  mulsd  %xmm2,%xmm0
  mulsd  0x20(%rsp),%xmm0
  mulsd  %xmm2,%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,(%rsp)
L66:
  cmpl   $0x1,0x2c(%rsp)
  jne    L23
  movsd  D25(%rip),%xmm0
  mulsd  0x20(%rsp),%xmm0
  movsd  0x18(%rsp),%xmm1
  mulsd  %xmm1,%xmm0
  mulsd  %xmm1,%xmm0
  subsd  D43(%rip),%xmm0
  movsd  %xmm0,0x8(%rsp)
L23:
  lea    D110(%rip),%rsi
  mov    %r13,%rdi
  call   <fopen@plt>
  mov    %rax,%rbp
  mov    0x14(%rsp),%eax
  test   %eax,%eax
  jle    L30
  mov    0x28(%rsp),%edx
  test   %edx,%edx
  jne    L57
L52:
  cmp    $0x1,%eax
  jle    L30
  cmpl   $0x0,0x2c(%rsp)
  jne    L92
L30:
  mov    %rbp,%rdi
  call   <fclose@plt>
  mov    0x88(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L108
  add    $0x98,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L57:
  movsd  (%rsp),%xmm0
  lea    D100(%rip),%rdx
  lea    D89(%rip),%rsi
  mov    %rbp,%rdi
  call   <fprintf@plt>
  mov    0x14(%rsp),%eax
  jmp    L52
L92:
  movsd  0x8(%rsp),%xmm0
  lea    D103(%rip),%rdx
  lea    D89(%rip),%rsi
  mov    %rbp,%rdi
  call   <fprintf@plt>
  jmp    L30
L108:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: parse_data
arguments: label: D63
data_type: string
name: parse_data
arguments: label: D51
data_type: string
name: parse_data
arguments: label: D96
data_type: string
name: parse_data
arguments: label: D76
data_type: byte[8]
name: parse_data
arguments: label: D23
data_type: byte[8]
name: parse_data
arguments: label: D25
data_type: byte[8]
name: parse_data
arguments: label: D43
data_type: f64
name: parse_data
arguments: label: D110
data_type: string
name: parse_data
arguments: label: D100
data_type: string
name: parse_data
arguments: label: D89
data_type: string
name: parse_data
arguments: label: D103
data_type: string

tool: D63: %lf %80s

tool: D51: %d %80s

tool: D96: r

tool: {"D76": [0x87,0xb2,0xcd,0xf7,0x7b,0x2f,0x00,0x40]}

tool: {"D23": [0x83,0x9f,0x65,0x4d,0x57,0x23,0x0a,0x40]}

tool: {"D25": [0x11,0x2d,0x44,0x54,0xfb,0x21,0xe9,0x3f]}

tool: D43: 63.525

tool: D110: w

tool: D100: area


tool: D89: %23.15e %s

tool: D103: volume_constraint


assistant: ```c
int main(int argc, char **argv) {
  FILE *fileptr;
  double fval[2], D, H;
  int i, num_vars, num_fns, req[2];
  char *infile, *outfile, in_str[81];
  char *valtag[] = {"area\n", "volume_constraint\n"};
  const double PI = 3.14159265358979;
  infile = argv[1];
  outfile = argv[2];
  fileptr = fopen(infile, "r");
  fscanf(fileptr, "%d %80s", &num_vars, in_str);
  fscanf(fileptr, "%lf %80s", &H, in_str);
  fscanf(fileptr, "%lf %80s", &D, in_str);
  fscanf(fileptr, "%d %80s", &num_fns, in_str);
  for (i = 0; i < num_fns; i++)
    fscanf(fileptr, "%d %80s", &req[i], in_str);
  fclose(fileptr);
  if (req[0] == 1)
    fval[0] = 0.644 * PI * D * D + 1.04 * PI * D * H;
  if (req[1] == 1)
    fval[1] = 0.25 * PI * H * D * D - 63.525;
  fileptr = fopen(outfile, "w");
  for (i = 0; i < num_fns; i++)
    if (req[i])
      fprintf(fileptr, "%23.15e %s", fval[i], valtag[i]);
  fclose(fileptr);
  return 0;
}
```