user: Translate the below assembly code into C programming language:

```asm
<read_data_double2>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbx
  mov    %edx,%ebx
  sub    $0x48,%rsp
  mov    %rcx,-0x68(%rbp)
  mov    %rdi,-0x60(%rbp)
  mov    %rsp,%rcx
  mov    %esi,-0x54(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  xor    %eax,%eax
  imul   $0x1e,%edx,%eax
  mov    %eax,-0x58(%rbp)
  cltq
  add    $0xf,%rax
  mov    %rax,%rdx
  and    $0xfffffffffffff000,%rax
  sub    %rax,%rcx
  and    $0xfffffffffffffff0,%rdx
  cmp    %rcx,%rsp
  je     L49
L46:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rcx,%rsp
  jne    L46
L49:
  and    $0xfff,%edx
  sub    %rdx,%rsp
  test   %rdx,%rdx
  jne    L113
L142:
  mov    -0x60(%rbp),%rdi
  lea    D60(%rip),%rsi
  mov    %rsp,-0x50(%rbp)
  call   <fopen@plt>
  mov    %rax,%r15
  test   %rax,%rax
  jne    L75
  mov    -0x60(%rbp),%rsi
  xor    %edx,%edx
  lea    D27(%rip),%rdi
  call   <print_error_global@plt>
L75:
  mov    -0x50(%rbp),%rdi
  mov    -0x58(%rbp),%esi
  mov    %r15,%rdx
  lea    D29(%rip),%r12
  call   <fgets@plt>
  mov    %r15,%rdi
  movl   $0x0,-0x48(%rbp)
  movl   $0x0,-0x44(%rbp)
  call   <feof@plt>
  test   %eax,%eax
  jne    L59
  xchg   %ax,%ax
L58:
  mov    -0x54(%rbp),%ecx
  cmp    %ecx,-0x44(%rbp)
  jge    L59
  mov    -0x50(%rbp),%rdi
  mov    %r12,%rsi
  call   <strtok@plt>
  mov    %rax,%r9
  test   %ebx,%ebx
  jle    L125
  test   %rax,%rax
  je     L125
  movslq -0x48(%rbp),%rax
  mov    -0x68(%rbp),%rcx
  mov    $0x1,%r14d
  mov    %r9,%rdi
  lea    (%rcx,%rax,8),%r13
  nopl   0x0(%rax)
L179:
  call   <atof@plt>
  pxor   %xmm0,%xmm0
  xor    %edi,%edi
  mov    %r12,%rsi
  cvtsi2sd %rax,%xmm0
  movsd  %xmm0,-0x8(%r13,%r14,8)
  call   <strtok@plt>
  mov    %r14d,%r10d
  test   %rax,%rax
  mov    %rax,%rdi
  setne  %dl
  cmp    %r14d,%ebx
  setg   %al
  add    $0x1,%r14
  test   %al,%dl
  jne    L179
  mov    %rdi,%r9
L28:
  addl   $0x1,-0x44(%rbp)
  mov    -0x44(%rbp),%edx
  cmp    %r10d,%ebx
  je     L82
  mov    -0x60(%rbp),%rsi
  mov    %ebx,%r8d
  mov    %r10d,%ecx
  xor    %eax,%eax
  lea    D31(%rip),%rdi
  mov    %r9,-0x70(%rbp)
  call   <printf@plt>
  mov    %r15,%rdi
  call   <fclose@plt>
  mov    $0x1,%edi
  call   <exit@plt>
  mov    -0x70(%rbp),%r9
L82:
  test   %r9,%r9
  je     L90
  mov    -0x44(%rbp),%edx
  mov    -0x60(%rbp),%rsi
  mov    %ebx,%ecx
  lea    D59(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    %r15,%rdi
  call   <fclose@plt>
  mov    $0x1,%edi
  call   <exit@plt>
L90:
  mov    -0x50(%rbp),%rdi
  mov    -0x58(%rbp),%esi
  mov    %r15,%rdx
  call   <fgets@plt>
  mov    %r15,%rdi
  add    %ebx,-0x48(%rbp)
  call   <feof@plt>
  test   %eax,%eax
  je     L58
L59:
  mov    -0x44(%rbp),%eax
  mov    -0x54(%rbp),%ecx
  cmp    %ecx,%eax
  je     L56
  mov    -0x60(%rbp),%rsi
  mov    %eax,%edx
  lea    D65(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    %r15,%rdi
  call   <fclose@plt>
  mov    $0x1,%edi
  call   <exit@plt>
L56:
  mov    %r15,%rdi
  call   <feof@plt>
  test   %eax,%eax
  je     L119
L36:
  mov    %r15,%rdi
  call   <fclose@plt>
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  jne    L38
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
  nopl   0x0(%rax)
L125:
  xor    %r10d,%r10d
  jmp    L28
L119:
  mov    -0x54(%rbp),%edx
  mov    -0x60(%rbp),%rsi
  lea    D52(%rip),%rdi
  call   <printf@plt>
  mov    %r15,%rdi
  call   <fclose@plt>
  mov    $0x1,%edi
  call   <exit@plt>
  jmp    L36
L113:
  orq    $0x0,-0x8(%rsp,%rdx,1)
  jmp    L142
L38:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D60
type_guessed: string
name: extract_symbolic_data
arguments: data_tag: D27
type_guessed: string
name: extract_symbolic_data
arguments: data_tag: D29
type_guessed: string
name: extract_symbolic_data
arguments: data_tag: D31
type_guessed: string
name: extract_symbolic_data
arguments: data_tag: D59
type_guessed: string
name: extract_symbolic_data
arguments: data_tag: D65
type_guessed: string
name: extract_symbolic_data
arguments: data_tag: D52
type_guessed: string

tool: D60: r

tool: D27: open

tool: D29:  

tool: D31: Error: unable to read file %s. It seems that line %d contains %d columns instead of %d.



tool: D59: Error: unable to read file %s. It seems that line %d contains more than %d columns.



tool: D65: Error: unable to read file %s. It seems that it contains %d lines instead of %d.



tool: D52: Error: unable to read file %s. It seems that it contains more than %d lines.



assistant: ```c
void read_data_double2(char *file_data, int N, int M, double *dat) {
  FILE *m_File = NULL;
  int i = 0;
  int j = 0;
  int max_char_per_line = 30 * M;
  char szbuff[max_char_per_line];
  char *token;
  int lmax = N;
  int cmax = M;
  i = 0;
  m_File = fopen(file_data, "r");
  if (!m_File)
    print_error_global("open", file_data, 0);
  token = fgets(szbuff, max_char_per_line, m_File);
  while (!feof(m_File) & (i < lmax)) {
    j = 0;
    token = strtok(szbuff, " ");
    while (token && j < cmax) {
      dat[i * M + j] = (double)atof(token);
      token = strtok(NULL, " ");
      j++;
    }
    i++;
    if (j != cmax) {
      printf("Error: unable to read file %s. It seems that"
             " line %d contains %d columns instead of %d."
             "\n\n",
             file_data, i, j, cmax);
      fclose(m_File);
      exit(1);
    }
    if (token) {
      printf("Error: unable to read file %s. It seems that"
             " line %d contains more than %d columns.\n\n",
             file_data, i, cmax);
      fclose(m_File);
      exit(1);
    }
    token = fgets(szbuff, max_char_per_line, m_File);
  }
  if (i != lmax) {
    printf("Error: unable to read file %s. It seems that it "
           "contains %d lines instead of %d.\n\n",
           file_data, i, lmax);
    fclose(m_File);
    exit(1);
  }
  if (!feof(m_File)) {
    printf("Error: unable to read file %s. It seems that it "
           "contains more than %d lines.\n\n",
           file_data, lmax);
    fclose(m_File);
    exit(1);
  }
  fclose(m_File);
}
```