user: 请从给定的汇编指令推导出C源代码:

```asm
<qr_house>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  mov    %rdi,%r13
  push   %r12
  mov    %edx,%r12d
  push   %rbp
  push   %rbx
  sub    $0xb8,%rsp
  mov    %esi,0x28(%rsp)
  mov    %rcx,0x70(%rsp)
  cmp    %edx,%esi
  jl     L32
L107:
  mov    0x28(%rsp),%r14d
  movslq %r12d,%rbx
  movslq %r14d,%r15
  mov    %r15,%rbp
  shl    $0x3,%ebp
  mov    %ebp,%edi
  call   <malloc@plt>
  mov    %ebp,%edi
  mov    %r14d,%ebp
  mov    %rax,0x40(%rsp)
  call   <malloc@plt>
  mov    %r14d,%edi
  imul   %r12d,%edi
  mov    %rax,0x38(%rsp)
  shl    $0x3,%edi
  call   <malloc@plt>
  mov    %ebp,%edi
  imul   %ebp,%edi
  mov    %rax,%r14
  shl    $0x3,%edi
  call   <malloc@plt>
  mov    %rax,0x48(%rsp)
  test   %r12d,%r12d
  jle    L19
  test   %ebp,%ebp
  jg     L17
  movl   $0x0,0x8c(%rsp)
L103:
  mov    0x38(%rsp),%r13
  mov    0x48(%rsp),%r15
  mov    %r12d,(%rsp)
  movslq 0x8c(%rsp),%rbp
  xchg   %ax,%ax
L157:
  mov    0x28(%rsp),%r12d
  mov    0x40(%rsp),%rdi
  mov    %r13,%rdx
  mov    (%rsp),%ebx
  sub    %ebp,%r12d
  mov    %r12d,%esi
  sub    %ebp,%ebx
  call   <house@plt>
  mov    0x70(%rsp),%rax
  mov    %r12d,%r8d
  mov    %ebx,%ecx
  mov    $0x1,%r9d
  mov    %r15,%rdx
  mov    %r13,%rsi
  mov    %r14,%rdi
  movsd  %xmm0,(%rax,%rbp,8)
  add    $0x1,%rbp
  movsd  %xmm0,0x8(%rsp)
  call   <mmult@plt>
  movsd  0x8(%rsp),%xmm0
  mov    %ebx,%esi
  mov    %r15,%rdi
  mov    $0x1,%edx
  call   <scale@plt>
  mov    %ebx,%r9d
  mov    %r12d,%ecx
  mov    %r14,%rdx
  mov    $0x1,%r8d
  mov    %r15,%rsi
  mov    %r13,%rdi
  call   <mmult@plt>
  cmp    %ebp,(%rsp)
  jg     L157
L19:
  mov    0x40(%rsp),%rdi
  call   <free@plt>
  mov    0x38(%rsp),%rdi
  call   <free@plt>
  mov    %r14,%rdi
  call   <free@plt>
  mov    0x48(%rsp),%rdi
  add    $0xb8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    10b0 <free@plt>
L17:
  mov    0x28(%rsp),%eax
  lea    0x0(,%rbx,8),%r11
  mov    %r12d,0x8(%rsp)
  lea    0x0(,%r15,8),%rbp
  movl   $0x0,0x64(%rsp)
  cmp    %r12d,%eax
  mov    %eax,%esi
  mov    %r13,0x50(%rsp)
  cmovg  %r12d,%esi
  movq   $0x0,(%rsp)
  sub    $0x2,%eax
  mov    %eax,0xac(%rsp)
  mov    %r13,%rax
  mov    %esi,0xa8(%rsp)
  lea    0x8(,%rbx,8),%rsi
  sub    %r15,%rbx
  shl    $0x3,%rbx
  mov    %rsi,0x90(%rsp)
  mov    %r14,%rsi
  sub    %r13,%rsi
  mov    %rbx,0x98(%rsp)
  lea    0x8(%r14),%rbx
  mov    %rsi,0x68(%rsp)
  mov    %rbx,0xa0(%rsp)
  mov    %r13,0x58(%rsp)
  mov    %r11,%r13
  mov    %rax,%r11
  nopl   0x0(%rax)
L108:
  mov    (%rsp),%rax
  mov    0x40(%rsp),%rcx
  mov    0x50(%rsp),%rdx
  lea    0x1(%rax),%esi
  mov    %eax,0x88(%rsp)
  mov    %eax,%ebx
  mov    %esi,0x8c(%rsp)
  mov    0x28(%rsp),%esi
  mov    %esi,%r15d
  sub    %eax,%r15d
  nopl   0x0(%rax,%rax,1)
L131:
  movsd  (%rdx),%xmm0
  add    $0x1,%eax
  add    %r13,%rdx
  add    $0x8,%rcx
  movsd  %xmm0,-0x8(%rcx)
  cmp    %eax,%esi
  jg     L131
  mov    0x40(%rsp),%rdi
  mov    0x38(%rsp),%rdx
  mov    %r15d,%esi
  mov    %r11,0x10(%rsp)
  call   <house@plt>
  mov    0x70(%rsp),%rax
  mov    (%rsp),%r8
  mov    %ebx,%esi
  mov    0x58(%rsp),%rcx
  mov    0x10(%rsp),%r11
  mov    %r14,%rdi
  mov    0x28(%rsp),%r9d
  movsd  %xmm0,(%rax,%r8,8)
  nopl   0x0(%rax)
L68:
  mov    %rdi,%rdx
  mov    %r8,%rax
  cs nopw 0x0(%rax,%rax,1)
L61:
  movsd  (%rcx,%rax,8),%xmm1
  add    $0x1,%rax
  movsd  %xmm1,(%rdx)
  add    %rbp,%rdx
  cmp    %eax,%r12d
  jg     L61
  add    $0x1,%esi
  add    $0x8,%rdi
  add    %r13,%rcx
  cmp    %esi,%r9d
  jg     L68
  mov    0x8(%rsp),%ecx
  mov    0x48(%rsp),%rdx
  mov    %r15d,%r8d
  mov    %r14,%rdi
  mov    0x38(%rsp),%rsi
  mov    $0x1,%r9d
  mov    %r11,0x80(%rsp)
  movsd  %xmm0,0x10(%rsp)
  call   <mmult@plt>
  movsd  0x10(%rsp),%xmm0
  mov    0x8(%rsp),%esi
  mov    $0x1,%edx
  mov    0x48(%rsp),%rdi
  call   <scale@plt>
  mov    0x8(%rsp),%r9d
  mov    %r15d,%ecx
  mov    %r14,%rdx
  mov    0x48(%rsp),%rsi
  mov    0x38(%rsp),%rdi
  mov    $0x1,%r8d
  call   <mmult@plt>
  mov    0x8(%rsp),%r11d
  mov    0x98(%rsp),%rax
  mov    %rbp,0x78(%rsp)
  mov    0x88(%rsp),%edx
  mov    0xa0(%rsp),%r10
  add    %rbp,%rax
  mov    0x68(%rsp),%rcx
  mov    0x58(%rsp),%r8
  mov    %ebx,%ebp
  mov    %rax,0x18(%rsp)
  mov    (%rsp),%rax
  mov    0x50(%rsp),%r9
  neg    %rax
  shl    $0x3,%rax
  cmp    %ebx,%r12d
  mov    %rax,0x20(%rsp)
  mov    $0x1,%eax
  cmovg  %r11d,%eax
  sub    $0x1,%r11d
  xor    %esi,%esi
  mov    %r11d,0x10(%rsp)
  mov    0x80(%rsp),%r11
  mov    %eax,%edi
  mov    %eax,0x2c(%rsp)
  shr    %eax
  sub    $0x1,%eax
  and    $0xfffffffe,%edi
  add    $0x1,%rax
  mov    %edi,0x60(%rsp)
  add    %edi,%edx
  mov    0x64(%rsp),%edi
  shl    $0x4,%rax
  mov    %rax,0x30(%rsp)
  nopl   0x0(%rax,%rax,1)
L8:
  cmp    (%rsp),%r12d
  setg   %r15b
  cmpl   $0x1,0x10(%rsp)
  seta   %al
  test   %al,%r15b
  je     L74
  cmp    %r10,%r9
  je     L74
  mov    0x30(%rsp),%rax
  lea    (%rax,%r9,1),%r15
  mov    %r9,%rax
  xchg   %ax,%ax
L134:
  movupd (%rax),%xmm0
  movupd (%rax,%rcx,1),%xmm2
  add    $0x10,%rax
  subpd  %xmm2,%xmm0
  movups %xmm0,-0x10(%rax)
  cmp    %r15,%rax
  jne    L134
  mov    0x60(%rsp),%r15d
  cmp    %r15d,0x2c(%rsp)
  je     L117
  lea    (%rdi,%rdx,1),%eax
  cltq
  lea    (%r11,%rax,8),%r15
  lea    (%rsi,%rdx,1),%eax
  sub    %ebx,%eax
  movsd  (%r15),%xmm0
  cltq
  subsd  (%r14,%rax,8),%xmm0
  movsd  %xmm0,(%r15)
L117:
  add    $0x1,%ebp
  add    0x18(%rsp),%r10
  add    %r13,%r9
  add    %r12d,%edi
  add    %r13,%r8
  add    0x8(%rsp),%esi
  add    0x20(%rsp),%rcx
  cmp    %ebp,0x28(%rsp)
  jg     L8
  mov    0x64(%rsp),%eax
  mov    0x78(%rsp),%rbp
  mov    0x8c(%rsp),%ebx
  lea    (%r12,%rax,1),%esi
  cmp    %ebx,0x28(%rsp)
  jle    L190
  mov    0x64(%rsp),%esi
  mov    0x38(%rsp),%rbx
  mov    0xac(%rsp),%ecx
  sub    0x88(%rsp),%ecx
  add    %r12d,%esi
  lea    0x8(%rbx),%rax
  lea    0x10(%rbx,%rcx,8),%rcx
  movslq %esi,%rdx
  add    (%rsp),%rdx
  lea    (%r11,%rdx,8),%rdx
  nopw   0x0(%rax,%rax,1)
L123:
  movsd  (%rax),%xmm0
  add    $0x8,%rax
  movsd  %xmm0,(%rdx)
  add    %r13,%rdx
  cmp    %rax,%rcx
  jne    L123
L190:
  mov    0x90(%rsp),%rdi
  addq   $0x1,(%rsp)
  sub    $0x8,%rbp
  add    %rdi,0x50(%rsp)
  mov    (%rsp),%rax
  add    %r13,0x58(%rsp)
  sub    %rdi,0x68(%rsp)
  mov    %esi,0x64(%rsp)
  cmp    %eax,0xa8(%rsp)
  jle    L176
  mov    0x10(%rsp),%eax
  mov    %eax,0x8(%rsp)
  jmp    L108
  nopw   0x0(%rax,%rax,1)
L74:
  mov    (%rsp),%rax
  lea    -0x8(%r10),%r15
  nopl   0x0(%rax,%rax,1)
L63:
  movsd  (%r8,%rax,8),%xmm0
  subsd  (%r15),%xmm0
  add    $0x8,%r15
  movsd  %xmm0,(%r8,%rax,8)
  add    $0x1,%rax
  cmp    %eax,%r12d
  jg     L63
  jmp    L117
L176:
  cmp    0x8c(%rsp),%r12d
  jg     L103
  jmp    L19
L32:
  lea    D2(%rip),%rdi
  call   <printf@plt>
  mov    $0x1,%edi
  call   <exit@plt>
  jmp    L107
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D2
data_type: string

tool: D2: M should be greater than or equal to N

assistant: ```c
void qr_house(double *A, int M, int N, double *bvec) {
  int j, i, k, u, t;
  double *x, *v, *AT, *w;
  double beta;
  if (M < N) {
    printf("M should be greater than or equal to N");
    exit(1);
  }
  x = (double *)malloc(sizeof(double) * M);
  v = (double *)malloc(sizeof(double) * M);
  AT = (double *)malloc(sizeof(double) * M * N);
  w = (double *)malloc(sizeof(double) * M * M);
  for (j = 0; j < N; ++j) {
    for (i = j; i < M; ++i) {
      x[i - j] = A[i * N + j];
    }
    beta = house(x, M - j, v);
    bvec[j] = beta;
    for (i = j; i < M; i++) {
      t = i * N;
      u = 0;
      for (k = j; k < N; k++) {
        AT[u + i - j] = A[k + t];
        u += (M - j);
      }
    }
    mmult(AT, v, w, N - j, M - j, 1);
    scale(w, N - j, 1, beta);
    mmult(v, w, AT, M - j, 1, N - j);
    for (i = j; i < M; i++) {
      t = i * N;
      for (k = j; k < N; k++) {
        A[t + k] -= AT[(i - j) * (N - j) + k - j];
      }
    }
    if (j < M) {
      for (i = j + 1; i < M; ++i) {
        A[i * N + j] = v[i - j];
      }
    }
  }
  free(x);
  free(v);
  free(AT);
  free(w);
}
```