user: Translate the below assembly code into C programming language:

```asm
<fromroot_transtable>:
  endbr64
  push   %r15
  mov    %rdi,%r10
  xor    %eax,%eax
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %ecx,%ebp
  push   %rbx
  sub    $0x28,%rsp
  mov    0x68(%rsp),%rbx
  mov    %rsi,0x18(%rsp)
  mov    %r9,0x8(%rsp)
  lea    0x8(%rbx),%rdi
  mov    %rbx,%rcx
  movq   $0x0,(%rbx)
  movq   $0x0,0x118(%rbx)
  and    $0xfffffffffffffff8,%rdi
  sub    %rdi,%rcx
  add    $0x120,%ecx
  shr    $0x3,%ecx
  rep stos %rax,%es:(%rdi)
  test   %edx,%edx
  jle    L28
  movslq %r8d,%rax
  mov    %r8d,%r12d
  xor    %r15d,%r15d
  lea    (%r10,%rax,8),%r13
  movslq %ebp,%rax
  lea    (%r10,%rax,8),%r14
  movslq %edx,%rax
  shl    $0x2,%rax
  mov    %rax,0x10(%rsp)
  jmp    L97
  xchg   %ax,%ax
L34:
  test   %edx,%edx
  jne    L13
  mov    0x18(%rsp),%rdi
  cltq
  pxor   %xmm0,%xmm0
  cvtss2sd (%rdi,%r15,1),%xmm0
  addsd  (%rbx,%rax,8),%xmm0
  movsd  %xmm0,(%rbx,%rax,8)
L53:
  add    $0x4,%r15
  cmp    %r15,0x10(%rsp)
  je     L28
L97:
  mov    0x0(%r13),%rax
  mov    %r12d,%esi
  mov    %ebp,%edi
  mov    (%rax,%r15,1),%ecx
  mov    (%r14),%rax
  mov    (%rax,%r15,1),%edx
  call   <assign_cell@plt>
  mov    0x8(%rsp),%rsi
  mov    0x60(%rsp),%rdi
  mov    (%rsi,%r15,1),%ecx
  mov    (%rdi,%r15,1),%edx
  test   %ecx,%ecx
  je     L34
  jle    L13
  mov    0x18(%rsp),%rsi
  movsd  0x20(%rbx),%xmm0
  pxor   %xmm1,%xmm1
  sub    $0x1,%ecx
  movss  (%rsi,%r15,1),%xmm2
  cvtss2sd %xmm2,%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,0x20(%rbx)
  pxor   %xmm0,%xmm0
  cvtsi2ss %ecx,%xmm0
  mulss  %xmm2,%xmm0
  cvtss2sd %xmm0,%xmm0
  addsd  0xe0(%rbx),%xmm0
  movsd  %xmm0,0xe0(%rbx)
  test   %edx,%edx
  jle    L56
  movsd  0xe8(%rbx),%xmm0
  addsd  %xmm1,%xmm0
  movsd  %xmm0,0xe8(%rbx)
L95:
  sub    $0x1,%edx
  pxor   %xmm0,%xmm0
  cltq
  add    $0x4,%r15
  cvtsi2ss %edx,%xmm0
  mulss  %xmm2,%xmm0
  cvtss2sd %xmm0,%xmm0
  addsd  0x118(%rbx),%xmm0
  movsd  %xmm0,0x118(%rbx)
  addsd  0xf0(%rbx,%rax,8),%xmm1
  movsd  %xmm1,0xf0(%rbx,%rax,8)
  cmp    %r15,0x10(%rsp)
  jne    L97
L28:
  add    $0x28,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L13:
  test   %edx,%edx
  jle    L53
  mov    0x18(%rsp),%rsi
  movsd  0x28(%rbx),%xmm0
  pxor   %xmm1,%xmm1
  movss  (%rsi,%r15,1),%xmm2
  cvtss2sd %xmm2,%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,0x28(%rbx)
  jmp    L95
  xchg   %ax,%ax
L56:
  cltq
  addsd  0xc0(%rbx,%rax,8),%xmm1
  movsd  %xmm1,0xc0(%rbx,%rax,8)
  jmp    L53
```

assistant: ```c
void fromroot_transtable(int **aseqsT, float *weights, int nseq, int i2, int j2, int *accum_insl, int *accum_insr, double trans[6][6]) {
  int fy, ty;
  int idx;
  for (fy = 0; fy < 6; fy++)
    for (ty = 0; ty < 6; ty++)
      trans[fy][ty] = 0.0;
  for (idx = 0; idx < nseq; idx++) {
    ty = assign_cell(i2, j2, aseqsT[i2][idx], aseqsT[j2][idx]);
    if (accum_insl[idx] == 0 && accum_insr[idx] == 0) {
      trans[0][ty] += weights[idx];
    } else if (accum_insl[idx] > 0) {
      trans[0][4] += weights[idx];
      trans[4][4] += (accum_insl[idx] - 1) * weights[idx];
      if (accum_insr[idx] > 0) {
        trans[4][5] += weights[idx];
        trans[5][5] += (accum_insr[idx] - 1) * weights[idx];
        trans[5][ty] += weights[idx];
      } else {
        trans[4][ty] += weights[idx];
      }
    } else if (accum_insr[idx] > 0) {
      trans[0][5] += weights[idx];
      trans[5][5] += (accum_insr[idx] - 1) * weights[idx];
      trans[5][ty] += weights[idx];
    }
  }
}
```