// File: /workspace/github_cpp_makefile_star2_O1/matteotiziano[P]simple-wavelet/wavelet.cpp
// Function: Wavelet<double>::Upconv(Matrix<double> const&, std::vector<double, std::allocator<double>> const&, std::vector<double, std::allocator<double>> const&, MatrixSize const&) const
Matrix<T> Wavelet<T>::Upconv(const Matrix<T>& x, const std::vector<T>& f1, const std::vector<T>& f2, const MatrixSize& s) const {
  // Upsample each column
  Matrix<T> tmp(s[0], x.GetNumColumns());
  for (size_t j = 0; j < x.GetNumColumns(); j++) {
    tmp.SetColumn(Upconv(x.GetColumn(j), f1, s.GetNumRows()), j);
  }
  // Upsample each row of tmp Matrix
  Matrix<T> y(s.GetNumRows(), s.GetNumColums());
  for (size_t i = 0; i < y.GetNumRows(); i++) {
    y.SetRow(Upconv(tmp.GetRow(i), f2, s.GetNumColums()), i);
  }
  return y;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %r9, %r14
movq %r8, 0x40(%rsp)
movq %rcx, 0x48(%rsp)
movq %rdx, %rbp
movq %rsi, %r12
movq %rdi, 0x8(%rsp)
movq (%r9), %rbx
movq %rdx, %rdi
callq 0x62b0
leaq 0x50(%rsp), %rdi
xorps %xmm0, %xmm0
movq %rbx, %rsi
movq %rax, %rdx
callq 0x6134
xorl %r15d, %r15d
leaq 0x10(%rsp), %rbx
leaq 0x28(%rsp), %r13
movq %rbp, %rdi
callq 0x62b0
cmpq %rax, %r15
jae 0x4c47
movq %rbx, %rdi
movq %rbp, %rsi
movq %r15, %rdx
callq 0x682c
movq (%r14), %r8
movq %r13, %rdi
movq %r12, %rsi
movq %rbx, %rdx
movq 0x48(%rsp), %rcx
callq 0x4102
leaq 0x50(%rsp), %rdi
movq %r13, %rsi
movq %r15, %rdx
callq 0x666c
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x4c2b
movq 0x38(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x4c42
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
incq %r15
jmp 0x4bd3
movq (%r14), %rsi
movq 0x8(%r14), %rdx
xorps %xmm0, %xmm0
movq 0x8(%rsp), %rdi
callq 0x6134
xorl %r15d, %r15d
leaq 0x10(%rsp), %r13
leaq 0x50(%rsp), %rbx
leaq 0x28(%rsp), %rbp
movq 0x8(%rsp), %rdi
callq 0x62ac
cmpq %rax, %r15
jae 0x4ce4
movq %r13, %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x6780
movq 0x8(%r14), %r8
movq %rbp, %rdi
movq %r12, %rsi
movq %r13, %rdx
movq 0x40(%rsp), %rcx
callq 0x4102
movq 0x8(%rsp), %rdi
movq %rbp, %rsi
movq %r15, %rdx
callq 0x658c
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x4cc8
movq 0x38(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x4cdf
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
incq %r15
jmp 0x4c6d
leaq 0x50(%rsp), %rdi
callq 0x6292
movq 0x8(%rsp), %rax
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x4d8a
movq %rax, %r14
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x4d26
movq 0x38(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
jmp 0x4d26
movq %rax, %r14
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x4d7e
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
jmp 0x4d7e
jmp 0x4d7b
movq %rax, %r14
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x4d60
movq 0x38(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
jmp 0x4d60
movq %rax, %r14
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x4d8d
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
jmp 0x4d8d
jmp 0x4d8a
movq %rax, %r14
movq 0x8(%rsp), %rdi
callq 0x6292
jmp 0x4d8d
movq %rax, %r14
leaq 0x50(%rsp), %rdi
callq 0x6292
movq %r14, %rdi
callq 0x22d0
nop