// File: /workspace/github_cpp_makefile_star2_O3/nmmmnu[P]HM3/hm3/main/db_file.cc
// Function: main
int main(int argc, char **argv){
	if (argc <= 3){
		printUsage(argv[0]);
		return 10;
	}

	// =======================

	const auto op		= argv[1];
	const auto filename	= argv[2];

	size_t const keyCount	= (size_t) argc - 3;
	char **keys		= & argv[3];

	// =======================

	using DiskTable = hm3::DiskTable;

	DiskTable list;
	list.open(filename);
	list.printHeader();

	// =======================

	switch(op[0]){
	case 'r':	return op_filesearch(list, keyCount, keys);
	case 'l':	return op_list(list, keyCount, keys);
	}

	printUsage(argv[0]);
	return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x188, %rsp            # imm = 0x188
movq %rsi, %rbx
cmpl $0x3, %edi
jg 0x2457
movq (%rbx), %rdi
callq 0x2778
movl $0xa, %ebx
jmp 0x2716
movl %edi, %ebp
movq 0x8(%rbx), %r15
movq 0x10(%rbx), %r14
xorl %eax, %eax
movb %al, 0xa8(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0xb0(%rsp)
movb %al, 0xc0(%rsp)
movups %xmm0, 0xc8(%rsp)
movups %xmm0, 0xd8(%rsp)
movq $0x0, 0xe8(%rsp)
movups %xmm0, 0xf4(%rsp)
movl %eax, 0x104(%rsp)
movl $0x1, 0x10c(%rsp)
movups %xmm0, 0x110(%rsp)
movl %eax, 0x13c(%rsp)
movups %xmm0, 0x124(%rsp)
movl %eax, 0x134(%rsp)
movb $0x1, 0x140(%rsp)
movups %xmm0, 0x148(%rsp)
movups %xmm0, 0x158(%rsp)
movups %xmm0, 0x168(%rsp)
movups %xmm0, 0x178(%rsp)
testq %r14, %r14
je 0x2507
movq %r14, %rdi
callq 0x2090
jmp 0x250e
leaq 0x2afe(%rip), %r14      # 0x500c
leaq 0x48(%rsp), %rsi
movq %rax, (%rsi)
movq %r14, 0x8(%rsi)
leaq 0xa8(%rsp), %rdi
callq 0x31c8
leaq 0xa8(%rsp), %rdi
callq 0x45fe
movl %ebp, %ebp
movzbl (%r15), %eax
cmpl $0x6c, %eax
je 0x25b6
cmpl $0x72, %eax
jne 0x26fc
movl $0x3, %r15d
leaq 0x78(%rsp), %r14
leaq 0x48(%rsp), %r12
movq (%rbx,%r15,8), %r13
testq %r13, %r13
je 0x256b
movq %r13, %rdi
callq 0x2090
jmp 0x2574
leaq 0x2a9a(%rip), %r13      # 0x500c
xorl %eax, %eax
movq %rax, 0x48(%rsp)
movq %r13, 0x50(%rsp)
movq %r14, %rdi
leaq 0xa8(%rsp), %rsi
movq %r12, %rdx
callq 0x3ce8
cmpq $0x0, 0x78(%rsp)
je 0x25a1
movq %r14, %rdi
callq 0x2bcc
movq %r14, %rdi
callq 0x29dc
incq %r15
cmpq %r15, %rbp
jne 0x2558
jmp 0x26f8
addq $-0x3, %rbp
xorl %r12d, %r12d
leaq 0xa8(%rsp), %r14
leaq 0x10(%rsp), %r13
movq 0x18(%rbx,%r12,8), %r15
testq %r15, %r15
je 0x260a
movq %r15, %rdi
callq 0x2090
movq %rax, (%rsp)
movq %r15, 0x8(%rsp)
cmpq $0x1, %rax
jne 0x261e
cmpb $0x2d, (%r15)
jne 0x261e
movzbl 0xc0(%rsp), %ecx
leaq 0x48(%rsp), %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x3fd6
jmp 0x262e
movq $0x0, (%rsp)
leaq 0x29f3(%rip), %rax      # 0x500c
movq %rax, 0x8(%rsp)
leaq 0x48(%rsp), %rdi
movq %r14, %rsi
movq %rsp, %rdx
callq 0x3d86
movq 0xb0(%rsp), %rdx
leaq 0x78(%rsp), %rdi
movq %r14, %rsi
xorl %ecx, %ecx
callq 0x3fd6
movq 0x68(%rsp), %rax
movq %rax, 0x30(%rsp)
movups 0x48(%rsp), %xmm0
movups 0x58(%rsp), %xmm1
movaps %xmm1, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
leaq 0x38(%rsp), %rdi
leaq 0x70(%rsp), %rsi
callq 0x2a52
movq 0x10(%rsp), %rax
cmpq 0x78(%rsp), %rax
jne 0x268d
movq 0x80(%rsp), %rax
cmpq %rax, 0x18(%rsp)
je 0x26cb
movl $0xa, %r15d
movq %r13, %rdi
callq 0x3ff0
movq %rax, %rdi
callq 0x2bcc
decq %r15
je 0x26cb
movq 0x10(%rsp), %rcx
movq 0x18(%rsp), %rax
incq %rax
movq %rax, 0x18(%rsp)
cmpq 0x78(%rsp), %rcx
jne 0x2693
cmpq 0x80(%rsp), %rax
jne 0x2693
leaq 0x38(%rsp), %rdi
callq 0x29dc
leaq 0xa0(%rsp), %rdi
callq 0x29dc
leaq 0x70(%rsp), %rdi
callq 0x29dc
incq %r12
cmpq %rbp, %r12
jne 0x25ca
xorl %ebx, %ebx
jmp 0x2709
movq (%rbx), %rdi
movl $0x1, %ebx
callq 0x2778
leaq 0xa8(%rsp), %rdi
callq 0x2992
movl %ebx, %eax
addq $0x188, %rsp            # imm = 0x188
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x273a
jmp 0x273a
jmp 0x273a
movq %rax, %rbx
jmp 0x2759
movq %rax, %rbx
jmp 0x274c
movq %rax, %rbx
jmp 0x2763
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x29dc
leaq 0xa0(%rsp), %rdi
callq 0x29dc
leaq 0x70(%rsp), %rdi
callq 0x29dc
leaq 0xa8(%rsp), %rdi
callq 0x2992
movq %rbx, %rdi
callq 0x2250