user: Demonstrate the C code that generates the assembly output below:

```asm
<convert_COO_SSS>:
  endbr64
  push   %r15
  push   %r14
  mov    %r8,%r14
  push   %r13
  movslq %edi,%r13
  push   %r12
  mov    %r13,%r12
  push   %rbp
  mov    %rcx,%rbp
  lea    0x0(,%r13,4),%rcx
  push   %rbx
  mov    %rdx,%rbx
  sub    $0x48,%rsp
  mov    0x80(%rsp),%rdi
  mov    0x90(%rsp),%rdx
  mov    %rcx,0x30(%rsp)
  mov    %esi,0x10(%rsp)
  mov    %rdi,0x18(%rsp)
  mov    0x88(%rsp),%rdi
  mov    %rdx,0x38(%rsp)
  mov    %rdi,0x20(%rsp)
  mov    %rcx,%rdi
  mov    %r9,0x8(%rsp)
  mov    %r13,0x28(%rsp)
  shl    $0x3,%r13
  call   <malloc@plt>
  mov    %rax,%rdi
  mov    %rax,%r15
  xor    %eax,%eax
  call   <assert@plt>
  mov    %r13,%rdi
  call   <malloc@plt>
  mov    0x38(%rsp),%rdx
  test   %r12d,%r12d
  mov    0x30(%rsp),%rcx
  mov    %rax,%r11
  mov    %rax,(%rdx)
  jle    L80
  mov    %rcx,%rdx
  xor    %esi,%esi
  mov    %r15,%rdi
  mov    %rax,0x38(%rsp)
  call   <memset@plt>
  mov    0x38(%rsp),%rdi
  mov    %r13,%rdx
  xor    %esi,%esi
  call   <memset@plt>
  mov    0x10(%rsp),%edx
  mov    0x30(%rsp),%rcx
  mov    %rax,%r11
  test   %edx,%edx
  jle    L21
L81:
  movslq 0x10(%rsp),%r13
  xor    %eax,%eax
  xor    %esi,%esi
  jmp    L116
  nopl   (%rax)
L83:
  jge    L87
  mov    %edi,(%rbx,%rax,4)
  mov    %edx,0x0(%rbp,%rax,4)
  movslq (%rbx,%rax,4),%rdx
L87:
  lea    (%r15,%rdx,4),%rdx
  add    $0x1,%esi
  mov    (%rdx),%edi
  mov    %r8d,(%rdx)
  mov    %edi,(%rbx,%rax,4)
  add    $0x1,%rax
  cmp    %rax,%r13
  je     L70
L116:
  movslq (%rbx,%rax,4),%rdx
  mov    0x0(%rbp,%rax,4),%edi
  mov    %eax,%r8d
  cmp    %edi,%edx
  jne    L83
  movsd  (%r14,%rax,8),%xmm0
  add    $0x1,%rax
  movsd  %xmm0,(%r11,%rdx,8)
  cmp    %rax,%r13
  jne    L116
L70:
  lea    0x4(%rcx),%rdi
  movslq %esi,%r13
  mov    %esi,0x30(%rsp)
  call   <malloc@plt>
  mov    0x8(%rsp),%rsi
  mov    %r13,0x10(%rsp)
  lea    0x0(,%r13,8),%rdi
  mov    %rax,(%rsi)
  call   <malloc@plt>
  mov    0x10(%rsp),%rdx
  mov    %rax,%r13
  mov    0x20(%rsp),%rax
  lea    0x0(,%rdx,4),%rdi
  mov    %r13,(%rax)
  call   <malloc@plt>
  test   %r12d,%r12d
  mov    0x30(%rsp),%esi
  mov    %rax,%rdi
  mov    0x18(%rsp),%rax
  mov    %rdi,(%rax)
  jle    L88
L10:
  mov    0x8(%rsp),%rax
  mov    %r12d,%r12d
  xor    %r10d,%r10d
  xor    %ecx,%ecx
  mov    (%rax),%r11
  nopl   0x0(%rax,%rax,1)
L79:
  mov    %ecx,(%r11,%r10,4)
  movslq (%r15,%r10,4),%rax
  test   %eax,%eax
  je     L72
  add    $0x1,%ecx
  movslq %ecx,%rdx
  nopw   0x0(%rax,%rax,1)
L63:
  mov    0x0(%rbp,%rax,4),%ecx
  movsd  (%r14,%rax,8),%xmm0
  movslq (%rbx,%rax,4),%rax
  mov    %ecx,-0x4(%rdi,%rdx,4)
  mov    %edx,%ecx
  movsd  %xmm0,-0x8(%r13,%rdx,8)
  add    $0x1,%rdx
  test   %eax,%eax
  jne    L63
L72:
  add    $0x1,%r10
  cmp    %r12,%r10
  jne    L79
L109:
  mov    0x28(%rsp),%rax
  xor    %edi,%edi
  cmp    %ecx,%esi
  sete   %dil
  mov    %ecx,(%r11,%rax,4)
  xor    %eax,%eax
  call   <assert@plt>
  add    $0x48,%rsp
  mov    %r15,%rdi
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1080 <free@plt>
L80:
  mov    0x10(%rsp),%eax
  test   %eax,%eax
  jg     L81
  lea    0x4(%rcx),%rdi
  call   <malloc@plt>
  mov    0x8(%rsp),%rsi
  xor    %edi,%edi
  mov    %rax,(%rsi)
  call   <malloc@plt>
  mov    0x20(%rsp),%rsi
  xor    %edi,%edi
  mov    %rax,(%rsi)
  call   <malloc@plt>
  mov    0x18(%rsp),%rsi
  mov    %rax,(%rsi)
  xor    %esi,%esi
L88:
  mov    0x8(%rsp),%rax
  xor    %ecx,%ecx
  mov    (%rax),%r11
  jmp    L109
L21:
  lea    0x4(%rcx),%rdi
  call   <malloc@plt>
  mov    0x8(%rsp),%rsi
  xor    %edi,%edi
  mov    %rax,(%rsi)
  call   <malloc@plt>
  xor    %edi,%edi
  mov    %rax,%r13
  mov    0x20(%rsp),%rax
  mov    %r13,(%rax)
  call   <malloc@plt>
  xor    %esi,%esi
  mov    %rax,%rdi
  mov    0x18(%rsp),%rax
  mov    %rdi,(%rax)
  jmp    L10
```

assistant: ```c
void convert_COO_SSS(int n, int nz, int *i_coo, int *j_coo, double *v_coo, int **ia, int **ja, double **va, double **da) {
  int i, k, l, t, nnz;
  int *root;
  root = (int *)malloc(n * sizeof(int));
  assert(root);
  (*da) = (double *)malloc(n * sizeof(double));
  for (i = 0; i < n; i++) {
    root[i] = 0;
    (*da)[i] = 0.0;
  }
  nnz = 0;
  for (k = 0; k < nz; k++) {
    if (i_coo[k] == j_coo[k])
      (*da)[i_coo[k]] = v_coo[k];
    else {
      if (i_coo[k] < j_coo[k]) {
        t = i_coo[k];
        i_coo[k] = j_coo[k];
        j_coo[k] = t;
      }
      i = i_coo[k];
      i_coo[k] = root[i];
      root[i] = k;
      nnz++;
    }
  }
  (*ia) = (int *)malloc((n + 1) * sizeof(int));
  (*va) = (double *)malloc((nnz * sizeof(double)));
  (*ja) = (int *)malloc(nnz * sizeof(int));
  k = 0;
  for (i = 0; i < n; i++) {
    (*ia)[i] = k;
    l = root[i];
    while (l != 0) {
      (*ja)[k] = j_coo[l];
      (*va)[k] = v_coo[l];
      k++;
      l = i_coo[l];
    }
  }
  (*ia)[n] = k;
  assert(k == nnz);
  free(root);
}
```