// File: Luthaf[P]zeopp/networkio.cc
// Function: checkInputFile(char*)
bool checkInputFile(char * filename){
  string file(filename);
  string fileTypes [] = {".cuc", ".arc", ".cssr", ".obcssr", ".v1",".cif",".car",".dlp",".pdb"};
  int numTypes = 8;

  for(int i = 0; i < numTypes; i++){
    if(file.find(fileTypes[i]) != string::npos)
      return true;
  }

  cerr << "Invalid input filename " << filename << "\n" << "Exiting ..." << "\n";
//  exit(1);
  return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x290, %rsp            # imm = 0x290
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x1a0(%rbp)
leaq -0x31(%rbp), %rdi
movq %rdi, -0x198(%rbp)
callq 0x5900
movq -0x1a0(%rbp), %rsi
movq -0x198(%rbp), %rdx
leaq -0x30(%rbp), %rdi
callq 0x47530
jmp 0x4b2d3
leaq -0x31(%rbp), %rdi
callq 0x55d0
movb $0x1, -0x182(%rbp)
leaq -0x170(%rbp), %rax
movq %rax, -0x1b0(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x179(%rbp), %rdi
movq %rdi, -0x1a8(%rbp)
callq 0x5900
movq -0x1b0(%rbp), %rdi
movq -0x1a8(%rbp), %rdx
leaq 0x1a78ef(%rip), %rsi    # 0x1f2c0f
callq 0x47530
jmp 0x4b327
leaq -0x150(%rbp), %rax
movq %rax, -0x1c0(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x17a(%rbp), %rdi
movq %rdi, -0x1b8(%rbp)
callq 0x5900
movq -0x1c0(%rbp), %rdi
movq -0x1b8(%rbp), %rdx
leaq 0x1a78b0(%rip), %rsi    # 0x1f2c14
callq 0x47530
jmp 0x4b36b
leaq -0x130(%rbp), %rax
movq %rax, -0x1d0(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x17b(%rbp), %rdi
movq %rdi, -0x1c8(%rbp)
callq 0x5900
movq -0x1d0(%rbp), %rdi
movq -0x1c8(%rbp), %rdx
leaq 0x1be372(%rip), %rsi    # 0x20971a
callq 0x47530
jmp 0x4b3af
leaq -0x110(%rbp), %rax
movq %rax, -0x1e0(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x17c(%rbp), %rdi
movq %rdi, -0x1d8(%rbp)
callq 0x5900
movq -0x1e0(%rbp), %rdi
movq -0x1d8(%rbp), %rdx
leaq 0x1a782d(%rip), %rsi    # 0x1f2c19
callq 0x47530
jmp 0x4b3f3
leaq -0xf0(%rbp), %rax
movq %rax, -0x1f0(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x17d(%rbp), %rdi
movq %rdi, -0x1e8(%rbp)
callq 0x5900
movq -0x1f0(%rbp), %rdi
movq -0x1e8(%rbp), %rdx
leaq 0x1a77f1(%rip), %rsi    # 0x1f2c21
callq 0x47530
jmp 0x4b437
leaq -0xd0(%rbp), %rax
movq %rax, -0x200(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x17e(%rbp), %rdi
movq %rdi, -0x1f8(%rbp)
callq 0x5900
movq -0x200(%rbp), %rdi
movq -0x1f8(%rbp), %rdx
leaq 0x1a77b1(%rip), %rsi    # 0x1f2c25
callq 0x47530
jmp 0x4b47b
leaq -0xb0(%rbp), %rax
movq %rax, -0x210(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x17f(%rbp), %rdi
movq %rdi, -0x208(%rbp)
callq 0x5900
movq -0x210(%rbp), %rdi
movq -0x208(%rbp), %rdx
leaq 0x1a7772(%rip), %rsi    # 0x1f2c2a
callq 0x47530
jmp 0x4b4bf
leaq -0x90(%rbp), %rax
movq %rax, -0x220(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x180(%rbp), %rdi
movq %rdi, -0x218(%rbp)
callq 0x5900
movq -0x220(%rbp), %rdi
movq -0x218(%rbp), %rdx
leaq 0x1a7733(%rip), %rsi    # 0x1f2c2f
callq 0x47530
jmp 0x4b503
leaq -0x70(%rbp), %rax
movq %rax, -0x230(%rbp)
movq %rax, -0x178(%rbp)
leaq -0x181(%rbp), %rdi
movq %rdi, -0x228(%rbp)
callq 0x5900
movq -0x230(%rbp), %rdi
movq -0x228(%rbp), %rdx
leaq 0x1a76f7(%rip), %rsi    # 0x1f2c34
callq 0x47530
jmp 0x4b544
movb $0x0, -0x182(%rbp)
leaq -0x181(%rbp), %rdi
callq 0x55d0
leaq -0x180(%rbp), %rdi
callq 0x55d0
leaq -0x17f(%rbp), %rdi
callq 0x55d0
leaq -0x17e(%rbp), %rdi
callq 0x55d0
leaq -0x17d(%rbp), %rdi
callq 0x55d0
leaq -0x17c(%rbp), %rdi
callq 0x55d0
leaq -0x17b(%rbp), %rdi
callq 0x55d0
leaq -0x17a(%rbp), %rdi
callq 0x55d0
leaq -0x179(%rbp), %rdi
callq 0x55d0
movl $0x8, -0x188(%rbp)
movl $0x0, -0x18c(%rbp)
movl -0x18c(%rbp), %eax
cmpl -0x188(%rbp), %eax
jge 0x4b79d
movslq -0x18c(%rbp), %rax
leaq -0x170(%rbp), %rsi
shlq $0x5, %rax
addq %rax, %rsi
leaq -0x30(%rbp), %rdi
xorl %eax, %eax
movl %eax, %edx
callq 0x5a10
cmpq $-0x1, %rax
je 0x4b787
movb $0x1, -0x1(%rbp)
movl $0x1, -0x190(%rbp)
jmp 0x4b858
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x31(%rbp), %rdi
callq 0x55d0
jmp 0x4b8f7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x4b71e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x4b712
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x4b706
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x4b6fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x4b6ee
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x4b6e2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x4b6d6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x4b6ca
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x181(%rbp), %rdi
callq 0x55d0
leaq -0x180(%rbp), %rdi
callq 0x55d0
leaq -0x17f(%rbp), %rdi
callq 0x55d0
leaq -0x17e(%rbp), %rdi
callq 0x55d0
leaq -0x17d(%rbp), %rdi
callq 0x55d0
leaq -0x17c(%rbp), %rdi
callq 0x55d0
leaq -0x17b(%rbp), %rdi
callq 0x55d0
leaq -0x17a(%rbp), %rdi
callq 0x55d0
leaq -0x179(%rbp), %rdi
callq 0x55d0
testb $0x1, -0x182(%rbp)
jne 0x4b735
jmp 0x4b782
movq -0x178(%rbp), %rax
leaq -0x170(%rbp), %rcx
cmpq %rax, %rcx
movq %rax, -0x238(%rbp)
je 0x4b780
movq -0x238(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x240(%rbp)
callq 0x5300
movq -0x240(%rbp), %rax
leaq -0x170(%rbp), %rcx
cmpq %rcx, %rax
movq %rax, -0x238(%rbp)
jne 0x4b74f
jmp 0x4b782
jmp 0x4b8ee
jmp 0x4b789
movl -0x18c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18c(%rbp)
jmp 0x4b5cb
movq 0x22784c(%rip), %rdi    # 0x272ff0
leaq 0x1a748e(%rip), %rsi    # 0x1f2c39
callq 0x5540
movq %rax, -0x248(%rbp)
jmp 0x4b7b9
movq -0x248(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x5540
movq %rax, -0x250(%rbp)
jmp 0x4b7d2
movq -0x250(%rbp), %rdi
leaq 0x1ade45(%rip), %rsi    # 0x1f9625
callq 0x5540
movq %rax, -0x258(%rbp)
jmp 0x4b7ee
movq -0x258(%rbp), %rdi
leaq 0x1a7407(%rip), %rsi    # 0x1f2c03
callq 0x5540
movq %rax, -0x260(%rbp)
jmp 0x4b80a
movq -0x260(%rbp), %rdi
leaq 0x1ade0d(%rip), %rsi    # 0x1f9625
callq 0x5540
jmp 0x4b81f
movb $0x0, -0x1(%rbp)
movl $0x1, -0x190(%rbp)
jmp 0x4b858
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x170(%rbp), %rax
movq %rax, -0x270(%rbp)
addq $0x120, %rax            # imm = 0x120
movq %rax, -0x268(%rbp)
jmp 0x4b8bb
leaq -0x170(%rbp), %rax
movq %rax, -0x280(%rbp)
addq $0x120, %rax            # imm = 0x120
movq %rax, -0x278(%rbp)
movq -0x278(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x288(%rbp)
callq 0x5300
movq -0x280(%rbp), %rcx
movq -0x288(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x278(%rbp)
jne 0x4b873
leaq -0x30(%rbp), %rdi
callq 0x5300
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x290, %rsp            # imm = 0x290
popq %rbp
retq
movq -0x268(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x290(%rbp)
callq 0x5300
movq -0x270(%rbp), %rcx
movq -0x290(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x268(%rbp)
jne 0x4b8bb
jmp 0x4b8ee
leaq -0x30(%rbp), %rdi
callq 0x5300
movq -0x40(%rbp), %rdi
callq 0x58f0