// File: /workspace/github_cpp_makefile_star2_O2/Konano[P]UselessDatabase/Database.cpp
// Function: Database::checkWhere(WhereStmt&)
Database::~Database() {
    update();
    fm->closeFile(mem_file);
    for (int i = 0; i < MAX_TABLE_NUM; i++) if (table[i] != nullptr) {
        delete table[i];
    }
    delete fm;
    delete bpm;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xb8, %rsp
xorps %xmm0, %xmm0
leaq 0x50(%rsp), %rax
movaps %xmm0, (%rax)
andq $0x0, 0x10(%rax)
movaps %xmm0, 0x30(%rsp)
andq $0x0, 0x40(%rsp)
movq (%rsi), %rbx
movq %rsi, 0x10(%rsp)
movq 0x8(%rsi), %r13
leaq 0x8848(%rdi), %rdx
addq $0x20, %rdi
leaq 0x28(%rsp), %r12
movq %rdx, 0x18(%rsp)
movq %rdi, %r14
cmpq %r13, %rbx
je 0x6b88
movslq (%rbx), %rax
testq %rax, %rax
movl 0x4(%rbx), %ebp
leaq (%rdi,%rax,8), %r15
notl %eax
leaq (%rdx,%rax,8), %rax
cmovsq %rax, %r15
movq (%r15), %rdi
callq 0x1f0da
testb %al, %al
je 0x6c99
movq (%r15), %rsi
movq %r12, %rdi
movl %ebp, %edx
callq 0x1f0e8
leaq 0x50(%rsp), %rdi
movq %r12, %rsi
callq 0x8ea0
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x6b7a
movq (%rdi), %rax
callq *0x8(%rax)
addq $0x8, %rbx
movq 0x18(%rsp), %rdx
movq %r14, %rdi
jmp 0x6b24
movq 0x10(%rsp), %r12
movl 0x20(%r12), %eax
cmpl $0x3, %eax
je 0x6cbb
cmpl $0x2, %eax
je 0x6c28
cmpl $0x1, %eax
jne 0x6cd1
movq 0x28(%r12), %r13
movq 0x30(%r12), %rbp
leaq 0x30(%rsp), %r15
leaq 0x8(%rsp), %r12
cmpq %rbp, %r13
je 0x6ca0
movq (%r13), %rdi
movb $0x1, %bl
testq %rdi, %rdi
je 0x6bf0
movq (%rdi), %rax
callq *0x10(%rax)
movq %rax, %r14
testq %rax, %rax
je 0x6bf0
movq (%r14), %rax
movq %r14, %rdi
callq *0x10(%rax)
xorl %ebx, %ebx
jmp 0x6bf5
xorl %r14d, %r14d
xorl %eax, %eax
movq %rax, 0x8(%rsp)
movq %r15, %rdi
movq %r12, %rsi
callq 0x8ea0
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x6c15
movq (%rdi), %rax
callq *0x8(%rax)
testb %bl, %bl
jne 0x6c22
movq (%r14), %rax
movq %r14, %rdi
callq *0x8(%rax)
addq $0x8, %r13
jmp 0x6bc1
movq 0x40(%r12), %rbx
movq 0x48(%r12), %r13
leaq 0x20(%rsp), %r15
cmpq %r13, %rbx
je 0x6ca0
movslq (%rbx), %rax
testq %rax, %rax
movl 0x4(%rbx), %ebp
leaq (%rdi,%rax,8), %r12
notl %eax
leaq (%rdx,%rax,8), %rax
cmovsq %rax, %r12
movq (%r12), %rdi
callq 0x1f0da
testb %al, %al
je 0x6c99
movq (%r12), %rsi
movq %r15, %rdi
movl %ebp, %edx
callq 0x1f0e8
leaq 0x30(%rsp), %rdi
movq %r15, %rsi
callq 0x8ea0
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x6c8b
movq (%rdi), %rax
callq *0x8(%rax)
addq $0x8, %rbx
movq 0x18(%rsp), %rdx
movq %r14, %rdi
jmp 0x6c37
movb $0x1, %bl
jmp 0x6d39
movq 0x10(%rsp), %rax
movl 0x18(%rax), %edi
leaq 0x50(%rsp), %rsi
leaq 0x30(%rsp), %rdx
callq 0x6a78
movl %eax, %ebx
jmp 0x6d39
cmpl $0x8, 0x18(%r12)
jne 0x6cd5
movb $0x1, 0x1c(%r12)
andl $0x0, 0x18(%r12)
jmp 0x6ce5
xorl %ebx, %ebx
jmp 0x6d39
testb $0x1, 0x1c(%r12)
jne 0x6ce5
cmpb $0x1, 0x1d(%r12)
jne 0x6d61
movslq 0x58(%r12), %rax
testq %rax, %rax
leaq (%rdi,%rax,8), %rcx
notl %eax
leaq (%rdx,%rax,8), %rax
cmovsq %rax, %rcx
movq (%rcx), %r15
leaq 0xa0(%rsp), %r14
leaq 0x50(%rsp), %rsi
movq %r14, %rdi
callq 0x9158
movl 0x18(%r12), %edx
movzbl 0x1c(%r12), %ecx
movzbl 0x1d(%r12), %r8d
movq %r15, %rdi
movq %r14, %rsi
callq 0x1f1b2
movl %eax, %ebx
movq %r14, %rdi
callq 0x9268
leaq 0x30(%rsp), %rdi
callq 0x9268
leaq 0x50(%rsp), %rdi
callq 0x9268
movl %ebx, %eax
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movslq 0x58(%r12), %rax
testq %rax, %rax
leaq (%rdi,%rax,8), %rcx
notl %eax
leaq (%rdx,%rax,8), %rax
cmovsq %rax, %rcx
movq (%rcx), %r15
movq %rdx, %rbx
movq %rdi, %r14
leaq 0x88(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0x9158
movslq 0x58(%r12), %rax
testq %rax, %rax
leaq (%r14,%rax,8), %rcx
notl %eax
leaq (%rbx,%rax,8), %rax
cmovsq %rax, %rcx
movl $0x9fd0, %esi           # imm = 0x9FD0
addq (%rcx), %rsi
leaq 0x70(%rsp), %rdi
callq 0x9158
movl 0x18(%r12), %ecx
leaq 0x88(%rsp), %r14
leaq 0x70(%rsp), %rdx
movq %r15, %rdi
movq %r14, %rsi
callq 0x1f156
movl %eax, %ebx
leaq 0x70(%rsp), %rdi
callq 0x9268
jmp 0x6d31
movq %rax, %r15
leaq 0x70(%rsp), %rdi
callq 0x9268
jmp 0x6dfa
movq %rax, %r15
leaq 0x88(%rsp), %rdi
jmp 0x6e0f
movq %rax, %r15
leaq 0xa0(%rsp), %rdi
callq 0x9268
jmp 0x6e62
jmp 0x6e5f
movq %rax, %r15
jmp 0x6e40
movq %rax, %r15
movq 0x20(%rsp), %rdi
jmp 0x6e52
jmp 0x6e5f
movq %rax, %r15
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x6e3c
movq (%rdi), %rax
callq *0x8(%rax)
testb %bl, %bl
jne 0x6e62
movq (%r14), %rax
movq %r14, %rdi
jmp 0x6e5a
jmp 0x6e5f
movq %rax, %r15
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x6e62
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x6e62
movq %rax, %r15
leaq 0x30(%rsp), %rdi
callq 0x9268
leaq 0x50(%rsp), %rdi
callq 0x9268
movq %r15, %rdi
callq 0x56f0