user: 请从给定的汇编指令推导出C源代码：

```asm
<FITS_image_size>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x88,%rsp
  mov    %edi,%ebp
  mov    %rsi,%r12
  mov    %fs:0x28,%rax
  mov    %rax,0x78(%rsp)
  xor    %eax,%eax
  lea    0x30(%rsp),%rbx
  mov    $0x46,%edx
  mov    $0x20,%esi
  mov    %rbx,%rdi
  call   <memset@plt>
  mov    %rbx,%rcx
  lea    D74(%rip),%rdx
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <get_FITS_key@plt>
  cmp    $0xffffffff,%eax
  je     L227
  cmp    $0x1,%eax
  jne    L253
L142:
  lea    0x1c(%rsp),%rdx
  lea    0x30(%rsp),%rdi
  lea    D37(%rip),%rsi
  call   <sscanf@plt>
  test   %eax,%eax
  jle    L236
  mov    0x1c(%rsp),%ebx
  lea    0x28(%rsp),%r13
  lea    D73(%rip),%rsi
  mov    %r13,%rdi
  call   <strcpy@plt>
  lea    0x30(%rsp),%rcx
  mov    %r13,%rdx
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <get_FITS_key@plt>
  cmp    $0xffffffff,%eax
  je     L230
  cmp    $0x2,%eax
  jne    L231
L228:
  lea    0x20(%rsp),%rdx
  lea    0x30(%rsp),%rdi
  lea    D37(%rip),%rsi
  call   <sscanf@plt>
  test   %eax,%eax
  jle    L172
  mov    0x20(%rsp),%eax
  test   %eax,%eax
  je     L204
  mov    %ebx,%ecx
  neg    %ecx
  cmovs  %ebx,%ecx
  lea    0x7(%rcx),%edx
  test   %ecx,%ecx
  cmovns %ecx,%edx
  sar    $0x3,%edx
  mov    %edx,%r15d
  test   %eax,%eax
  jle    L5
  mov    $0x1,%ebx
  lea    0x2d(%rsp),%rax
  mov    %rax,0x8(%rsp)
  lea    D37(%rip),%r13
  lea    0x30(%rsp),%r14
  jmp    L129
L227:
  lea    D86(%rip),%rdi
  call   <puts@plt>
  mov    $0x0,%eax
  jmp    L204
L253:
  lea    D136(%rip),%rdi
  call   <puts@plt>
  jmp    L142
L236:
  lea    D140(%rip),%rdi
  call   <puts@plt>
  mov    $0x0,%eax
L204:
  mov    0x78(%rsp),%rdx
  sub    %fs:0x28,%rdx
  jne    L95
  add    $0x88,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L230:
  lea    D98(%rip),%rdi
  call   <puts@plt>
  mov    $0x0,%eax
  jmp    L204
L231:
  lea    D9(%rip),%rdi
  call   <puts@plt>
  jmp    L228
L172:
  lea    D55(%rip),%rdi
  call   <puts@plt>
  mov    $0x0,%eax
  jmp    L204
L173:
  lea    0x28(%rsp),%rsi
  lea    D26(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  jmp    L204
L16:
  lea    0x28(%rsp),%rsi
  lea    D109(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  jmp    L204
L51:
  lea    0x24(%rsp),%rdx
  mov    %r13,%rsi
  mov    %r14,%rdi
  call   <sscanf@plt>
  test   %eax,%eax
  jle    L144
  imul   0x24(%rsp),%r15d
  add    $0x1,%ebx
  cmp    %ebx,0x20(%rsp)
  jl     L139
L129:
  mov    %ebx,%ecx
  mov    %r13,%rdx
  mov    $0x3,%esi
  mov    0x8(%rsp),%rdi
  call   <snprintf@plt>
  test   %eax,%eax
  jle    L173
  lea    0x28(%rsp),%rdx
  mov    %r14,%rcx
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <get_FITS_key@plt>
  cmp    $0xffffffff,%eax
  je     L16
  lea    0x2(%rbx),%edx
  cmp    %eax,%edx
  je     L51
  lea    0x28(%rsp),%rsi
  lea    D56(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L51
L144:
  lea    0x28(%rsp),%rsi
  lea    D117(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  jmp    L204
L139:
  mov    %r15d,%eax
  jmp    L204
L5:
  mov    %edx,%eax
  jmp    L204
L95:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: tag: D74
datatype: string
name: disassemble_data
arguments: tag: D37
datatype: string
name: disassemble_data
arguments: tag: D73
datatype: string
name: disassemble_data
arguments: tag: D86
datatype: string
name: disassemble_data
arguments: tag: D136
datatype: string
name: disassemble_data
arguments: tag: D140
datatype: string
name: disassemble_data
arguments: tag: D98
datatype: string
name: disassemble_data
arguments: tag: D9
datatype: string
name: disassemble_data
arguments: tag: D55
datatype: string
name: disassemble_data
arguments: tag: D26
datatype: string
name: disassemble_data
arguments: tag: D109
datatype: string
name: disassemble_data
arguments: tag: D56
datatype: string
name: disassemble_data
arguments: tag: D117
datatype: string

tool: D74: BITPIX

tool: D37: %d

tool: D73: NAXIS

tool: D86: 
	ERROR! FITS_image_size(): BITPIX not found in the header

tool: D136: 
	WARNING! header does not conform to FITS standard (BITPIX)

tool: D140: 
	ERROR! FITS_image_size(): reading BITPIX

tool: D98: 
	ERROR! FITS_image_size(): NAXIS not found in the header

tool: D9: 
	WARNING! header does not conform to FITS standard (NAXIS)

tool: D55: 
	ERROR! FITS_image_size(): reading NAXIS

tool: D26: 
	ERROR! FITS_image_size(): %s


tool: D109: 
	ERROR! FITS_image_size(): %s not found in the header


tool: D56: 
	WARNING! header does not conform to FITS standard (%s)


tool: D117: 
	ERROR! FITS_image_size(): reading %s


assistant: ```c
int FITS_image_size(const int ncards, char **header) {
  char val[70], keyword[8];
  int i, p, bitpix, bytepix, naxis, naxisn, size;
  memset(val, ' ', 70);
  if ((p = get_FITS_key(ncards, header, "BITPIX", val)) == -1) {
    printf("\n\tERROR! FITS_image_size(): BITPIX not found in the header\n");
    return (0);
  }
  if (p != 1)
    printf("\n\tWARNING! header does not conform to FITS standard (BITPIX)\n");
  if (sscanf(val, "%d", &bitpix) < 1) {
    printf("\n\tERROR! FITS_image_size(): reading BITPIX\n");
    return (0);
  }
  bytepix = abs(bitpix) / 8;
  strcpy(keyword, "NAXIS");
  if ((p = get_FITS_key(ncards, header, keyword, val)) == -1) {
    printf("\n\tERROR! FITS_image_size(): NAXIS not found in the header\n");
    return (0);
  }
  if (p != 2)
    printf("\n\tWARNING! header does not conform to FITS standard (NAXIS)\n");
  if (sscanf(val, "%d", &naxis) < 1) {
    printf("\n\tERROR! FITS_image_size(): reading NAXIS\n");
    return (0);
  }
  if (naxis == 0)
    return (0);
  size = bytepix;
  for (i = 1; i <= naxis; i++) {
    if (snprintf((keyword + 5), 8 - 5, "%d", i) < 1) {
      printf("\n\tERROR! FITS_image_size(): %s\n", keyword);
      return (0);
    }
    if ((p = get_FITS_key(ncards, header, keyword, val)) == -1) {
      printf("\n\tERROR! FITS_image_size(): %s not found in the header\n", keyword);
      return (0);
    }
    if (p != i + 2)
      printf("\n\tWARNING! header does not conform to FITS standard (%s)\n", keyword);
    if (sscanf(val, "%d", &naxisn) < 1) {
      printf("\n\tERROR! FITS_image_size(): reading %s\n", keyword);
      return (0);
    }
    size *= naxisn;
  }
  return (size);
}
```