// File: /workspace/github_cpp_makefile_star2_O1/bothaynahazem[P]AsuMathLabG13/Matrix2017.cpp
// Function: Matrix::sub(Matrix const&)
void Matrix::sub(const Matrix& m)
{
	if (nRows != m.nRows || nColumns != m.nColumns)
		throw("Invalid matrix dimension");
	for (int iR = 0;iR < nRows;iR++)
	{
		for (int iC = 0;iC < nColumns;iC++)
    {
      if((this->type=="complex") && (m.type=="complex"))
        cvalues[iR][iC] -= m.cvalues[iR][iC];
      else if((this->type=="complex") && (m.type!="complex"))
        cvalues[iR][iC] -= m.values[iR][iC];
      else if((this->type!="complex") && (m.type=="complex"))
        cvalues[iR][iC] =values[iR][iC]-m.cvalues[iR][iC];
      else
        values[iR][iC] -= m.values[iR][iC];
    }
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl (%rdi), %eax
cmpl (%rsi), %eax
jne 0xbeb7
movq %rsi, %r14
movl 0x4(%rdi), %eax
cmpl 0x4(%rsi), %eax
jne 0xbeb7
cmpl $0x0, (%rdi)
jle 0xbea8
leaq 0x18(%rdi), %r15
leaq 0x18(%r14), %rax
movq %rax, -0x40(%rbp)
movq $0x0, -0x30(%rbp)
leaq 0x54dd(%rip), %rbx      # 0x111f5
movq %r15, -0x48(%rbp)
movq %rdi, -0x38(%rbp)
cmpl $0x0, 0x4(%rdi)
jle 0xbe91
xorl %r12d, %r12d
xorl %r13d, %r13d
movq %r15, %rdi
movq %rbx, %rsi
callq 0x30e0
testl %eax, %eax
jne 0xbd53
movq -0x40(%rbp), %rdi
movq %rbx, %rsi
callq 0x30e0
testl %eax, %eax
je 0xbe3a
movq %r15, %rdi
movq %rbx, %rsi
callq 0x30e0
testl %eax, %eax
je 0xbdb1
movq -0x48(%rbp), %rdi
movq %rbx, %rsi
callq 0x30e0
testl %eax, %eax
je 0xbd82
movq -0x40(%rbp), %rdi
movq %rbx, %rsi
callq 0x30e0
testl %eax, %eax
je 0xbdf0
movq 0x8(%r14), %rax
movq -0x30(%rbp), %rdx
movq (%rax,%rdx,8), %rax
movq -0x38(%rbp), %rdi
movq 0x8(%rdi), %rcx
movq (%rcx,%rdx,8), %rcx
movsd (%rcx,%r12), %xmm0
subsd (%rax,%r12), %xmm0
movsd %xmm0, (%rcx,%r12)
jmp 0xbe79
movq -0x40(%rbp), %rdi
movq %rbx, %rsi
callq 0x30e0
testl %eax, %eax
je 0xbd62
movq 0x8(%r14), %rax
movq -0x30(%rbp), %rdx
movq (%rax,%rdx,8), %rax
movq -0x38(%rbp), %rdi
movq 0x10(%rdi), %rcx
movq (%rcx,%rdx,8), %rcx
movsd (%rcx,%r12,2), %xmm0
subsd (%rax,%r12), %xmm0
movsd %xmm0, (%rcx,%r12,2)
jmp 0xbe79
movq -0x38(%rbp), %rdi
movq 0x8(%rdi), %rax
movq 0x10(%rdi), %rcx
movq -0x30(%rbp), %r8
movq (%rax,%r8,8), %rax
movq 0x10(%r14), %rdx
movq (%rdx,%r8,8), %rdx
movsd 0x8(%rdx,%r12,2), %xmm0
movsd (%rax,%r12), %xmm1
subsd (%rdx,%r12,2), %xmm1
xorpd 0x5399(%rip), %xmm0     # 0x111c0
movq (%rcx,%r8,8), %rax
movsd %xmm1, (%rax,%r12,2)
movlpd %xmm0, 0x8(%rax,%r12,2)
jmp 0xbe79
movq 0x10(%r14), %rax
movq -0x30(%rbp), %rdx
movq (%rax,%rdx,8), %rax
movq -0x38(%rbp), %rdi
movq 0x10(%rdi), %rcx
movq (%rcx,%rdx,8), %rcx
movsd (%rcx,%r12,2), %xmm0
movsd 0x8(%rcx,%r12,2), %xmm1
subsd (%rax,%r12,2), %xmm0
subsd 0x8(%rax,%r12,2), %xmm1
movsd %xmm0, (%rcx,%r12,2)
movsd %xmm1, 0x8(%rcx,%r12,2)
incq %r13
movslq 0x4(%rdi), %rax
addq $0x8, %r12
cmpq %rax, %r13
movq -0x48(%rbp), %r15
jl 0xbd30
movq -0x30(%rbp), %r8
incq %r8
movslq (%rdi), %rax
movq %r8, -0x30(%rbp)
cmpq %rax, %r8
jl 0xbd20
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x8, %edi
callq 0x3170
leaq 0x537d(%rip), %rcx      # 0x11245
movq %rcx, (%rax)
movq 0xa0ee(%rip), %rsi      # 0x15fc0
movq %rax, %rdi
xorl %edx, %edx
callq 0x34d0