// File: simonrharris[P]SKA/src/ska.cpp
// Function: infoSubcommand(int, char**)
int infoSubcommand(int argc, char *argv[]){

	std::vector < std::string > args;
	bool tabulated=false;

	for (int i=2; i<argc; ++i){

		std::string arg=(argv[i]);

		if (arg=="-h" || arg=="--help"){
			infoHelp();
			return 0;
		}
		else if (arg == "-f"){
			i++;
			if (i<argc){
				fileToVector(argv[i], args);
			}
			else {
				std::cerr << std::endl << "Expecting file name after -f flag" << std::endl << std::endl;
				return 1;
			}
		}
		else if (arg == "-t"){
			tabulated=true;
		}
		else if (arg[0]=='-'){
			std::cerr << std::endl << "Unrecognised flag " << arg << std::endl << std::endl;
				return 1;
		}
		else {
			args.push_back(arg);
		}
	}

	if (args.size()<1){
		std::cerr << std::endl << "Too few arguments" << std::endl;
		infoHelp();
		return 1;
	}

	if (getKmerFileInfo(args, tabulated)){return 1;}

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x120, %rsp            # imm = 0x120
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
leaq -0x28(%rbp), %rdi
callq 0x1ab40
movb $0x0, -0x29(%rbp)
movl $0x2, -0x30(%rbp)
movl -0x30(%rbp), %eax
cmpl -0x8(%rbp), %eax
jge 0x535b3
movq -0x10(%rbp), %rax
movslq -0x30(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0xa0(%rbp)
leaq -0x51(%rbp), %rdi
movq %rdi, -0x98(%rbp)
callq 0x6910
movq -0xa0(%rbp), %rsi
movq -0x98(%rbp), %rdx
leaq -0x50(%rbp), %rdi
callq 0xab20
jmp 0x5327e
leaq -0x51(%rbp), %rdi
callq 0x65a0
leaq 0x7d59(%rip), %rsi      # 0x5afe7
leaq -0x50(%rbp), %rdi
callq 0x2dce0
movb %al, -0xa1(%rbp)
jmp 0x5329f
movb -0xa1(%rbp), %al
testb $0x1, %al
jne 0x532cf
jmp 0x532ab
leaq 0x7d38(%rip), %rsi      # 0x5afea
leaq -0x50(%rbp), %rdi
callq 0x2dce0
movb %al, -0xa2(%rbp)
jmp 0x532c3
movb -0xa2(%rbp), %al
testb $0x1, %al
jne 0x532cf
jmp 0x53314
callq 0x53100
jmp 0x532d6
movl $0x0, -0x4(%rbp)
movl $0x1, -0x68(%rbp)
jmp 0x5357f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x51(%rbp), %rdi
callq 0x65a0
jmp 0x5368a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x535a5
leaq 0x7d4c(%rip), %rsi      # 0x5b067
leaq -0x50(%rbp), %rdi
callq 0x2dce0
movb %al, -0xa3(%rbp)
jmp 0x5332c
movb -0xa3(%rbp), %al
testb $0x1, %al
jne 0x5333b
jmp 0x53479
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
movl -0x30(%rbp), %eax
cmpl -0x8(%rbp), %eax
jge 0x533f8
movq -0x10(%rbp), %rax
movslq -0x30(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0xb8(%rbp)
leaq -0x89(%rbp), %rdi
movq %rdi, -0xb0(%rbp)
callq 0x6910
movq -0xb8(%rbp), %rsi
movq -0xb0(%rbp), %rdx
leaq -0x88(%rbp), %rdi
callq 0xab20
jmp 0x53392
leaq -0x88(%rbp), %rdi
leaq -0x28(%rbp), %rsi
callq 0xa6a0
jmp 0x533a4
leaq -0x88(%rbp), %rdi
callq 0x6a08
leaq -0x89(%rbp), %rdi
callq 0x65a0
jmp 0x53474
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x533e7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x88(%rbp), %rdi
callq 0x6a08
leaq -0x89(%rbp), %rdi
callq 0x65a0
jmp 0x535a5
movq 0x25bf1(%rip), %rdi     # 0x78ff0
movq 0x25b8a(%rip), %rsi     # 0x78f90
callq 0x6570
movq %rax, -0xc0(%rbp)
jmp 0x53414
movq -0xc0(%rbp), %rdi
leaq 0x7c48(%rip), %rsi      # 0x5b06a
callq 0x6520
movq %rax, -0xc8(%rbp)
jmp 0x53430
movq -0xc8(%rbp), %rdi
movq 0x25b52(%rip), %rsi     # 0x78f90
callq 0x6570
movq %rax, -0xd0(%rbp)
jmp 0x5344c
movq -0xd0(%rbp), %rdi
movq 0x25b36(%rip), %rsi     # 0x78f90
callq 0x6570
jmp 0x53461
movl $0x1, -0x4(%rbp)
movl $0x1, -0x68(%rbp)
jmp 0x5357f
jmp 0x53576
leaq 0x8ed5(%rip), %rsi      # 0x5c355
leaq -0x50(%rbp), %rdi
callq 0x2dce0
movb %al, -0xd1(%rbp)
jmp 0x53491
movb -0xd1(%rbp), %al
testb $0x1, %al
jne 0x5349d
jmp 0x534a6
movb $0x1, -0x29(%rbp)
jmp 0x53574
xorl %eax, %eax
movl %eax, %esi
leaq -0x50(%rbp), %rdi
callq 0x69e0
movq %rax, -0xe0(%rbp)
jmp 0x534bc
movq -0xe0(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2d, %eax
jne 0x53561
movq 0x25b1a(%rip), %rdi     # 0x78ff0
movq 0x25ab3(%rip), %rsi     # 0x78f90
callq 0x6570
movq %rax, -0xe8(%rbp)
jmp 0x534eb
movq -0xe8(%rbp), %rdi
leaq 0x7b93(%rip), %rsi      # 0x5b08c
callq 0x6520
movq %rax, -0xf0(%rbp)
jmp 0x53507
movq -0xf0(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x64d0
movq %rax, -0xf8(%rbp)
jmp 0x53520
movq -0xf8(%rbp), %rdi
movq 0x25a62(%rip), %rsi     # 0x78f90
callq 0x6570
movq %rax, -0x100(%rbp)
jmp 0x5353c
movq -0x100(%rbp), %rdi
movq 0x25a46(%rip), %rsi     # 0x78f90
callq 0x6570
jmp 0x53551
movl $0x1, -0x4(%rbp)
movl $0x1, -0x68(%rbp)
jmp 0x5357f
leaq -0x28(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0xabd0
jmp 0x53570
jmp 0x53572
jmp 0x53574
jmp 0x53576
jmp 0x53578
movl $0x0, -0x68(%rbp)
leaq -0x50(%rbp), %rdi
callq 0x6a08
movl -0x68(%rbp), %eax
testl %eax, %eax
jne 0x53675
jmp 0x53595
jmp 0x53597
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x53236
leaq -0x50(%rbp), %rdi
callq 0x6a08
jmp 0x5368a
leaq -0x28(%rbp), %rdi
callq 0xb670
cmpq $0x1, %rax
jae 0x53634
movq 0x25a27(%rip), %rdi     # 0x78ff0
movq 0x259c0(%rip), %rsi     # 0x78f90
callq 0x6570
movq %rax, -0x108(%rbp)
jmp 0x535de
movq -0x108(%rbp), %rdi
leaq 0x7ab3(%rip), %rsi      # 0x5b09f
callq 0x6520
movq %rax, -0x110(%rbp)
jmp 0x535fa
movq -0x110(%rbp), %rdi
movq 0x25988(%rip), %rsi     # 0x78f90
callq 0x6570
jmp 0x5360f
callq 0x53100
jmp 0x53616
movl $0x1, -0x4(%rbp)
movl $0x1, -0x68(%rbp)
jmp 0x53675
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x5368a
movzbl -0x29(%rbp), %esi
andl $0x1, %esi
leaq -0x28(%rbp), %rdi
callq 0x33560
movl %eax, -0x114(%rbp)
jmp 0x5364c
movl -0x114(%rbp), %eax
cmpl $0x0, %eax
je 0x53667
movl $0x1, -0x4(%rbp)
movl $0x1, -0x68(%rbp)
jmp 0x53675
movl $0x0, -0x4(%rbp)
movl $0x1, -0x68(%rbp)
leaq -0x28(%rbp), %rdi
callq 0xfe90
movl -0x4(%rbp), %eax
addq $0x120, %rsp            # imm = 0x120
popq %rbp
retq
leaq -0x28(%rbp), %rdi
callq 0xfe90
movq -0x60(%rbp), %rdi
callq 0x6900
nopl (%rax)