// File: /workspace/github_cpp_makefile_star2_O1/SilentAssassinMa[P]Sudoku-Solver/SudokuSolver.cpp
// Function: SudokuSolver::SudokuSolver(char const*)
SudokuSolver::SudokuSolver(const char *inputfilename)
{
    ifstream infile;
    infile.open(inputfilename, ios::in);

    for (int i = 0; i < 81; i++)
    {
        infile >> OriginalSudoku[i];
        if (OriginalSudoku[i] < 0 || OriginalSudoku[i] > 9)
        {
            cout << "Error : Input Sudoku Is Wrong !" << endl;
            isSolvable = false;
            return;
        }

        isChangeable[i] = OriginalSudoku[i] == 0 ? true : false;
        Current[i] = OriginalSudoku[i];
    }

    if (!CheckConsistency(OriginalSudoku))
    {
        cout << "Error : Input Sudoku Is Wrong !" << endl;
        isSolvable = false;
        return;
    }

    if (!CheckEmpty(OriginalSudoku))
    {
        cout << "Error : The Input Sudoku Has Already Been Fiiled Out" << endl;
        isSolvable = false;
        return;
    }

    infile.close();

    isSolvable = true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x208, %rsp            # imm = 0x208
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x37be(%rip), %rax      # 0x5d60
movq %rax, (%rdi)
leaq 0x8(%rdi), %r14
movl $0x144, %edx            # imm = 0x144
movq %r14, %rdi
xorl %esi, %esi
callq 0x20c0
leaq 0x14c(%rbx), %rdi
movl $0x144, %edx            # imm = 0x144
xorl %esi, %esi
callq 0x20c0
xorps %xmm0, %xmm0
movups %xmm0, 0x290(%rbx)
movups %xmm0, 0x2a0(%rbx)
movups %xmm0, 0x2b0(%rbx)
movups %xmm0, 0x2c0(%rbx)
movups %xmm0, 0x2d0(%rbx)
movb $0x0, 0x2e0(%rbx)
movups %xmm0, 0x2e8(%rbx)
movups %xmm0, 0x2f8(%rbx)
movups %xmm0, 0x308(%rbx)
movq %rsp, %rdi
callq 0x2180
movq %rsp, %rdi
movq %r15, %rsi
movl $0x8, %edx
callq 0x20e0
movl $0x290, %r13d           # imm = 0x290
movq %rsp, %r15
movq %r14, %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x20d0
movl (%r12), %eax
cmpl $0xa, %eax
jae 0x2694
testl %eax, %eax
sete (%rbx,%r13)
movl %eax, 0x144(%r12)
addq $0x4, %r12
incq %r13
cmpq $0x2e1, %r13            # imm = 0x2E1
jne 0x2631
movq (%rbx), %rax
movq %rbx, %rdi
movq %r14, %rsi
callq *0x20(%rax)
testb %al, %al
je 0x26dc
movq (%rbx), %rax
movq %rbx, %rdi
movq %r14, %rsi
callq *0x28(%rax)
testb %al, %al
je 0x26ea
movb $0x1, %bpl
movq %rsp, %rdi
callq 0x2040
jmp 0x2732
movq 0x393d(%rip), %r14      # 0x5fd8
leaq 0x19be(%rip), %rsi      # 0x4060
movl $0x1f, %edx
movq %r14, %rdi
callq 0x2190
movq (%r14), %rax
addq -0x18(%rax), %r14
movq %r14, %rdi
movl $0xa, %esi
callq 0x2150
movsbl %al, %esi
movq 0x390b(%rip), %rdi      # 0x5fd8
callq 0x2030
movq %rax, %rdi
callq 0x2100
jmp 0x2730
movl $0x1f, %edx
leaq 0x1978(%rip), %rsi      # 0x4060
jmp 0x26f6
movl $0x34, %edx
leaq 0x198a(%rip), %rsi      # 0x4080
movq 0x38db(%rip), %r14      # 0x5fd8
movq %r14, %rdi
callq 0x2190
movq (%r14), %rax
addq -0x18(%rax), %r14
movq %r14, %rdi
movl $0xa, %esi
callq 0x2150
movsbl %al, %esi
movq 0x38b5(%rip), %rdi      # 0x5fd8
callq 0x2030
movq %rax, %rdi
callq 0x2100
xorl %ebp, %ebp
movb %bpl, 0x2e1(%rbx)
movq %rsp, %rdi
callq 0x2050
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
jmp 0x2767
jmp 0x275c
jmp 0x275c
movq %rax, %r14
movq %rsp, %rdi
callq 0x2050
leaq 0x2e8(%rbx), %r15
leaq 0x300(%rbx), %rdi
callq 0x38be
movq (%r15), %rdi
testq %rdi, %rdi
je 0x2791
movq 0x2f8(%rbx), %rsi
subq %rdi, %rsi
callq 0x2170
movq %r14, %rdi
callq 0x2220
nop