user: 请显示与下面列出的汇编代码相匹配的C语言实现:

```asm
<inverse_mat3>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  mov    -0x18(%rbp),%rax
  mov    %rax,%rdi
  call   <determinant3x3@plt>
  movq   %xmm0,%rax
  mov    %rax,-0x8(%rbp)
  pxor   %xmm0,%xmm0
  ucomisd -0x8(%rbp),%xmm0
  jp     L5
  pxor   %xmm0,%xmm0
  ucomisd -0x8(%rbp),%xmm0
  jne    L5
  mov    $0x1,%eax
  jmp    L16
L5:
  movsd  D7(%rip),%xmm0
  divsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,-0x8(%rbp)
  mov    -0x18(%rbp),%rax
  add    $0x20,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  add    $0x40,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  add    $0x38,%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x28,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mulsd  -0x8(%rbp),%xmm0
  mov    -0x20(%rbp),%rax
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%rax
  add    $0x38,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  add    $0x10,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  add    $0x40,%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x8,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x8,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%rax
  add    $0x8,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  add    $0x28,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  add    $0x10,%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x20,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x10,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%rax
  add    $0x28,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  add    $0x30,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  add    $0x18,%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x40,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x18,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%rax
  add    $0x40,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  add    $0x10,%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x30,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x20,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%rax
  add    $0x10,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  add    $0x18,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x28,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x28,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%rax
  add    $0x18,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  add    $0x38,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  add    $0x30,%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x20,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x30,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%rax
  add    $0x8,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  add    $0x30,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x38,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x38,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%rax
  add    $0x20,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  mov    -0x18(%rbp),%rax
  add    $0x18,%rax
  movsd  (%rax),%xmm2
  mov    -0x18(%rbp),%rax
  add    $0x8,%rax
  movsd  (%rax),%xmm1
  mulsd  %xmm2,%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x20(%rbp),%rax
  add    $0x40,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    $0x0,%eax
L16:
  leave
  ret
```

tool_calls: name: unpack_data
arguments: tag: D7
type_infered: f64

tool: D7: 1

assistant: ```c
int inverse_mat3(double m[9], double r[9]) {
  double d;
  d = determinant3x3(m);
  if (fabs(d) == 0.0) {
    return 1;
  }
  d = 1.0 / d;
  r[0] = d * (m[4] * m[8] - m[7] * m[5]);
  r[1] = d * (m[7] * m[2] - m[8] * m[1]);
  r[2] = d * (m[1] * m[5] - m[2] * m[4]);
  r[3] = d * (m[5] * m[6] - m[3] * m[8]);
  r[4] = d * (m[8] * m[0] - m[2] * m[6]);
  r[5] = d * (m[2] * m[3] - m[0] * m[5]);
  r[6] = d * (m[3] * m[7] - m[6] * m[4]);
  r[7] = d * (m[1] * m[6] - m[0] * m[7]);
  r[8] = d * (m[0] * m[4] - m[3] * m[1]);
  return 0;
}
```