user: Please show me the C implementation that matches the assembly code listed below:

```asm
<luinv>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %edi,-0x24(%rbp)
  mov    %rsi,-0x30(%rbp)
  mov    %rdx,-0x38(%rbp)
  mov    %rcx,-0x40(%rbp)
  movl   $0x0,-0x18(%rbp)
  jmp    L76
L23:
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x8(%rbp)
  mov    -0x18(%rbp),%eax
  sub    -0x24(%rbp),%eax
  mov    %eax,-0x10(%rbp)
  movl   $0x0,-0x14(%rbp)
  jmp    L64
L11:
  mov    -0x24(%rbp),%eax
  add    %eax,-0x10(%rbp)
  mov    -0x10(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  mov    -0x14(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm0,%xmm1
  movsd  -0x8(%rbp),%xmm0
  subsd  %xmm1,%xmm0
  movsd  %xmm0,-0x8(%rbp)
  addl   $0x1,-0x14(%rbp)
L64:
  mov    -0x14(%rbp),%eax
  cmp    -0x18(%rbp),%eax
  jl     L11
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  movsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x18(%rbp)
L76:
  mov    -0x18(%rbp),%eax
  cmp    -0x24(%rbp),%eax
  jl     L23
  mov    -0x18(%rbp),%eax
  imul   -0x24(%rbp),%eax
  mov    %eax,-0xc(%rbp)
  mov    -0x24(%rbp),%eax
  sub    $0x1,%eax
  mov    %eax,-0x18(%rbp)
  jmp    L2
L73:
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x8(%rbp)
  mov    -0x24(%rbp),%eax
  sub    %eax,-0xc(%rbp)
  mov    -0x18(%rbp),%edx
  mov    -0xc(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x10(%rbp)
  mov    -0x18(%rbp),%eax
  add    $0x1,%eax
  mov    %eax,-0x14(%rbp)
  jmp    L9
L26:
  mov    -0x24(%rbp),%eax
  add    %eax,-0x10(%rbp)
  mov    -0x10(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  mov    -0x14(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm0,%xmm1
  movsd  -0x8(%rbp),%xmm0
  subsd  %xmm1,%xmm0
  movsd  %xmm0,-0x8(%rbp)
  addl   $0x1,-0x14(%rbp)
L9:
  mov    -0x14(%rbp),%eax
  cmp    -0x24(%rbp),%eax
  jl     L26
  mov    -0xc(%rbp),%edx
  mov    -0x18(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  mulsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  subl   $0x1,-0x18(%rbp)
L2:
  cmpl   $0x0,-0x18(%rbp)
  jns    L73
  nop
  nop
  pop    %rbp
  ret
```

assistant: ```c
void luinv(int n, double *a, double *x, double *y) {
  int i, j, bsA, bsB;
  double sum;
  for (i = 0; i < n; i++) {
    sum = x[i];
    bsA = i - n;
    for (j = 0; j < i; j++) {
      bsA += n;
      sum -= a[bsA] * y[j];
    }
    y[i] = sum;
  }
  bsB = i * n;
  for (i = n - 1; i >= 0; i--) {
    sum = y[i];
    bsB -= n;
    bsA = i + bsB;
    for (j = i + 1; j < n; j++) {
      bsA += n;
      sum -= a[bsA] * y[j];
    }
    y[i] = sum * a[bsB + i];
  }
}
```