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

```asm
<read_IntelHEX>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x468,%rsp
  mov    %rdi,0x18(%rsp)
  mov    %rsi,%rdi
  lea    D13(%rip),%rsi
  mov    %fs:0x28,%rax
  mov    %rax,0x458(%rsp)
  xor    %eax,%eax
  call   <fopen@plt>
  mov    %rax,0x28(%rsp)
  test   %rax,%rax
  je     L78
  lea    0x4c(%rsp),%rsi
  mov    %rax,%rdi
  call   <fstat@plt>
  mov    0x4c(%rsp),%eax
  lea    0x50(%rsp),%rsi
  xor    %r8d,%r8d
  mov    %rsi,0x30(%rsp)
  mov    %eax,0x10(%rsp)
  test   %eax,%eax
  je     L54
  nopl   0x0(%rax)
L354:
  mov    0x10(%rsp),%r15d
  mov    %r8d,0x20(%rsp)
  cmp    $0x3ff,%r15d
  jle    L1670
  mov    0x28(%rsp),%rcx
  mov    0x30(%rsp),%rdi
  mov    $0x1,%edx
  mov    $0x400,%esi
  sub    $0x400,%r15d
  call   <fread@plt>
  mov    0x20(%rsp),%r8d
  mov    %r15d,0x10(%rsp)
  lea    0x51(%rsp),%r15
L367:
  movzbl (%r15),%eax
  mov    %r8d,0x20(%rsp)
  lea    0x450(%rsp),%r14
  cmp    $0x3a,%al
  jne    L948
  nopw   0x0(%rax,%rax,1)
L515:
  lea    0x1(%r15),%r12
  lea    -0x1(%r12),%rax
  mov    %r12,%r13
  cmp    %rax,%r14
  jbe    L1108
L1460:
  movsbl (%r12),%edi
  cmp    $0x3a,%dil
  jne    L625
  lea    0x1(%r12),%r15
  cmp    %r14,%r12
  jae    L1108
  movsbl 0x1(%r12),%edi
  cmp    $0x3a,%dil
  je     L1949
L1948:
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  je     L630
  mov    %r15,%r13
L684:
  shl    $0x4,%eax
  lea    0x1(%r13),%r15
  mov    %eax,0x8(%rsp)
  cmp    %r14,%r13
  jae    L508
  movzbl 0x1(%r13),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    %r15,%r8
  cmp    $0xff,%eax
  je     L1685
L2048:
  or     %eax,0x8(%rsp)
  lea    0x1(%r8),%r15
  mov    0x8(%rsp),%ecx
  cmp    %r14,%r8
  jae    L307
  movzbl 0x1(%r8),%eax
  mov    %r8,0x20(%rsp)
  mov    %ecx,0xc(%rsp)
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r8
  cmp    $0xff,%eax
  je     L748
  shl    $0xc,%eax
  mov    0x8(%rsp),%edx
  lea    0x2(%r8),%r13
  movslq %eax,%rbx
  sar    $0x8,%eax
  add    %ebx,%eax
  mov    %rbx,%rbp
  add    0x18(%rsp),%rbx
  sub    %eax,%edx
  mov    %edx,0xc(%rsp)
  cmp    %r14,%r15
  jae    L198
  movzbl 0x2(%r8),%eax
  mov    %r8,0x20(%rsp)
  mov    %r13,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r8
  cmp    $0xff,%eax
  je     L1271
  shl    $0x8,%eax
  lea    0x3(%r8),%rdx
  or     %eax,%ebp
  mov    %ebp,%eax
  movslq %ebp,%rbx
  add    0x18(%rsp),%rbx
  sar    $0x8,%eax
  add    %ebp,%eax
  sub    %eax,0xc(%rsp)
  cmp    %r14,%r13
  jae    L654
  movzbl 0x3(%r8),%eax
  mov    %rdx,0x20(%rsp)
  mov    %rdx,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%rdx
  cmp    $0xff,%eax
  je     L807
  mov    $0x5,%r8d
  jmp    L670
  nop
L625:
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  jne    L684
  cmp    %r14,%r12
  jae    L1108
  movsbl 0x1(%r12),%edi
  lea    0x1(%r12),%r15
  cmp    $0x3a,%dil
  jne    L1948
  nopw   0x0(%rax,%rax,1)
L1949:
  add    $0x2,%r12
  lea    -0x1(%r12),%rax
  mov    %r12,%r13
  cmp    %rax,%r14
  ja     L1460
L1108:
  xor    %r8d,%r8d
L1961:
  mov    0x10(%rsp),%edx
  test   %edx,%edx
  jne    L354
L54:
  mov    0x458(%rsp),%rdx
  sub    %fs:0x28,%rdx
  jne    L1506
  add    $0x468,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   (%rax)
L630:
  lea    0x2(%r12),%r13
  cmp    %r14,%r15
  jae    L1108
  movzbl 0x1(%r15),%eax
  cmp    $0x3a,%al
  jne    L2078
  nopw   0x0(%rax,%rax,1)
L1865:
  mov    %r13,%r15
  jmp    L515
  nopl   0x0(%rax,%rax,1)
L1670:
  mov    0x10(%rsp),%esi
  mov    $0x400,%r9d
  mov    0x28(%rsp),%r15
  mov    $0x1,%edx
  lea    0x450(%rsp),%r14
  sub    %esi,%r9d
  mov    %r15,%rcx
  movslq %r9d,%r9
  add    0x30(%rsp),%r9
  mov    %r9,%rdi
  mov    %r9,0x10(%rsp)
  call   <fread@plt>
  mov    %r15,%rdi
  call   <fclose@plt>
  mov    0x10(%rsp),%r9
  lea    0x1(%r9),%r15
  cmp    %r14,%r9
  jae    L54
  movl   $0x0,0x10(%rsp)
  mov    0x20(%rsp),%r8d
  jmp    L367
L748:
  lea    0x2(%r8),%rcx
  cmp    %r14,%r15
  jae    L1230
  movzbl 0x2(%r8),%eax
  mov    %r8,0x38(%rsp)
  mov    %rcx,%r15
  mov    %rcx,0x20(%rsp)
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%rcx
  mov    0x38(%rsp),%r8
  cmp    $0xff,%eax
  je     L123
  shl    $0xc,%eax
  mov    0x8(%rsp),%esi
  lea    0x3(%r8),%rdx
  movslq %eax,%rbx
  sar    $0x8,%eax
  add    %ebx,%eax
  mov    %rbx,%rbp
  add    0x18(%rsp),%rbx
  sub    %eax,%esi
  mov    %esi,0xc(%rsp)
  cmp    %r14,%rcx
  jae    L198
L1234:
  movzbl 0x3(%r8),%eax
  mov    %rdx,0x20(%rsp)
  mov    %rdx,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%rdx
  mov    $0x4,%r8d
  cmp    $0xff,%eax
  je     L1262
L670:
  mov    $0x6,%ecx
  sub    %r8d,%ecx
  shl    $0x2,%ecx
L1754:
  shl    %cl,%eax
  or     %eax,%ebp
  mov    %ebp,%eax
  movslq %ebp,%rbx
  add    0x18(%rsp),%rbx
  sar    $0x8,%eax
  add    %ebp,%eax
  sub    %eax,0xc(%rsp)
  jmp    L917
L1685:
  lea    0x2(%r13),%r8
  cmp    %r14,%r15
  jae    L508
  movzbl 0x2(%r13),%eax
  mov    %r8,0x20(%rsp)
  mov    %r8,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r8
  cmp    $0xff,%eax
  jne    L2048
  lea    0x3(%r13),%r15
  cmp    %r14,%r8
  jae    L508
  movzbl 0x3(%r13),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  je     L1060
  mov    %r15,%r8
  jmp    L2048
  nopw   0x0(%rax,%rax,1)
L78:
  xor    %eax,%eax
  jmp    L54
L508:
  mov    $0x1,%r8d
  jmp    L1961
L307:
  mov    0x8(%rsp),%eax
  mov    $0x2,%r8d
  mov    %eax,0xc(%rsp)
  jmp    L1961
L1271:
  lea    0x3(%r8),%rdx
  cmp    %r14,%r13
  jb     L1234
L198:
  mov    $0x3,%r8d
  jmp    L1961
L1230:
  mov    $0x2,%r8d
  jmp    L1961
L948:
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r8d
  cmp    $0xff,%eax
  je     L1116
  lea    0x1(%r8),%edi
  cmp    $0x9,%r8d
  jg     L1210
  ja     L164
  lea    D4(%rip),%rdx
  movslq (%rdx,%r8,4),%rcx
  add    %rdx,%rcx
  notrack jmp *%rcx
L1506:
  call   <__stack_chk_fail@plt>
  lea    0x450(%rsp),%r14
L208:
  or     (%rbx),%al
  subl   $0x1,0x8(%rsp)
  lea    0x1(%r15),%r10
  add    $0x1,%rbx
  mov    %al,-0x1(%rbx)
  movsbl %al,%eax
  sub    %eax,0xc(%rsp)
  mov    0x8(%rsp),%eax
  test   %eax,%eax
  jle    L1138
  cmp    %r14,%r15
  jae    L396
  movzbl 0x1(%r15),%eax
  cmp    $0x3a,%al
  je     L667
  movsbl %al,%edi
  mov    %r10,0x20(%rsp)
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  je     L91
L402:
  lea    0x1(%r10),%r15
  cmp    $0x1,%eax
  je     L1122
  cmp    %r14,%r10
  jae    L214
  movzbl 0x1(%r10),%eax
  mov    %r10,0x20(%rsp)
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  mov    %r15,%r13
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  je     L1474
L1559:
  shl    $0x4,%eax
  lea    0x1(%r13),%r15
  mov    %al,(%rbx)
  cmp    %r14,%r13
  jae    L1680
  movzbl 0x1(%r13),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  jne    L208
  lea    0x2(%r13),%r8
  cmp    %r14,%r15
  jae    L1680
  movzbl 0x2(%r13),%eax
  mov    %r8,0x20(%rsp)
  mov    %r8,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r8
  cmp    $0xff,%eax
  jne    L208
  lea    0x3(%r13),%r15
  cmp    %r14,%r8
  jae    L1680
  movzbl 0x3(%r13),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  jne    L208
  mov    %r15,%rdx
  mov    $0x9,%r8d
  nopw   0x0(%rax,%rax,1)
L917:
  lea    0x1(%rdx),%r15
  cmp    %r14,%rdx
  jb     L367
  jmp    L1961
  nopw   0x0(%rax,%rax,1)
L667:
  lea    0x2(%r15),%r13
  cmp    %r14,%r10
  jae    L1108
  movzbl 0x2(%r15),%eax
  cmp    $0x3a,%al
  je     L1865
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  jne    L684
  lea    0x3(%r15),%r8
  cmp    %r14,%r13
  jae    L1108
  movzbl 0x3(%r15),%eax
  cmp    $0x3a,%al
  je     L1292
  movsbl %al,%edi
  mov    %r8,0x20(%rsp)
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r8
  mov    %r8,%r13
  cmp    $0xff,%eax
  jne    L684
  lea    0x4(%r15),%rdx
  cmp    %r14,%r8
  jae    L1108
  movzbl 0x4(%r15),%eax
  mov    %rdx,0x20(%rsp)
  mov    %rdx,%r15
  cmp    $0x3a,%al
  je     L515
L2099:
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%rdx
  mov    %rdx,%r13
  cmp    $0xff,%eax
  jne    L684
L903:
  xor    %r8d,%r8d
  jmp    L917
  nopl   0x0(%rax)
L1138:
  cmp    %r14,%r15
  jae    L1158
  movzbl 0x1(%r15),%eax
  cmp    $0x3a,%al
  je     L667
  movsbl %al,%edi
  mov    %r10,0x20(%rsp)
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  mov    %eax,%r8d
  je     L105
L946:
  xor    %eax,%eax
  cmp    $0xf,%r8d
  sete   %al
  test   %eax,0xc(%rsp)
  je     L78
  lea    0x450(%rsp),%r14
  lea    0x1(%r10),%r15
  cmp    %r14,%r10
  jae    L348
  movzbl 0x1(%r10),%eax
  mov    %r10,0x20(%rsp)
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  mov    %r15,%r13
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  mov    %eax,%r8d
  je     L692
L131:
  shl    $0x4,%r8d
  xor    %eax,%eax
  cmp    $0xf0,%r8d
  sete   %al
  and    0xc(%rsp),%eax
  je     L78
  test   %rbx,%rbx
  jne    L1837
  test   %ebp,%ebp
  je     L54
L1837:
  lea    0x450(%rsp),%r14
  lea    0x1(%r13),%r15
  cmp    %r14,%r13
  jae    L114
  movzbl 0x1(%r13),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  lea    0x2(%r13),%r12
  call   <Char2Int@plt>
  cmp    %r14,%r15
  jae    L114
  movzbl 0x2(%r13),%eax
  mov    %r12,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  je     L1375
  lea    0x3(%r13),%r15
  cmp    %r14,%r12
  jae    L114
  movzbl 0x3(%r13),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    %eax,%r8d
  cmp    $0xff,%eax
  je     L1116
  mov    $0xff,%r10d
L1149:
  mov    %r15,%rdx
  mov    %r10d,%r8d
  jmp    L917
  nopl   0x0(%rax,%rax,1)
L1122:
  cmp    %r14,%r10
  jae    L2063
  movzbl 0x1(%r10),%eax
  cmp    $0x3a,%al
  jne    L1254
  lea    0x2(%r10),%r13
  cmp    %r14,%r15
  jae    L494
  movzbl 0x2(%r10),%eax
  mov    %r10,0x20(%rsp)
  cmp    $0x3a,%al
  je     L680
  movsbl %al,%edi
  xor    %ebp,%ebp
  xor    %ebx,%ebx
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  jne    L684
  lea    0x3(%r10),%r8
  cmp    %r14,%r13
  jae    L1108
  movzbl 0x3(%r10),%eax
  mov    %r10,0x38(%rsp)
  mov    %r8,%r15
  mov    %r8,0x20(%rsp)
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r8
  mov    0x38(%rsp),%r10
  cmp    $0xff,%eax
  mov    %r8,%r13
  jne    L684
  lea    0x4(%r10),%r15
  cmp    %r14,%r8
  jae    L494
  movzbl 0x4(%r10),%eax
  cmp    $0x3a,%al
  je     L1170
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  je     L390
  mov    %r15,%r13
  xor    %ebp,%ebp
  xor    %ebx,%ebx
  jmp    L684
  nopl   0x0(%rax)
L1254:
  movsbl %al,%edi
  mov    %r10,0x20(%rsp)
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  mov    %eax,%r8d
  je     L1526
  mov    %r15,%r10
  xor    %ebx,%ebx
  xor    %ebp,%ebp
  jmp    L946
L692:
  lea    0x2(%r10),%r13
  cmp    %r14,%r15
  jae    L348
  movzbl 0x2(%r10),%eax
  mov    %r13,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  mov    %eax,%r8d
  jne    L131
  lea    0x3(%r10),%r15
  cmp    %r14,%r13
  jae    L348
  movzbl 0x3(%r10),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    %eax,%r8d
  cmp    $0xff,%eax
  je     L516
L1966:
  mov    %r15,%r13
  jmp    L131
  nopl   0x0(%rax)
L1474:
  lea    0x2(%r10),%r13
  cmp    %r14,%r15
  jae    L214
  movzbl 0x2(%r10),%eax
  mov    %r13,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  jne    L1559
  lea    0x3(%r10),%r15
  cmp    %r14,%r13
  jae    L214
  movzbl 0x3(%r10),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  je     L699
  mov    %r15,%r13
  jmp    L1559
  nopw   0x0(%rax,%rax,1)
L91:
  lea    0x2(%r15),%r13
  cmp    %r14,%r10
  jae    L396
  movzbl 0x2(%r15),%eax
  cmp    $0x3a,%al
  je     L1865
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    %r13,%r10
  cmp    $0xff,%eax
  jne    L402
  lea    0x3(%r15),%r10
  cmp    %r14,%r13
  jae    L396
  movzbl 0x3(%r15),%eax
  cmp    $0x3a,%al
  jne    L1190
L1872:
  mov    %r10,%r15
  jmp    L515
  nopw   0x0(%rax,%rax,1)
L680:
  mov    %r13,%r15
  xor    %ebp,%ebp
  xor    %ebx,%ebx
  jmp    L515
L105:
  lea    0x2(%r15),%r13
  cmp    %r14,%r10
  jae    L1158
  movzbl 0x2(%r15),%eax
  cmp    $0x3a,%al
  je     L1865
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    %r13,%r10
  mov    %eax,%r8d
  cmp    $0xff,%eax
  jne    L946
  lea    0x3(%r15),%r10
  cmp    %r14,%r13
  jae    L1158
  movzbl 0x3(%r15),%eax
  cmp    $0x3a,%al
  je     L1872
  movsbl %al,%edi
  mov    %r10,0x20(%rsp)
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  mov    %eax,%r8d
  jne    L946
  lea    0x4(%r15),%rdx
  cmp    %r14,%r10
  jae    L1158
  movzbl 0x4(%r15),%eax
  mov    %rdx,0x20(%rsp)
  mov    %rdx,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%rdx
  cmp    $0xff,%eax
  mov    %eax,%r8d
  je     L483
L197:
  mov    %r15,%r10
  jmp    L946
  nopw   0x0(%rax,%rax,1)
L1526:
  lea    0x2(%r10),%rbp
  cmp    %r14,%r15
  jae    L2063
  movzbl 0x2(%r10),%eax
  mov    %rbp,%r15
  cmp    $0x3a,%al
  je     L1170
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  mov    %eax,%r8d
  je     L16
  mov    %rbp,%r10
  xor    %ebx,%ebx
  xor    %ebp,%ebp
  jmp    L946
L114:
  mov    $0xff,%r8d
  jmp    L1961
L348:
  mov    $0xfe,%r8d
  jmp    L1961
L1680:
  mov    $0x9,%r8d
  jmp    L1961
L1170:
  xor    %ebp,%ebp
  xor    %ebx,%ebx
  jmp    L515
L214:
  mov    $0x8,%r8d
  jmp    L1961
L396:
  mov    $0x7,%r8d
  jmp    L1961
L1158:
  mov    $0xfd,%r8d
  jmp    L1961
L2063:
  xor    %ebx,%ebx
  xor    %ebp,%ebp
  mov    $0xfd,%r8d
  jmp    L1961
L16:
  lea    0x3(%r10),%rbx
  cmp    %r14,%rbp
  jae    L2063
  movzbl 0x3(%r10),%eax
  cmp    $0x3a,%al
  je     L855
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  mov    %eax,%r8d
  je     L2090
  mov    %rbx,%r10
  xor    %ebp,%ebp
  xor    %ebx,%ebx
  jmp    L946
  nop
L494:
  xor    %ebx,%ebx
  xor    %ebp,%ebp
  xor    %r8d,%r8d
  jmp    L1961
L1375:
  mov    %eax,0x20(%rsp)
  lea    0x3(%r13),%r15
  cmp    %r14,%r12
  jae    L114
  movzbl 0x3(%r13),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10d
  cmp    $0xff,%eax
  mov    %eax,%r8d
  jne    L1149
L1116:
  mov    %r15,%rdx
  jmp    L917
L1190:
  movsbl %al,%edi
  mov    %r10,0x20(%rsp)
  call   <Char2Int@plt>
  mov    0x20(%rsp),%r10
  cmp    $0xff,%eax
  jne    L402
  lea    0x4(%r15),%rdx
  cmp    %r14,%r10
  jae    L396
  movzbl 0x4(%r15),%eax
  mov    %rdx,0x20(%rsp)
  mov    %rdx,%r15
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    0x20(%rsp),%rdx
  mov    %r15,%r10
  mov    $0x7,%r8d
  cmp    $0xff,%eax
  jne    L402
  jmp    L917
L483:
  mov    $0xfd,%r8d
  jmp    L917
L699:
  mov    %r15,%rdx
  mov    $0x8,%r8d
  jmp    L917
  mov    %r15,%r13
  lea    0x450(%rsp),%r14
  jmp    L1559
L1292:
  mov    %r8,%r15
  jmp    L515
  mov    %r15,%r13
  lea    0x450(%rsp),%r14
  jmp    L684
L1210:
  mov    %r8d,%r10d
  mov    %eax,%r8d
  cmp    $0xfd,%r10d
  je     L197
  cmp    $0xfe,%r10d
  je     L1966
  jmp    L1149
L164:
  mov    %r15,%rdx
  mov    $0x6,%r8d
  lea    0x450(%rsp),%r14
  jmp    L917
L1060:
  mov    %r15,%rdx
  mov    $0x1,%r8d
  jmp    L917
L1262:
  mov    $0x3,%r8d
  jmp    L917
L123:
  lea    0x3(%r8),%r15
  cmp    %r14,%rcx
  jae    L1230
  movzbl 0x3(%r8),%eax
  cmp    $0x3a,%al
  je     L515
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  je     L1607
L1002:
  mov    %r15,%rdx
  mov    $0xc,%ecx
  mov    $0x3,%r8d
  xor    %ebp,%ebp
  jmp    L1754
L2078:
  movsbl %al,%edi
  call   <Char2Int@plt>
  cmp    $0xff,%eax
  jne    L684
  lea    0x3(%r12),%rdx
  cmp    %r14,%r13
  jae    L1108
  movzbl 0x2(%r15),%eax
  cmp    $0x3a,%al
  je     L1669
  mov    %rdx,0x20(%rsp)
  jmp    L2099
L1607:
  mov    %r15,%rdx
  mov    $0x2,%r8d
  jmp    L917
L1669:
  mov    %rdx,%r15
  jmp    L515
L807:
  mov    $0x4,%r8d
  jmp    L917
L654:
  mov    $0x4,%r8d
  jmp    L1961
  mov    %r15,%r10
  lea    0x450(%rsp),%r14
  jmp    L402
  mov    %r15,%rdx
  mov    %edi,%r8d
  lea    0x450(%rsp),%r14
  jmp    L670
  lea    0x450(%rsp),%r14
  jmp    L1002
  mov    %r15,%r8
  lea    0x450(%rsp),%r14
  jmp    L2048
L516:
  mov    %r15,%rdx
  mov    $0xfe,%r8d
  jmp    L917
L390:
  mov    %r15,%rdx
  jmp    L903
L2090:
  lea    0x4(%r10),%r15
  cmp    %r14,%rbx
  jae    L2063
  movzbl 0x4(%r10),%eax
  cmp    $0x3a,%al
  je     L1170
  movsbl %al,%edi
  call   <Char2Int@plt>
  mov    %eax,%r8d
  cmp    $0xff,%eax
  je     L1394
  xor    %ebp,%ebp
  xor    %ebx,%ebx
  jmp    L197
L855:
  mov    %rbx,%r15
  xor    %ebp,%ebp
  xor    %ebx,%ebx
  jmp    L515
L1394:
  mov    %r15,%rdx
  xor    %ebx,%ebx
  xor    %ebp,%ebp
  mov    $0xfd,%r8d
  jmp    L917
```

tool_calls: name: unpack_data
arguments: data_label: D13
datatype: string

tool: D13: rb

assistant: ```c
__attribute__((visibility("default"))) bool read_IntelHEX(void *ROM, char *file) {
  FILE *in_file;
  uint8_t parsed, lenght, checksum, mode = 0;
  uint16_t address;
  char buffer[1024];
  char *buffer_ptr;
  char *target_ptr;
  struct stat file_disc;
  if (!(in_file = fopen(file, "rb")))
    return false;
  fstat(in_file, &file_disc);
  for (int size = file_disc.st_size; size;) {
    if (size >= 1024) {
      fread(buffer_ptr = buffer, 1024, 1, in_file);
      size -= 1024;
    } else {
      fread(buffer_ptr = &buffer[1024 - size], size, 1, in_file);
      size = 0;
      fclose(in_file);
    }
    while (buffer_ptr++ < &buffer[1024]) {
      if (*buffer_ptr == ':')
        mode = 0;
      else if ((parsed = Char2Int(*buffer_ptr)) != 255) {
        switch (mode++) {
        case 0:
          lenght = parsed << 4;
          break;
        case 1:
          lenght |= parsed;
          checksum = lenght;
          break;
        case 2:
          address = 0;
        case 3:
        case 4:
        case 5:
          address |= parsed << (4 * (6 - mode));
          checksum -= address + (address >> 8);
          target_ptr = &ROM[address];
          break;
        case 7:
          if (parsed == 1) {
            mode += (253 - 8);
            target_ptr = NULL;
            address = 0;
          }
          break;
        case 8:
          *target_ptr = parsed << 4;
          break;
        case 9:
          *target_ptr |= parsed;
          checksum -= *(target_ptr++);
          if (--lenght > 0)
            mode = 7;
          else
            mode += (253 - 10);
          break;
        case 253:
          if (!(checksum & 0x0F == parsed))
            return false;
          break;
        case 254:
          if (!(checksum & 0xF0 == parsed << 4))
            return false;
          else if ((target_ptr == NULL) && (address == 0))
            return true;
          break;
        case 6:
        case 255:
        default:
          mode--;
          break;
        }
      }
    }
  }
}
```