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

```asm
<main>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x48,%rsp
  mov    $0x4,%esi
  mov    $0x400000,%edi
  call   <calloc@plt>
  mov    %rax,0x30(%rsp)
  mov    $0x4,%esi
  mov    $0x400000,%edi
  call   <calloc@plt>
  mov    %rax,0x38(%rsp)
  mov    $0x4,%esi
  mov    $0x400000,%edi
  call   <calloc@plt>
  mov    %rax,%r12
  mov    %rax,0x20(%rsp)
  mov    $0x4,%esi
  mov    $0x400000,%edi
  call   <calloc@plt>
  mov    %rax,%rbp
  mov    %rax,0x28(%rsp)
  mov    $0x4,%esi
  mov    $0x400000,%edi
  call   <calloc@plt>
  mov    %rax,%r14
  mov    %rax,0x10(%rsp)
  mov    $0x4,%esi
  mov    $0x400000,%edi
  call   <calloc@plt>
  mov    %rax,%rbx
  mov    %rax,0x18(%rsp)
  mov    $0x4,%esi
  mov    $0x201804,%edi
  call   <calloc@plt>
  mov    %rax,%r15
  mov    $0x4,%esi
  mov    $0x201804,%edi
  call   <calloc@plt>
  mov    %rax,%r13
  push   %rbx
  push   %r14
  mov    %rbp,%r9
  mov    %r12,%r8
  mov    0x48(%rsp),%rcx
  mov    0x40(%rsp),%rdx
  movss  D2(%rip),%xmm4
  movss  D75(%rip),%xmm3
  movss  D217(%rip),%xmm2
  movaps %xmm2,%xmm1
  movaps %xmm4,%xmm0
  mov    $0x800,%esi
  mov    $0x800,%edi
  call   <fill_coeffs@plt>
  lea    0x806010(%r15),%rcx
  add    $0x10,%rsp
  mov    %r15,%rax
  mov    %r13,%rdx
  sub    %r15,%rdx
L112:
  movl   $0x0,(%rax)
  movl   $0x0,(%rdx,%rax,1)
  add    $0x4,%rax
  cmp    %rcx,%rax
  jne    L112
  mov    $0x800,%edx
  mov    $0x800,%esi
  lea    D180(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x1,%esi
  lea    D169(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  call   <StartTimer@plt>
  push   %r15
  push   %r13
  mov    0x28(%rsp),%r9
  mov    0x20(%rsp),%r8
  mov    0x38(%rsp),%r12
  mov    %r12,%rcx
  mov    0x30(%rsp),%rbp
  mov    %rbp,%rdx
  mov    0x48(%rsp),%r14
  mov    %r14,%rsi
  mov    0x40(%rsp),%rbx
  mov    %rbx,%rdi
  call   <red_kernel@plt>
  pxor   %xmm0,%xmm0
  cvtsi2ss %rax,%xmm0
  addss  D117(%rip),%xmm0
  movss  %xmm0,0x14(%rsp)
  push   %r13
  push   %r15
  mov    0x38(%rsp),%r9
  mov    0x30(%rsp),%r8
  mov    %r12,%rcx
  mov    %rbp,%rdx
  mov    %r14,%rsi
  mov    %rbx,%rdi
  call   <black_kernel@plt>
  pxor   %xmm0,%xmm0
  cvtsi2ss %rax,%xmm0
  addss  0x24(%rsp),%xmm0
  mulss  D41(%rip),%xmm0
  add    $0x20,%rsp
  call   <sqrt@plt>
  movss  %xmm0,0x4(%rsp)
  mov    $0x1,%ebx
  lea    D161(%rip),%rbp
L94:
  movss  D25(%rip),%xmm6
  comiss 0x4(%rsp),%xmm6
  ja     L106
  add    $0x1,%ebx
  cmp    $0xf4241,%ebx
  je     L106
  push   %r15
  push   %r13
  mov    0x28(%rsp),%r9
  mov    0x20(%rsp),%r8
  mov    0x38(%rsp),%rcx
  mov    0x30(%rsp),%rdx
  mov    0x48(%rsp),%r12
  mov    %r12,%rsi
  mov    0x40(%rsp),%r14
  mov    %r14,%rdi
  call   <red_kernel@plt>
  pxor   %xmm0,%xmm0
  cvtsi2ss %rax,%xmm0
  addss  D117(%rip),%xmm0
  movss  %xmm0,0x14(%rsp)
  push   %r13
  push   %r15
  mov    0x38(%rsp),%r9
  mov    0x30(%rsp),%r8
  mov    0x48(%rsp),%rcx
  mov    0x40(%rsp),%rdx
  mov    %r12,%rsi
  mov    %r14,%rdi
  call   <black_kernel@plt>
  pxor   %xmm0,%xmm0
  cvtsi2ss %rax,%xmm0
  addss  0x24(%rsp),%xmm0
  mulss  D41(%rip),%xmm0
  add    $0x20,%rsp
  call   <sqrt@plt>
  movss  %xmm0,0x4(%rsp)
  movslq %ebx,%rax
  imul   $0x51eb851f,%rax,%rax
  sar    $0x25,%rax
  mov    %ebx,%edx
  sar    $0x1f,%edx
  sub    %edx,%eax
  imul   $0x64,%eax,%eax
  cmp    %eax,%ebx
  jne    L94
  cvtss2sd %xmm0,%xmm0
  mov    %ebx,%esi
  mov    %rbp,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  jmp    L94
L106:
  mov    $0x0,%eax
  call   <GetTimer@plt>
  movq   %xmm0,%rbp
  lea    D28(%rip),%rdi
  call   <puts@plt>
  mov    %ebx,%esi
  lea    D143(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  movq   %rbp,%xmm0
  divsd  D117(%rip),%xmm0
  lea    D214(%rip),%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  lea    D46(%rip),%rsi
  lea    D178(%rip),%rdi
  call   <fopen@plt>
  mov    %rax,%r12
  test   %rax,%rax
  je     L113
  mov    %rax,%rcx
  mov    $0xd,%edx
  mov    $0x1,%esi
  lea    D50(%rip),%rdi
  call   <fwrite@plt>
  movl   $0x1,0x4(%rsp)
  lea    D71(%rip),%r14
  jmp    L20
L83:
  lea    0x1(%rbx),%eax
  mov    %eax,%edx
  shr    $0x1f,%edx
  add    %edx,%eax
  and    $0x1,%eax
  sub    %edx,%eax
  add    0x4(%rsp),%eax
  mov    %eax,%edx
  shr    $0x1f,%edx
  add    %edx,%eax
  sar    %eax
  add    %ebp,%eax
  cltq
  cvtss2sd %xmm0,%xmm0
  pxor   %xmm2,%xmm2
  cvtss2sd 0x0(%r13,%rax,4),%xmm2
  pxor   %xmm1,%xmm1
  cvtss2sd 0x8(%rsp),%xmm1
  mov    %r14,%rsi
  mov    %r12,%rdi
  mov    $0x3,%eax
  call   <fprintf@plt>
L18:
  add    $0x1,%ebx
  add    $0x402,%ebp
  cmp    $0x801,%ebx
  je     L2
L10:
  lea    -0x1(%rbx),%eax
  pxor   %xmm0,%xmm0
  cvtsi2ss %eax,%xmm0
  mulss  D217(%rip),%xmm0
  addss  D0(%rip),%xmm0
  mov    0xc(%rsp),%eax
  add    %ebx,%eax
  test   $0x1,%al
  jne    L83
  mov    %ebx,%eax
  shr    $0x1f,%eax
  lea    (%rbx,%rax,1),%edx
  and    $0x1,%edx
  sub    %eax,%edx
  add    0x4(%rsp),%edx
  mov    %edx,%eax
  shr    $0x1f,%eax
  add    %edx,%eax
  sar    %eax
  add    %ebp,%eax
  cltq
  cvtss2sd %xmm0,%xmm0
  pxor   %xmm2,%xmm2
  cvtss2sd (%r15,%rax,4),%xmm2
  pxor   %xmm1,%xmm1
  cvtss2sd 0x8(%rsp),%xmm1
  mov    %r14,%rsi
  mov    %r12,%rdi
  mov    $0x3,%eax
  call   <fprintf@plt>
  jmp    L18
L2:
  mov    %r12,%rsi
  mov    $0xa,%edi
  call   <fputc@plt>
  addl   $0x1,0x4(%rsp)
  mov    0x4(%rsp),%eax
  cmp    $0x801,%eax
  je     L113
L20:
  mov    0x4(%rsp),%eax
  mov    %eax,0xc(%rsp)
  sub    $0x1,%eax
  pxor   %xmm0,%xmm0
  cvtsi2ss %eax,%xmm0
  mulss  D217(%rip),%xmm0
  addss  D0(%rip),%xmm0
  movss  %xmm0,0x8(%rsp)
  mov    $0x402,%ebp
  mov    $0x1,%ebx
  jmp    L10
L113:
  mov    %r12,%rdi
  call   <fclose@plt>
  mov    0x30(%rsp),%rdi
  call   <free@plt>
  mov    0x38(%rsp),%rdi
  call   <free@plt>
  mov    0x20(%rsp),%rdi
  call   <free@plt>
  mov    0x28(%rsp),%rdi
  call   <free@plt>
  mov    0x10(%rsp),%rdi
  call   <free@plt>
  mov    0x18(%rsp),%rdi
  call   <free@plt>
  mov    %r15,%rdi
  call   <free@plt>
  mov    %r13,%rdi
  call   <free@plt>
  mov    $0x0,%eax
  add    $0x48,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

tool_calls: name: read_data
arguments: label: D2
datatype: f32
name: read_data
arguments: label: D75
datatype: f32
name: read_data
arguments: label: D217
datatype: byte[4]
name: read_data
arguments: label: D180
datatype: string
name: read_data
arguments: label: D169
datatype: string
name: read_data
arguments: label: D117
datatype: byte[8]
name: read_data
arguments: label: D41
datatype: byte[4]
name: read_data
arguments: label: D161
datatype: string
name: read_data
arguments: label: D25
datatype: byte[4]
name: read_data
arguments: label: D28
datatype: string
name: read_data
arguments: label: D143
datatype: string
name: read_data
arguments: label: D214
datatype: string
name: read_data
arguments: label: D46
datatype: string
name: read_data
arguments: label: D178
datatype: string
name: read_data
arguments: label: D50
datatype: string
name: read_data
arguments: label: D71
datatype: string
name: read_data
arguments: label: D0
datatype: byte[4]

tool: D2: 1

tool: D75: 0.01

tool: {"D217": [0x00,0x00,0x00,0x3a]}

tool: D180: Problem size: %d x %d 


tool: D169: Max threads: %d


tool: {"D117": [0x00,0x00,0x00,0x00,0x00,0x40,0x8f,0x40]}

tool: {"D41": [0x00,0x00,0x80,0x34]}

tool: D161: %5d, %0.6f


tool: {"D25": [0xbd,0x37,0x86,0x35]}

tool: D28: CPU

tool: D143: Iterations: %i


tool: D214: Total time: %f s


tool: D46: w

tool: D178: temp_cpu.dat

tool: D50: #x	y	temp(K)


tool: D71: %f	%f	%f


tool: {"D0": [0x00,0x00,0x80,0x39]}

assistant: ```c
int main(void) {
  float L = 1.0;
  float H = 1.0;
  float width = 0.01;
  float th_cond = 1.0;
  float TN = 1.0;
  float tol = 1.e-6;
  int num_rows = (2048 / 2) + 2;
  int num_cols = 2048 + 2;
  int size_temp = num_rows * num_cols;
  int size = 2048 * 2048;
  float dx = L / 2048;
  float dy = H / 2048;
  int iter;
  int it_max = 1e6;
  float *restrict aP, *restrict aW, *restrict aE, *restrict aS, *restrict aN, *restrict b;
  float *restrict temp_red, *restrict temp_black;
  aP = (float *)calloc(size, sizeof(float));
  aW = (float *)calloc(size, sizeof(float));
  aE = (float *)calloc(size, sizeof(float));
  aS = (float *)calloc(size, sizeof(float));
  aN = (float *)calloc(size, sizeof(float));
  b = (float *)calloc(size, sizeof(float));
  temp_red = (float *)calloc(size_temp, sizeof(float));
  temp_black = (float *)calloc(size_temp, sizeof(float));
  fill_coeffs(2048, 2048, th_cond, dx, dy, width, TN, aP, aW, aE, aS, aN, b);
  int i;
  for (i = 0; i < size_temp; ++i) {
    temp_red[i] = 0.0f;
    temp_black[i] = 0.0f;
  }
  printf("Problem size: %d x %d \n", 2048, 2048);
  printf("Max threads: %d\n", 1);
  StartTimer();
#pragma acc data copyin(aP [0:SIZE], aW [0:SIZE], aE [0:SIZE], aS [0:SIZE], aN [0:SIZE], b [0:SIZE]) copy(temp_red [0:SIZET], temp_black [0:SIZET])
  for (iter = 1; iter <= it_max; ++iter) {
    float norm_L2 = 0.0f;
    norm_L2 += red_kernel(aP, aW, aE, aS, aN, b, temp_black, temp_red);
    norm_L2 += black_kernel(aP, aW, aE, aS, aN, b, temp_red, temp_black);
    norm_L2 = sqrt(norm_L2 / ((float)size));
    if (iter % 100 == 0)
      printf("%5d, %0.6f\n", iter, norm_L2);
    if (norm_L2 < tol) {
      break;
    }
  }
  double runtime = GetTimer();
  printf("CPU\n");
  printf("Iterations: %i\n", iter);
  printf("Total time: %f s\n", runtime / 1000);
  FILE *pfile;
  pfile = fopen("temp_cpu.dat", "w");
  if (pfile != NULL) {
    fprintf(pfile, "#x\ty\ttemp(K)\n");
    int row, col;
    for (row = 1; row < 2048 + 1; ++row) {
      for (col = 1; col < 2048 + 1; ++col) {
        float x_pos = (col - 1) * dx + (dx / 2);
        float y_pos = (row - 1) * dy + (dy / 2);
        if ((row + col) % 2 == 0) {
          int ind = col * num_rows + (row + (col % 2)) / 2;
          fprintf(pfile, "%f\t%f\t%f\n", x_pos, y_pos, temp_red[ind]);
        } else {
          int ind = col * num_rows + (row + ((col + 1) % 2)) / 2;
          fprintf(pfile, "%f\t%f\t%f\n", x_pos, y_pos, temp_black[ind]);
        }
      }
      fprintf(pfile, "\n");
    }
  }
  fclose(pfile);
  free(aP);
  free(aW);
  free(aE);
  free(aS);
  free(aN);
  free(b);
  free(temp_red);
  free(temp_black);
  return 0;
}
```