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

```asm
<RotToAxisAng>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x50,%rsp
  mov    %rdi,-0x38(%rbp)
  mov    %rsi,-0x40(%rbp)
  mov    %rdx,-0x48(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movq   $0x0,-0x20(%rbp)
  movq   $0x0,-0x18(%rbp)
  movq   $0x0,-0x10(%rbp)
  mov    -0x38(%rbp),%rax
  movsd  (%rax),%xmm1
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  0x8(%rax),%xmm0
  addsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  0x10(%rax),%xmm0
  addsd  %xmm1,%xmm0
  movsd  D263(%rip),%xmm1
  subsd  %xmm1,%xmm0
  movsd  D33(%rip),%xmm1
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x30(%rbp)
  movsd  -0x30(%rbp),%xmm0
  movsd  D263(%rip),%xmm1
  subsd  %xmm1,%xmm0
  movq   D213(%rip),%xmm1
  andpd  %xmm0,%xmm1
  movsd  D237(%rip),%xmm0
  comisd %xmm1,%xmm0
  jbe    L28
  mov    -0x40(%rbp),%rax
  mov    $0x18,%edx
  mov    $0x0,%esi
  mov    %rax,%rdi
  call   <memset@plt>
  mov    -0x48(%rbp),%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  jmp    L58
L28:
  movsd  D77(%rip),%xmm0
  comisd -0x30(%rbp),%xmm0
  jb     L78
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  0x10(%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  comisd D237(%rip),%xmm0
  jb     L65
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  0x10(%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  movsd  0x10(%rax),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x20(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  0x10(%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  0x10(%rax),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x18(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  0x10(%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  0x10(%rax),%xmm2
  movsd  D263(%rip),%xmm0
  addsd  %xmm2,%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x10(%rbp)
  jmp    L2
L65:
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  0x8(%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  comisd D237(%rip),%xmm0
  jb     L22
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  0x8(%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  movsd  0x8(%rax),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x20(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  0x8(%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  0x8(%rax),%xmm2
  movsd  D263(%rip),%xmm0
  addsd  %xmm2,%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x18(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  0x8(%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  0x8(%rax),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x10(%rbp)
  jmp    L2
L22:
  mov    -0x38(%rbp),%rax
  movsd  (%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  movsd  (%rax),%xmm2
  movsd  D263(%rip),%xmm0
  addsd  %xmm2,%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x20(%rbp)
  mov    -0x38(%rbp),%rax
  movsd  (%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x18(%rbp)
  mov    -0x38(%rbp),%rax
  movsd  (%rax),%xmm1
  movsd  D263(%rip),%xmm0
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  movsd  D263(%rip),%xmm1
  divsd  %xmm0,%xmm1
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,-0x10(%rbp)
L2:
  movsd  -0x20(%rbp),%xmm0
  mov    -0x40(%rbp),%rax
  movsd  %xmm0,(%rax)
  mov    -0x40(%rbp),%rax
  add    $0x8,%rax
  movsd  -0x18(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x40(%rbp),%rax
  add    $0x10,%rax
  movsd  -0x10(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x48(%rbp),%rax
  movsd  D272(%rip),%xmm0
  movsd  %xmm0,(%rax)
  jmp    L58
L78:
  mov    -0x30(%rbp),%rax
  movq   %rax,%xmm0
  call   <acos@plt>
  movq   %xmm0,%rax
  mov    -0x48(%rbp),%rdx
  mov    %rax,(%rdx)
  mov    -0x48(%rbp),%rax
  mov    (%rax),%rax
  movq   %rax,%xmm0
  call   <sin@plt>
  addsd  %xmm0,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  0x8(%rax),%xmm0
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  0x10(%rax),%xmm1
  subsd  %xmm1,%xmm0
  divsd  -0x28(%rbp),%xmm0
  mov    -0x40(%rbp),%rax
  movsd  %xmm0,(%rax)
  mov    -0x38(%rbp),%rax
  movsd  0x10(%rax),%xmm0
  mov    -0x38(%rbp),%rax
  add    $0x30,%rax
  movsd  (%rax),%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x40(%rbp),%rax
  add    $0x8,%rax
  divsd  -0x28(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x38(%rbp),%rax
  add    $0x18,%rax
  movsd  (%rax),%xmm0
  mov    -0x38(%rbp),%rax
  movsd  0x8(%rax),%xmm1
  subsd  %xmm1,%xmm0
  mov    -0x40(%rbp),%rax
  add    $0x10,%rax
  divsd  -0x28(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  nop
L58:
  mov    -0x8(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L71
  call   <__stack_chk_fail@plt>
L71:
  leave
  ret
```

tool_calls: name: parse_data
arguments: data_label: D263
type: f64
name: parse_data
arguments: data_label: D33
type: f64
name: parse_data
arguments: data_label: D213
type: qword
name: parse_data
arguments: data_label: D237
type: byte[16]
name: parse_data
arguments: data_label: D77
type: f32[2]
name: parse_data
arguments: data_label: D272
type: f64

tool: D263: 1

tool: D33: 2

tool: D213: 9223372036854775807

tool: {"D237": [0x8d,0xed,0xb5,0xa0,0xf7,0xc6,0xb0,0x3e,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xbf]}

tool: {"D77": [0.0,-1.875]}

tool: D272: 3.141592653589793

assistant: ```c
void RotToAxisAng(double R[3][3], double omghat[3], double *theta) {
  double tmp;
  double omg[3] = {0};
  double acosinput = (R[0][0] + R[1][1] + R[2][2] - 1.0) / 2.0;
  if (fabs(acosinput - 1.0) < 1.0E-6) {
    memset(omghat, 0, 3 * sizeof(double));
    *theta = 0.0;
  } else if (acosinput <= -1.0) {
    if ((1.0 + R[2][2]) >= 1.0E-6) {
      omg[0] = 1.0 / sqrt(2 * (1.0 + R[2][2])) * R[0][2];
      omg[1] = 1.0 / sqrt(2 * (1.0 + R[2][2])) * R[1][2];
      omg[2] = 1.0 / sqrt(2 * (1.0 + R[2][2])) * (1.0 + R[2][2]);
    } else if ((1.0 + R[1][1] >= 1.0E-6)) {
      omg[0] = 1.0 / sqrt(2 * (1.0 + R[1][1])) * R[0][1];
      omg[1] = 1.0 / sqrt(2 * (1.0 + R[1][1])) * (1.0 + R[1][1]);
      omg[2] = 1.0 / sqrt(2 * (1.0 + R[1][1])) * R[2][1];
    } else {
      omg[0] = 1.0 / sqrt(2 * (1.0 + R[0][0])) * (1.0 + R[0][0]);
      omg[1] = 1.0 / sqrt(2 * (1.0 + R[0][0])) * R[1][0];
      omg[2] = 1.0 / sqrt(2 * (1.0 + R[0][0])) * R[2][0];
    }
    omghat[0] = omg[0];
    omghat[1] = omg[1];
    omghat[2] = omg[2];
    *theta = 3.14159265358979323846;
  } else {
    *theta = acos(acosinput);
    tmp = 2.0 * sin(*theta);
    omghat[0] = (R[2][1] - R[1][2]) / tmp;
    omghat[1] = (R[0][2] - R[2][0]) / tmp;
    omghat[2] = (R[1][0] - R[0][1]) / tmp;
  }
  return;
}
```