user: 请将以下的汇编代码转换成C语言代码：

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x50,%rsp
  mov    %edi,-0x44(%rbp)
  mov    %rsi,-0x50(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movq   $0x0,-0x20(%rbp)
  movq   $0x0,-0x18(%rbp)
  movl   $0x0,-0x28(%rbp)
  movl   $0x0,-0x24(%rbp)
  movl   $0x0,-0x2c(%rbp)
  movq   $0x0,-0x10(%rbp)
  mov    -0x50(%rbp),%rax
  add    $0x8,%rax
  mov    (%rax),%rax
  test   %rax,%rax
  je     L113
  mov    -0x50(%rbp),%rax
  add    $0x8,%rax
  mov    (%rax),%rax
  mov    %rax,%rdi
  call   <atoi@plt>
  mov    %eax,-0x28(%rbp)
  mov    -0x50(%rbp),%rax
  add    $0x10,%rax
  mov    (%rax),%rax
  test   %rax,%rax
  je     L96
  jmp    L47
L113:
  lea    D38(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  mov    $0xffffffff,%eax
  jmp    L52
L47:
  mov    -0x50(%rbp),%rax
  add    $0x10,%rax
  mov    (%rax),%rax
  mov    %rax,%rdi
  call   <atoi@plt>
  mov    %eax,-0x24(%rbp)
  mov    -0x24(%rbp),%eax
  mov    $0x4,%esi
  mov    %eax,%edi
  call   <calloc@plt>
  mov    %rax,-0x18(%rbp)
  cmpq   $0x0,-0x18(%rbp)
  jne    L27
  jmp    L48
L96:
  lea    D10(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  mov    $0xffffffff,%eax
  jmp    L52
L48:
  lea    D65(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  mov    $0xffffffff,%eax
  jmp    L52
L27:
  movl   $0x0,-0x2c(%rbp)
  jmp    L99
L26:
  lea    D35(%rip),%rax
  mov    %rax,%rsi
  lea    D42(%rip),%rax
  mov    %rax,%rdi
  call   <fopen@plt>
  mov    %rax,-0x10(%rbp)
  lea    -0x34(%rbp),%rax
  mov    %rax,%rdi
  call   <timer_start@plt>
  mov    -0x10(%rbp),%rdx
  mov    -0x28(%rbp),%eax
  mov    %rdx,%rsi
  mov    %eax,%edi
  call   <do_task@plt>
  mov    -0x34(%rbp),%eax
  mov    %eax,%edi
  call   <timer_end@plt>
  mov    %rax,-0x20(%rbp)
  pxor   %xmm0,%xmm0
  cvtsi2ssq -0x20(%rbp),%xmm0
  mov    -0x2c(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movss  D60(%rip),%xmm1
  divss  %xmm1,%xmm0
  movss  %xmm0,(%rax)
  mov    -0x2c(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  pxor   %xmm2,%xmm2
  cvtss2sd %xmm0,%xmm2
  movq   %xmm2,%rax
  mov    -0x2c(%rbp),%edx
  add    $0x1,%edx
  movq   %rax,%xmm0
  mov    %edx,%esi
  lea    D47(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  addl   $0x1,-0x2c(%rbp)
L99:
  mov    -0x2c(%rbp),%eax
  cmp    -0x24(%rbp),%eax
  jl     L26
  movl   $0x0,-0x2c(%rbp)
  jmp    L84
L106:
  mov    -0x2c(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  movss  -0x30(%rbp),%xmm1
  addss  %xmm1,%xmm0
  movss  %xmm0,-0x30(%rbp)
  addl   $0x1,-0x2c(%rbp)
L84:
  mov    -0x2c(%rbp),%eax
  cmp    -0x24(%rbp),%eax
  jl     L106
  pxor   %xmm1,%xmm1
  cvtsi2ssl -0x24(%rbp),%xmm1
  movss  -0x30(%rbp),%xmm0
  divss  %xmm1,%xmm0
  movss  %xmm0,-0x30(%rbp)
  pxor   %xmm3,%xmm3
  cvtss2sd -0x30(%rbp),%xmm3
  movq   %xmm3,%rax
  movq   %rax,%xmm0
  lea    D41(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  mov    $0x0,%eax
L52:
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L67
  call   <__stack_chk_fail@plt>
L67:
  leave
  ret
```

tool_calls: name: extract_symbolic_data
arguments: label: D38
type_guessed: string
name: extract_symbolic_data
arguments: label: D10
type_guessed: string
name: extract_symbolic_data
arguments: label: D65
type_guessed: string
name: extract_symbolic_data
arguments: label: D35
type_guessed: string
name: extract_symbolic_data
arguments: label: D42
type_guessed: string
name: extract_symbolic_data
arguments: label: D60
type_guessed: byte[4]
name: extract_symbolic_data
arguments: label: D47
type_guessed: string
name: extract_symbolic_data
arguments: label: D41
type_guessed: string

tool: D38: lack of do count!

tool: D10: lack of repeat count!

tool: D65: No memory!

tool: D35: w

tool: D42: hr_test.txt

tool: {"D60": [0x00,0x24,0x74,0x49]}

tool: D47: (%d) Time taken in nano grade = %.3f ms


tool: D41: -> Average: %.3f ms


assistant: ```c
int main(int argc, char *argv[]) {
  struct timespec vartime;
  long timeElapsed = 0;
  float *result = NULL, total;
  int maxCnt = 0, repeatCnt = 0, doCnt = 0;
  FILE *record_fp = NULL;
  if (argv[1])
    maxCnt = atoi(argv[1]);
  else {
    printf("lack of do count!\n");
    return -1;
  }
  if (argv[2])
    repeatCnt = atoi(argv[2]);
  else {
    printf("lack of repeat count!\n");
    return -1;
  }
  if (!(result = (float *)calloc(repeatCnt, sizeof(float)))) {
    printf("No memory!\n");
    return -1;
  }
  for (doCnt = 0; doCnt < repeatCnt; doCnt++) {
    record_fp = fopen("hr_test"
                      ".txt",
                      "w");
    timer_start(&vartime);
    do_task(maxCnt, record_fp);
    timeElapsed = timer_end(vartime);
    result[doCnt] = (float)((float)timeElapsed / 1000000L);
    printf("(%d) Time taken in nano grade = %.3f ms\n", doCnt + 1, result[doCnt]);
  }
  for (doCnt = 0; doCnt < repeatCnt; doCnt++)
    total += result[doCnt];
  total /= repeatCnt;
  printf("-> Average: %.3f ms\n", total);
  return 0;
}
```