user: 请显示与下面列出的汇编代码相匹配的C语言实现:

```asm
<dyaddown_2D_keep_odd>:
  endbr64
  push   %r15
  mov    %r8d,%r15d
  push   %r14
  mov    %esi,%r14d
  push   %r13
  mov    %edx,%r13d
  push   %r12
  mov    %rdi,%r12
  mov    %esi,%edi
  push   %rbp
  imul   %edx,%edi
  push   %rbx
  mov    %rcx,%rbx
  shl    $0x3,%edi
  sub    $0x48,%rsp
  mov    %esi,0x34(%rsp)
  mov    %r9d,0xc(%rsp)
  call   <malloc@plt>
  mov    0xc(%rsp),%r8d
  mov    %r12,%rdi
  mov    %r14d,%r9d
  mov    %rax,%rcx
  mov    %r14d,%edx
  mov    %r13d,%esi
  mov    %rax,%rbp
  call   <matrix_tran@plt>
  mov    %r13d,%eax
  imul   %r15d,%eax
  shl    $0x3,%eax
  mov    %eax,%edi
  mov    %eax,0x30(%rsp)
  call   <malloc@plt>
  mov    %rax,%r12
  test   %r15d,%r15d
  jle    L41
  test   %r13d,%r13d
  jle    L51
  movslq %r13d,%rax
  mov    %r15d,0x10(%rsp)
  mov    %r13d,%ecx
  mov    %r12,%rsi
  mov    %rbx,0x38(%rsp)
  lea    0x8(%rbp),%r11
  mov    %rbp,%r10
  and    $0xfffffffe,%ecx
  lea    0x0(,%rax,8),%rdi
  shl    $0x4,%rax
  xor    %r14d,%r14d
  mov    %rax,%rdx
  mov    %r13d,%eax
  mov    %rdi,0x18(%rsp)
  xor    %edi,%edi
  shr    %eax
  mov    %rdx,%rbx
  lea    -0x1(%rax),%r9d
  lea    -0x1(%r13),%eax
  mov    %eax,0x20(%rsp)
  mov    %r13d,%eax
  add    $0x1,%r9
  mov    %rax,0x28(%rsp)
  shl    $0x4,%r9
  nopw   0x0(%rax,%rax,1)
L109:
  cmpl   $0x2,0x20(%rsp)
  lea    (%rdi,%rdi,1),%eax
  jbe    L42
  cmp    %r11,%rsi
  lea    -0x8(%r11),%r8
  setne  %r15b
  xor    %edx,%edx
  test   %r15b,%r15b
  je     L42
  nopl   0x0(%rax)
L176:
  movupd (%r8,%rdx,1),%xmm1
  movups %xmm1,(%rsi,%rdx,1)
  add    $0x10,%rdx
  cmp    %r9,%rdx
  jne    L176
  cmp    %r13d,%ecx
  je     L123
  add    %ecx,%eax
  cltq
  movsd  0x0(%rbp,%rax,8),%xmm0
  lea    (%rdi,%rcx,1),%eax
  cltq
  movsd  %xmm0,(%r12,%rax,8)
L123:
  add    $0x1,%r14d
  add    0x18(%rsp),%rsi
  add    %rbx,%r11
  add    %r13d,%edi
  add    %rbx,%r10
  cmp    %r14d,0x10(%rsp)
  jne    L109
  mov    0x38(%rsp),%rbx
  mov    0x10(%rsp),%r15d
L51:
  mov    %rbp,%rdi
  call   <free@plt>
  mov    0x30(%rsp),%edi
  call   <malloc@plt>
  mov    0xc(%rsp),%r14d
  mov    %r12,%rdi
  mov    %r13d,%edx
  mov    0x34(%rsp),%r8d
  mov    %rax,%rcx
  mov    %r15d,%esi
  mov    %rax,%rbp
  mov    %r14d,%r9d
  call   <matrix_tran@plt>
  mov    %r12,%rdi
  call   <free@plt>
  test   %r14d,%r14d
  jle    L35
  movslq %r15d,%rax
  mov    %r15d,%ecx
  lea    0x8(%rbp),%r11
  mov    %rbx,%rsi
  mov    %rax,%r13
  shl    $0x3,%rax
  mov    %rbp,%r10
  and    $0xfffffffe,%ecx
  mov    %rax,0x10(%rsp)
  mov    %r15d,%eax
  shl    $0x4,%r13
  xor    %edi,%edi
  shr    %eax
  xor    %r12d,%r12d
  lea    -0x1(%rax),%r9d
  lea    -0x1(%r15),%eax
  mov    %eax,0x18(%rsp)
  mov    %r15d,%eax
  add    $0x1,%r9
  mov    %rax,0x20(%rsp)
  shl    $0x4,%r9
  nopl   0x0(%rax)
L107:
  cmpl   $0x2,0x18(%rsp)
  lea    (%rdi,%rdi,1),%eax
  jbe    L121
  cmp    %r11,%rsi
  lea    -0x8(%r11),%r8
  setne  %r14b
  xor    %edx,%edx
  test   %r14b,%r14b
  je     L121
  nopl   0x0(%rax)
L18:
  movupd (%r8,%rdx,1),%xmm2
  movups %xmm2,(%rsi,%rdx,1)
  add    $0x10,%rdx
  cmp    %rdx,%r9
  jne    L18
  cmp    %ecx,%r15d
  je     L170
  add    %ecx,%eax
  cltq
  movsd  0x0(%rbp,%rax,8),%xmm0
  lea    (%rdi,%rcx,1),%eax
  cltq
  movsd  %xmm0,(%rbx,%rax,8)
L170:
  add    $0x1,%r12d
  add    %r13,%r11
  add    0x10(%rsp),%rsi
  add    %r15d,%edi
  add    %r13,%r10
  cmp    %r12d,0xc(%rsp)
  jne    L107
L35:
  add    $0x48,%rsp
  mov    %rbp,%rdi
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1070 <free@plt>
  nopl   0x0(%rax,%rax,1)
L42:
  mov    0x28(%rsp),%rdx
  xor    %eax,%eax
  nopw   0x0(%rax,%rax,1)
L168:
  movsd  (%r10,%rax,8),%xmm0
  movsd  %xmm0,(%rsi,%rax,8)
  add    $0x1,%rax
  cmp    %rax,%rdx
  jne    L168
  jmp    L123
  nopl   0x0(%rax)
L121:
  mov    0x20(%rsp),%rdx
  xor    %eax,%eax
  nopw   0x0(%rax,%rax,1)
L70:
  movsd  (%r10,%rax,8),%xmm0
  movsd  %xmm0,(%rsi,%rax,8)
  add    $0x1,%rax
  cmp    %rdx,%rax
  jne    L70
  jmp    L170
L41:
  mov    %rbp,%rdi
  call   <free@plt>
  mov    0x30(%rsp),%edi
  call   <malloc@plt>
  mov    0xc(%rsp),%r9d
  mov    %r12,%rdi
  mov    %r13d,%edx
  mov    0x34(%rsp),%r8d
  mov    %rax,%rcx
  mov    %r15d,%esi
  mov    %rax,%rbp
  call   <matrix_tran@plt>
  mov    %r12,%rdi
  call   <free@plt>
  jmp    L35
```

assistant: ```c
void dyaddown_2D_keep_odd(double *matrixIn, int matrixInRow, int matrixInCol, double *matrixOut, int matrixOutRow, int matrixOutCol) {
  int row, col;
  double *matrixInTemp, *matrixOutPre, *matrixOutTemp;
  matrixInTemp = malloc(matrixInRow * matrixInCol * sizeof(double));
  matrix_tran(matrixIn, matrixInCol, matrixInRow, matrixInTemp, matrixOutCol, matrixInRow);
  matrixOutPre = malloc(matrixOutRow * matrixInCol * sizeof(double));
  for (row = 0; row < matrixOutRow; row++) {
    for (col = 0; col < matrixInCol; col++)
      matrixOutPre[col + row * matrixInCol] = matrixInTemp[col + 2 * row * matrixInCol];
  }
  free(matrixInTemp);
  matrixOutTemp = malloc(matrixOutRow * matrixInCol * sizeof(double));
  matrix_tran(matrixOutPre, matrixOutRow, matrixInCol, matrixOutTemp, matrixInRow, matrixOutCol);
  free(matrixOutPre);
  for (col = 0; col < matrixOutCol; col++) {
    for (row = 0; row < matrixOutRow; row++)
      matrixOut[row + col * matrixOutRow] = matrixOutTemp[row + 2 * col * matrixOutRow];
  }
  free(matrixOutTemp);
  return;
}
```