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

```asm
<bpstep_par>:
  endbr64
  push   %r15
  mov    %rdx,%r15
  push   %r14
  mov    %rdi,%r14
  push   %r13
  push   %r12
  mov    %rsi,%r12
  push   %rbp
  push   %rbx
  mov    %r8,%rbx
  sub    $0x138,%rsp
  mov    0x170(%rsp),%rax
  mov    %r9,0x20(%rsp)
  lea    0x100(%rsp),%r11
  lea    0xe0(%rsp),%rbp
  mov    %rcx,0x48(%rsp)
  mov    %r11,%rsi
  mov    %rax,0x28(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0x128(%rsp)
  mov    0x8(%rdi),%rax
  movsd  0x18(%rax),%xmm0
  mov    0x8(%rdx),%rax
  movsd  %xmm0,0xe8(%rsp)
  movsd  0x18(%rax),%xmm0
  mov    0x10(%rdi),%rax
  movsd  %xmm0,0x108(%rsp)
  movsd  0x18(%rax),%xmm0
  mov    0x10(%rdx),%rax
  movsd  %xmm0,0xf0(%rsp)
  movsd  0x18(%rax),%xmm0
  mov    0x18(%rdi),%rax
  mov    %rbp,%rdi
  movsd  %xmm0,0x110(%rsp)
  movsd  0x18(%rax),%xmm0
  mov    0x18(%rdx),%rax
  movsd  %xmm0,0xf8(%rsp)
  movsd  0x18(%rax),%xmm0
  lea    0x60(%rsp),%rax
  mov    %rax,%rdx
  mov    %rax,(%rsp)
  movsd  %xmm0,0x118(%rsp)
  mov    %r11,0x8(%rsp)
  call   <cross@plt>
  mov    0x8(%rsp),%r11
  mov    %rbp,%rdi
  mov    %rbp,0x30(%rsp)
  mov    %r11,%rsi
  mov    %r11,0x40(%rsp)
  call   <magang@plt>
  mov    $0x3,%ecx
  mov    $0x1,%edx
  mov    $0x3,%esi
  movapd %xmm0,%xmm6
  mov    $0x1,%edi
  movsd  %xmm0,0x8(%rsp)
  unpcklpd %xmm6,%xmm6
  movaps %xmm6,0x10(%rsp)
  call   <dmatrix@plt>
  mov    $0x3,%ecx
  mov    $0x1,%edx
  mov    $0x3,%esi
  mov    $0x1,%edi
  mov    %rax,%r13
  call   <dmatrix@plt>
  mov    $0x3,%ecx
  mov    $0x1,%edx
  mov    $0x3,%esi
  mov    $0x1,%edi
  mov    %rax,%rbp
  call   <dmatrix@plt>
  movsd  0x8(%rsp),%xmm0
  mov    (%rsp),%rdi
  mulsd  D46(%rip),%xmm0
  mov    %rax,%rsi
  mov    %rax,0x8(%rsp)
  movsd  %xmm0,0x38(%rsp)
  call   <arb_rotation@plt>
  sub    $0x8,%rsp
  mov    %r15,%rcx
  mov    $0x3,%r9d
  push   %rbp
  mov    0x18(%rsp),%r15
  mov    $0x3,%r8d
  mov    $0x3,%edx
  mov    $0x3,%esi
  mov    %r15,%rdi
  call   <multi_matrix@plt>
  movsd  0x48(%rsp),%xmm0
  mov    0x10(%rsp),%rdi
  mov    %r15,%rsi
  xorpd  D76(%rip),%xmm0
  call   <arb_rotation@plt>
  mov    %r14,%rcx
  mov    $0x3,%edx
  mov    %r15,%rdi
  mov    $0x3,%r9d
  mov    $0x3,%r8d
  mov    %r13,(%rsp)
  mov    $0x3,%esi
  call   <multi_matrix@plt>
  mov    0x8(%rbp),%rax
  mov    0x8(%r13),%rdx
  lea    0xd0(%rsp),%r14
  mov    0x50(%rsp),%rsi
  mov    0x40(%rsp),%rdi
  movsd  0x18(%rax),%xmm0
  movsd  %xmm0,0xd8(%rsp)
  movsd  0x10(%rdx),%xmm0
  mov    0x10(%r13),%rdx
  movsd  %xmm0,0xf8(%rsp)
  movsd  0x10(%rax),%xmm0
  mov    0x10(%rbp),%rax
  movsd  %xmm0,0x118(%rsp)
  movsd  0x18(%rax),%xmm0
  movsd  %xmm0,0xe0(%rsp)
  movsd  0x10(%rdx),%xmm0
  mov    0x18(%r13),%rdx
  movsd  %xmm0,0x100(%rsp)
  movsd  0x10(%rax),%xmm0
  mov    0x18(%rbp),%rax
  movsd  %xmm0,0x120(%rsp)
  movsd  0x18(%rax),%xmm0
  movsd  %xmm0,0xe8(%rsp)
  movsd  0x10(%rdx),%xmm0
  mov    %r14,%rdx
  movsd  %xmm0,0x108(%rsp)
  movsd  0x10(%rax),%xmm0
  movsd  %xmm0,0x128(%rsp)
  call   <vec_ang@plt>
  mov    $0xb4,%edi
  movsd  %xmm0,0x30(%rbx)
  call   <ddiff@plt>
  movsd  D45(%rip),%xmm6
  pop    %rax
  pop    %rdx
  mov    0x48(%rsp),%r10
  comisd %xmm0,%xmm6
  jbe    L72
  mov    0x8(%rbp),%rax
  lea    0xa0(%rsp),%r15
  movsd  0x8(%rax),%xmm0
  mov    0x10(%rbp),%rax
  movsd  %xmm0,0xa8(%rsp)
  movsd  0x8(%rax),%xmm0
  mov    0x18(%rbp),%rax
  movsd  %xmm0,0xb0(%rsp)
  movsd  0x8(%rax),%xmm0
  movsd  %xmm0,0xb8(%rsp)
L74:
  lea    0x80(%rsp),%rdx
  mov    %r14,%rsi
  mov    %r15,%rdi
  mov    %r10,0x30(%rsp)
  call   <cross@plt>
  mov    0x30(%rsp),%r10
  mov    0x28(%rsp),%rcx
  lea    0x8(%rbx),%r9
  movsd  0x8(%r12),%xmm0
  movsd  D22(%rip),%xmm1
  lea    0x18(%rbx),%r8
  addsd  0x8(%r10),%xmm0
  mov    0x20(%rsp),%rdi
  mov    0x8(%rdi),%rdx
  mov    0x10(%rdi),%rax
  mulsd  %xmm1,%xmm0
  lea    0x18(%rax),%rsi
  cmp    %rsi,%r9
  lea    0x8(%rax),%rsi
  movsd  %xmm0,0x8(%rcx)
  movsd  0x8(%r10),%xmm0
  subsd  0x8(%r12),%xmm0
  movsd  %xmm0,0xe8(%rsp)
  movsd  0x88(%rsp),%xmm0
  movsd  %xmm0,0x8(%rdx)
  movsd  0xa8(%rsp),%xmm0
  movsd  %xmm0,0x10(%rdx)
  movsd  0xc8(%rsp),%xmm0
  movsd  %xmm0,0x18(%rdx)
  movsd  0x10(%r12),%xmm0
  addsd  0x10(%r10),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,0x10(%rcx)
  movsd  0x10(%r10),%xmm0
  subsd  0x10(%r12),%xmm0
  movsd  %xmm0,0xf0(%rsp)
  movsd  0x90(%rsp),%xmm0
  movsd  %xmm0,0x8(%rax)
  movsd  0xb0(%rsp),%xmm0
  movsd  %xmm0,0x10(%rax)
  movsd  0xd0(%rsp),%xmm0
  movsd  %xmm0,0x18(%rax)
  movsd  0x18(%r12),%xmm0
  addsd  0x18(%r10),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,0x18(%rcx)
  movsd  0x18(%r10),%xmm0
  mov    0x18(%rdi),%rcx
  setae  %dil
  subsd  0x18(%r12),%xmm0
  cmp    %rsi,%r8
  setbe  %sil
  or     %esi,%edi
  lea    0x18(%rdx),%rsi
  movsd  %xmm0,0xf8(%rsp)
  cmp    %rsi,%r9
  lea    0x8(%rdx),%rsi
  movsd  0x98(%rsp),%xmm0
  setae  %r10b
  cmp    %rsi,%r8
  movsd  %xmm0,0x8(%rcx)
  setbe  %sil
  movsd  0xb8(%rsp),%xmm0
  movsd  0xe8(%rsp),%xmm3
  or     %r10d,%esi
  movsd  %xmm0,0x10(%rcx)
  movsd  0xd8(%rsp),%xmm0
  movsd  0xf0(%rsp),%xmm2
  movsd  %xmm0,0x18(%rcx)
  movsd  0xf8(%rsp),%xmm4
  test   %sil,%dil
  je     L63
  lea    0x18(%rcx),%rsi
  lea    0x8(%rcx),%rdi
  cmp    %rsi,%r9
  setae  %sil
  cmp    %rdi,%r8
  setbe  %dil
  or     %sil,%dil
  je     L63
  pxor   %xmm0,%xmm0
  movapd %xmm3,%xmm1
  movups %xmm0,0x8(%rbx)
  movupd 0x8(%rdx),%xmm7
  unpcklpd %xmm1,%xmm1
  mulpd  %xmm7,%xmm1
  addpd  %xmm0,%xmm1
  movapd %xmm2,%xmm0
  unpcklpd %xmm0,%xmm0
  movups %xmm1,0x8(%rbx)
  movupd 0x8(%rax),%xmm5
  mulpd  %xmm5,%xmm0
  addpd  %xmm1,%xmm0
  movapd %xmm4,%xmm1
  unpcklpd %xmm1,%xmm1
  movups %xmm0,0x8(%rbx)
  movupd 0x8(%rcx),%xmm7
  movq   $0x0,0x18(%rbx)
  mulpd  %xmm7,%xmm1
  addpd  %xmm1,%xmm0
  pxor   %xmm1,%xmm1
  movups %xmm0,0x8(%rbx)
  mulsd  0x18(%rdx),%xmm3
  addsd  %xmm3,%xmm1
  movsd  %xmm1,0x18(%rbx)
  mulsd  0x18(%rax),%xmm2
  movapd %xmm2,%xmm0
  addsd  %xmm1,%xmm0
  movsd  %xmm0,0x18(%rbx)
  mulsd  0x18(%rcx),%xmm4
  movapd %xmm4,%xmm1
  addsd  %xmm0,%xmm1
  movsd  %xmm1,0x18(%rbx)
L49:
  mov    (%rsp),%rdi
  mov    %r14,%rdx
  mov    %r15,%rsi
  call   <vec_ang@plt>
  call   <deg2rad@plt>
  lea    0x58(%rsp),%rdi
  lea    0x50(%rsp),%rsi
  call   <sincos@plt>
  movsd  0x58(%rsp),%xmm0
  mov    $0x3,%r8d
  mov    $0x1,%ecx
  mov    $0x3,%edx
  mov    $0x1,%esi
  mov    %r13,%rdi
  movhpd 0x50(%rsp),%xmm0
  mulpd  0x10(%rsp),%xmm0
  movups %xmm0,0x20(%rbx)
  call   <free_dmatrix@plt>
  mov    $0x3,%r8d
  mov    $0x1,%ecx
  mov    %rbp,%rdi
  mov    $0x3,%edx
  mov    $0x1,%esi
  call   <free_dmatrix@plt>
  mov    0x8(%rsp),%rdi
  mov    $0x3,%r8d
  mov    $0x1,%ecx
  mov    $0x3,%edx
  mov    $0x1,%esi
  call   <free_dmatrix@plt>
  mov    0x128(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L40
  add    $0x138,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopw   0x0(%rax,%rax,1)
L72:
  movsd  0x30(%rbx),%xmm0
  mov    $0xffffff4c,%edi
  mov    %r10,0x30(%rsp)
  call   <ddiff@plt>
  movsd  D45(%rip),%xmm5
  mov    0x30(%rsp),%r10
  comisd %xmm0,%xmm5
  jbe    L16
  mov    0x8(%rbp),%rax
  lea    0xa0(%rsp),%r15
  movsd  0x8(%rax),%xmm0
  mov    0x10(%rbp),%rax
  xorpd  D76(%rip),%xmm0
  movsd  %xmm0,0xa8(%rsp)
  movsd  0x8(%rax),%xmm0
  mov    0x18(%rbp),%rax
  xorpd  D76(%rip),%xmm0
  movsd  %xmm0,0xb0(%rsp)
  movsd  0x8(%rax),%xmm0
  xorpd  D76(%rip),%xmm0
  movsd  %xmm0,0xb8(%rsp)
  jmp    L74
  nopw   0x0(%rax,%rax,1)
L16:
  movupd 0xe8(%rsp),%xmm0
  lea    0xa0(%rsp),%r15
  mov    %r10,0x30(%rsp)
  movupd 0x108(%rsp),%xmm6
  mov    %r15,%rdi
  addpd  %xmm6,%xmm0
  movups %xmm0,0xa8(%rsp)
  movsd  0xf8(%rsp),%xmm0
  addsd  0x118(%rsp),%xmm0
  movsd  %xmm0,0xb8(%rsp)
  call   <vec_norm@plt>
  mov    0x30(%rsp),%r10
  jmp    L74
L63:
  movq   $0x0,0x8(%rbx)
  movsd  0x8(%rdx),%xmm1
  pxor   %xmm5,%xmm5
  mulsd  %xmm3,%xmm1
  addsd  %xmm5,%xmm1
  movsd  %xmm1,0x8(%rbx)
  movsd  0x8(%rax),%xmm0
  mulsd  %xmm2,%xmm0
  addsd  %xmm1,%xmm0
  movsd  %xmm0,0x8(%rbx)
  movsd  0x8(%rcx),%xmm1
  movq   $0x0,0x10(%rbx)
  mulsd  %xmm4,%xmm1
  addsd  %xmm0,%xmm1
  movsd  %xmm1,0x8(%rbx)
  movsd  0x10(%rdx),%xmm1
  mulsd  %xmm3,%xmm1
  addsd  %xmm5,%xmm1
  movsd  %xmm1,0x10(%rbx)
  movsd  0x10(%rax),%xmm0
  mulsd  %xmm2,%xmm0
  addsd  %xmm1,%xmm0
  movsd  %xmm0,0x10(%rbx)
  movsd  0x10(%rcx),%xmm1
  movq   $0x0,0x18(%rbx)
  mulsd  %xmm4,%xmm1
  addsd  %xmm0,%xmm1
  movsd  %xmm1,0x10(%rbx)
  mulsd  0x18(%rdx),%xmm3
  addsd  %xmm5,%xmm3
  movsd  %xmm3,0x18(%rbx)
  mulsd  0x18(%rax),%xmm2
  addsd  %xmm3,%xmm2
  movsd  %xmm2,0x18(%rbx)
  mulsd  0x18(%rcx),%xmm4
  movapd %xmm4,%xmm1
  addsd  %xmm2,%xmm1
  movsd  %xmm1,0x18(%rbx)
  jmp    L49
L40:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: tag: D46
data_type: f32[2]
name: disassemble_data
arguments: tag: D76
data_type: f32[4]
name: disassemble_data
arguments: tag: D45
data_type: byte[8]
name: disassemble_data
arguments: tag: D22
data_type: f64

tool: {"D46": [0.0,-1.75]}

tool: {"D76": [0.0,-0.0,0.0,0.0]}

tool: {"D45": [0x48,0xaf,0xbc,0x9a,0xf2,0xd7,0x7a,0x3e]}

tool: D22: 0.5

assistant: ```c
void bpstep_par(double **rot1, double *org1, double **rot2, double *org2, double *pars, double **mst_orien, double *mst_org) {
  double phi, rolltilt;
  double hinge[4], mstx[4], msty[4], mstz[4], t1[4], t2[4];
  double **para_bp1, **para_bp2, **temp;
  long i, j;
  for (i = 1; i <= 3; i++) {
    t1[i] = rot1[i][3];
    t2[i] = rot2[i][3];
  }
  cross(t1, t2, hinge);
  rolltilt = magang(t1, t2);
  para_bp1 = dmatrix(1, 3, 1, 3);
  para_bp2 = dmatrix(1, 3, 1, 3);
  temp = dmatrix(1, 3, 1, 3);
  arb_rotation(hinge, -0.5 * rolltilt, temp);
  multi_matrix(temp, 3, 3, rot2, 3, 3, para_bp2);
  arb_rotation(hinge, 0.5 * rolltilt, temp);
  multi_matrix(temp, 3, 3, rot1, 3, 3, para_bp1);
  for (i = 1; i <= 3; i++) {
    mstz[i] = para_bp2[i][3];
    t1[i] = para_bp1[i][2];
    t2[i] = para_bp2[i][2];
  }
  pars[6] = vec_ang(t1, t2, mstz);
  if (ddiff(pars[6], 180) < 1.0e-7)
    for (i = 1; i <= 3; i++)
      msty[i] = para_bp2[i][1];
  else if (ddiff(pars[6], -180) < 1.0e-7)
    for (i = 1; i <= 3; i++)
      msty[i] = -para_bp2[i][1];
  else {
    for (i = 1; i <= 3; i++)
      msty[i] = t1[i] + t2[i];
    vec_norm(msty);
  }
  cross(msty, mstz, mstx);
  for (i = 1; i <= 3; i++) {
    mst_org[i] = 0.5 * (org1[i] + org2[i]);
    t1[i] = org2[i] - org1[i];
    mst_orien[i][1] = mstx[i];
    mst_orien[i][2] = msty[i];
    mst_orien[i][3] = mstz[i];
  }
  for (i = 1; i <= 3; i++) {
    pars[i] = 0.0;
    for (j = 1; j <= 3; j++)
      pars[i] += t1[j] * mst_orien[j][i];
  }
  phi = deg2rad(vec_ang(hinge, msty, mstz));
  pars[5] = rolltilt * cos(phi);
  pars[4] = rolltilt * sin(phi);
  free_dmatrix(para_bp1, 1, 3, 1, 3);
  free_dmatrix(para_bp2, 1, 3, 1, 3);
  free_dmatrix(temp, 1, 3, 1, 3);
}
```