user: What would the C source look like for the assembly code provided here?

```asm
<matrix_chain_order>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x28(%rbp)
  mov    %rsi,-0x30(%rbp)
  mov    %rdx,-0x38(%rbp)
  movl   $0x6,-0xc(%rbp)
  movl   $0x1,-0x18(%rbp)
  jmp    L73
L9:
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x3,%rax
  sub    %rdx,%rax
  shl    $0x2,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rax,%rdx
  mov    -0x18(%rbp),%eax
  cltq
  movl   $0x0,(%rdx,%rax,4)
  addl   $0x1,-0x18(%rbp)
L73:
  mov    -0x18(%rbp),%eax
  cmp    -0xc(%rbp),%eax
  jle    L9
  movl   $0x2,-0x10(%rbp)
  jmp    L6
L7:
  movl   $0x1,-0x18(%rbp)
  jmp    L30
L44:
  mov    -0x18(%rbp),%edx
  mov    -0x10(%rbp),%eax
  add    %edx,%eax
  sub    $0x1,%eax
  mov    %eax,-0x8(%rbp)
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x3,%rax
  sub    %rdx,%rax
  shl    $0x2,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  cltq
  movl   $0xffff,(%rdx,%rax,4)
  mov    -0x18(%rbp),%eax
  mov    %eax,-0x14(%rbp)
  jmp    L79
L81:
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x3,%rax
  sub    %rdx,%rax
  shl    $0x2,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rax,%rdx
  mov    -0x14(%rbp),%eax
  cltq
  mov    (%rdx,%rax,4),%ecx
  mov    -0x14(%rbp),%eax
  cltq
  lea    0x1(%rax),%rdx
  mov    %rdx,%rax
  shl    $0x3,%rax
  sub    %rdx,%rax
  shl    $0x2,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  cltq
  mov    (%rdx,%rax,4),%eax
  add    %eax,%ecx
  mov    -0x18(%rbp),%eax
  cltq
  shl    $0x2,%rax
  lea    -0x4(%rax),%rdx
  mov    -0x28(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%edx
  mov    -0x14(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rsi
  mov    -0x28(%rbp),%rax
  add    %rsi,%rax
  mov    (%rax),%eax
  imul   %eax,%edx
  mov    -0x8(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rsi
  mov    -0x28(%rbp),%rax
  add    %rsi,%rax
  mov    (%rax),%eax
  imul   %edx,%eax
  add    %ecx,%eax
  mov    %eax,-0x4(%rbp)
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x3,%rax
  sub    %rdx,%rax
  shl    $0x2,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  cltq
  mov    (%rdx,%rax,4),%eax
  cmp    %eax,-0x4(%rbp)
  jge    L48
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x3,%rax
  sub    %rdx,%rax
  shl    $0x2,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  lea    (%rdx,%rax,1),%rcx
  mov    -0x8(%rbp),%eax
  cltq
  mov    -0x4(%rbp),%edx
  mov    %edx,(%rcx,%rax,4)
  mov    -0x18(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x3,%rax
  sub    %rdx,%rax
  shl    $0x2,%rax
  mov    %rax,%rdx
  mov    -0x38(%rbp),%rax
  lea    (%rdx,%rax,1),%rcx
  mov    -0x8(%rbp),%eax
  cltq
  mov    -0x14(%rbp),%edx
  mov    %edx,(%rcx,%rax,4)
L48:
  addl   $0x1,-0x14(%rbp)
L79:
  mov    -0x8(%rbp),%eax
  cmp    -0x14(%rbp),%eax
  jg     L81
  addl   $0x1,-0x18(%rbp)
L30:
  mov    -0xc(%rbp),%eax
  sub    -0x10(%rbp),%eax
  add    $0x1,%eax
  cmp    %eax,-0x18(%rbp)
  jle    L44
  addl   $0x1,-0x10(%rbp)
L6:
  mov    -0x10(%rbp),%eax
  cmp    -0xc(%rbp),%eax
  jle    L7
  nop
  nop
  pop    %rbp
  ret
```

assistant: ```c
void matrix_chain_order(int *p, int m[7][7], int s[7][7]) {
  int i, j, k, l, n, q;
  n = sizeof(p) / sizeof(char) - 2;
  for (i = 1; i <= n; i++)
    m[i][i] = 0;
  for (l = 2; l <= n; l++) {
    for (i = 1; i <= n - l + 1; i++) {
      j = i + l - 1;
      m[i][j] = 65535;
      for (k = i; k <= j - 1; k++) {
        q = m[i][k] + m[k + 1][j] + p[i - 1] * p[k] * p[j];
        if (q < m[i][j]) {
          m[i][j] = q;
          s[i][j] = k;
        }
      }
    }
  }
}
```