// File: /workspace/github_cpp_makefile_star2_O3/c2-d2[P]disty/src/main.cpp
// Function: void load_sequences<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&)
void load_sequences(const string &fasta_fn, T &names, T &seqs) {
    gzFile fp;
    kseq_t *seq;
    int l;
    fp = gzopen(fasta_fn.c_str(), "r");
    assert (fp != nullptr);
    seq = kseq_init(fp);

    int len=0; // length of sequences (for checking)

    while ((l = kseq_read(seq)) >= 0) {
        names.push_back(seq->name.s);
        string s(seq->seq.s);
        for (auto & c: s) {
            c = toupper(c);
        }
        if(len!=0){
            assert(len==static_cast<int>(s.size()));
        }
        else{
            len=(int)s.size();
        }

        for(char &a: s){
            assert ((int)a<128);
        }

        seqs.push_back(s);
    }
    kseq_destroy(seq);
    gzclose(fp);

    assert(seqs.size()>0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdx, 0x38(%rsp)
movq %rsi, 0x50(%rsp)
movq (%rdi), %rdi
leaq 0x1fd4(%rip), %rsi      # 0x53ad
callq 0x2240
testq %rax, %rax
je 0x38d0
movq %rax, %rbx
movl $0x1, %edi
movl $0x70, %esi
callq 0x20f0
movq %rax, %r15
movl $0x1, %edi
movl $0x20, %esi
callq 0x20f0
movq %rax, %r14
movq %rbx, 0x48(%rsp)
movq %rbx, 0x18(%rax)
movl $0x4000, %edi           # imm = 0x4000
callq 0x2220
movq %rax, (%r14)
movq %r14, 0x68(%r15)
leaq 0x48(%r15), %r13
leaq 0x30(%r15), %rbp
leaq 0x18(%r15), %rax
movq %rax, 0x40(%rsp)
leaq 0x10(%rsp), %rbx
xorl %eax, %eax
movl $0x0, 0x34(%rsp)
testl %eax, %eax
je 0x3581
xorl %eax, %eax
movq %rax, 0x48(%r15)
movq %rax, 0x30(%r15)
movq %rax, 0x18(%r15)
movq %r14, %rdi
xorl %esi, %esi
movq %r15, %rdx
movq %rbx, %rcx
xorl %r8d, %r8d
callq 0x30e8
testl %eax, %eax
js 0x3864
cmpl $0xa, 0x10(%rsp)
je 0x3497
movq %r14, %rdi
movl $0x2, %esi
movq 0x40(%rsp), %rdx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x30e8
cmpq $0x0, 0x40(%r15)
jne 0x34b4
movq $0x100, 0x38(%r15)      # imm = 0x100
movl $0x100, %edi            # imm = 0x100
callq 0x2220
movq %rax, 0x40(%r15)
movl 0xc(%r14), %eax
movl $0xfffffffd, %ebx       # imm = 0xFFFFFFFD
cmpl $-0x1, %eax
je 0x3624
cmpl $0x0, 0x10(%r14)
movl 0x8(%r14), %ecx
je 0x34d9
cmpl %eax, %ecx
jge 0x3603
movq (%r14), %rsi
cmpl %eax, %ecx
jl 0x3512
movl $0x0, 0x8(%r14)
movq 0x18(%r14), %rdi
movl $0x4000, %edx           # imm = 0x4000
callq 0x22f0
movl %eax, 0xc(%r14)
cmpl $-0x1, %eax
je 0x3610
testl %eax, %eax
je 0x3617
movl 0x8(%r14), %ecx
movq (%r14), %rsi
leal 0x1(%rcx), %edx
movl %edx, 0x8(%r14)
movslq %ecx, %rcx
movb (%rsi,%rcx), %cl
movzbl %cl, %edx
movl %edx, 0x10(%rsp)
cmpl $0x2a, %edx
jg 0x3532
cmpl $0xa, %edx
je 0x34bd
jmp 0x354d
cmpl $0x2b, %edx
je 0x3628
cmpl $0x3e, %edx
je 0x360a
cmpl $0x40, %edx
je 0x360a
movq 0x30(%r15), %rax
movq 0x40(%r15), %rdx
leaq 0x1(%rax), %rsi
movq %rsi, 0x30(%r15)
movb %cl, (%rdx,%rax)
movq %r14, %rdi
movl $0x2, %esi
movq %rbp, %rdx
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x30e8
movl 0xc(%r14), %eax
jmp 0x34bd
leaq 0x10(%r14), %rbx
movl 0xc(%r14), %eax
cmpl $-0x1, %eax
je 0x385f
cmpl $0x0, 0x10(%r14)
movl 0x8(%r14), %ecx
je 0x35a5
cmpl %eax, %ecx
jge 0x385f
movq (%r14), %rsi
cmpl %eax, %ecx
jl 0x35d9
movl $0x0, 0x8(%r14)
movq 0x18(%r14), %rdi
movl $0x4000, %edx           # imm = 0x4000
callq 0x22f0
movl %eax, 0xc(%r14)
leal 0x1(%rax), %ecx
cmpl $0x2, %ecx
jb 0x3859
movl 0x8(%r14), %ecx
movq (%r14), %rsi
leal 0x1(%rcx), %edx
movl %edx, 0x8(%r14)
movslq %ecx, %rcx
movzbl (%rsi,%rcx), %ecx
movl %ecx, 0x10(%rsp)
cmpl $0x40, %ecx
je 0x35f5
cmpl $0x3e, %ecx
jne 0x3589
movl %ecx, 0x60(%r15)
leaq 0x10(%rsp), %rbx
jmp 0x3450
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jmp 0x3624
movl %edx, 0x60(%r15)
jmp 0x3628
movl $0xfffffffd, %ebx       # imm = 0xFFFFFFFD
jmp 0x361c
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl $0x1, 0x10(%r14)
movl %ebx, 0x10(%rsp)
movq 0x30(%r15), %r12
movq 0x38(%r15), %rbx
leaq 0x1(%r12), %rcx
movq 0x40(%r15), %rax
cmpq %rbx, %rcx
jb 0x3685
movq %rcx, %rdx
shrq %rdx
orq %rcx, %rdx
movq %rdx, %rcx
shrq $0x2, %rcx
orq %rdx, %rcx
movq %rcx, %rdx
shrq $0x4, %rdx
orq %rcx, %rdx
movq %rdx, %rcx
shrq $0x8, %rcx
orq %rdx, %rcx
movq %rcx, %rbx
shrq $0x10, %rbx
orq %rcx, %rbx
incq %rbx
movq %rbx, 0x38(%r15)
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2290
movq %rax, 0x40(%r15)
movb $0x0, (%rax,%r12)
cmpl $0x2b, 0x10(%rsp)
jne 0x3778
cmpq %rbx, 0x50(%r15)
jae 0x36af
movq %rbx, 0x50(%r15)
movq 0x58(%r15), %rdi
movq %rbx, %rsi
callq 0x2290
movq %rax, 0x58(%r15)
leaq 0x10(%r14), %rbx
movl 0xc(%r14), %eax
cmpl $-0x1, %eax
je 0x3723
cmpl $0x0, 0x10(%r14)
movl 0x8(%r14), %ecx
je 0x36cf
cmpl %eax, %ecx
jge 0x385f
movq (%r14), %rsi
cmpl %eax, %ecx
jl 0x3704
movl $0x0, 0x8(%r14)
movq 0x18(%r14), %rdi
movl $0x4000, %edx           # imm = 0x4000
callq 0x22f0
movl %eax, 0xc(%r14)
cmpl $-0x1, %eax
je 0x371d
testl %eax, %eax
je 0x3859
movl 0x8(%r14), %ecx
movq (%r14), %rsi
leal 0x1(%rcx), %edx
movl %edx, 0x8(%r14)
movslq %ecx, %rcx
movzbl (%rsi,%rcx), %ecx
movl %ecx, 0x10(%rsp)
cmpl $0xa, %ecx
jne 0x36b7
jmp 0x372b
movl $0x1, (%rbx)
movl $0xfffffffd, 0x10(%rsp) # imm = 0xFFFFFFFD
movq %r14, %rdi
movl $0x2, %esi
movq %r13, %rdx
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x30e8
testl %eax, %eax
js 0x375f
movq (%r13), %r12
movq (%rbp), %rax
xorl %ecx, %ecx
cmpq %rax, %r12
setb %cl
movl %ecx, 0x10(%rsp)
jb 0x372b
jmp 0x3767
movq (%rbp), %rax
movq (%r13), %r12
movl $0x0, 0x60(%r15)
cmpq %r12, %rax
jne 0x3864
testl %r12d, %r12d
js 0x3864
movq 0x10(%r15), %rsi
leaq 0x10(%rsp), %rbx
movq %rbx, %rdi
leaq 0xf(%rsp), %rdx
callq 0x337a
movq 0x50(%rsp), %rdi
movq %rbx, %rsi
callq 0x45bc
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x37c0
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x21a0
movq 0x40(%r15), %rsi
movq %rbx, %rdi
leaq 0xf(%rsp), %rdx
callq 0x337a
movq 0x18(%rsp), %rbx
testq %rbx, %rbx
je 0x37f9
movq 0x10(%rsp), %r14
xorl %r12d, %r12d
movsbl (%r14,%r12), %edi
callq 0x22e0
movb %al, (%r14,%r12)
incq %r12
cmpq %r12, %rbx
jne 0x37e3
movl 0x18(%rsp), %eax
movl 0x34(%rsp), %r14d
testl %r14d, %r14d
je 0x3816
cmpl %eax, %r14d
leaq 0x10(%rsp), %rbx
je 0x381e
jmp 0x390e
movl %eax, %r14d
leaq 0x10(%rsp), %rbx
movq 0x38(%rsp), %rdi
movq %rbx, %rsi
callq 0x457e
movl %r14d, 0x34(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x384c
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x21a0
movq 0x68(%r15), %r14
movl 0x60(%r15), %eax
jmp 0x3448
movl $0x1, (%rbx)
testq %r15, %r15
je 0x38a9
movq 0x10(%r15), %rdi
callq 0x21e0
movq 0x28(%r15), %rdi
callq 0x21e0
movq 0x40(%r15), %rdi
callq 0x21e0
movq 0x58(%r15), %rdi
callq 0x21e0
movq 0x68(%r15), %rbx
testq %rbx, %rbx
je 0x38a1
movq (%rbx), %rdi
callq 0x21e0
movq %rbx, %rdi
callq 0x21e0
movq %r15, %rdi
callq 0x21e0
movq 0x48(%rsp), %rdi
callq 0x22a0
movq 0x38(%rsp), %rcx
movq 0x8(%rcx), %rax
cmpq (%rcx), %rax
je 0x38ef
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1bed(%rip), %rdi      # 0x54c4
leaq 0x1a3c(%rip), %rsi      # 0x531a
leaq 0x1bed(%rip), %rcx      # 0x54d2
movl $0xef, %edx
callq 0x20e0
leaq 0x1c55(%rip), %rdi      # 0x554b
leaq 0x1a1d(%rip), %rsi      # 0x531a
leaq 0x1bce(%rip), %rcx      # 0x54d2
movl $0x10a, %edx            # imm = 0x10A
callq 0x20e0
leaq 0x1c16(%rip), %rdi      # 0x552b
leaq 0x19fe(%rip), %rsi      # 0x531a
leaq 0x1baf(%rip), %rcx      # 0x54d2
movl $0xfb, %edx
callq 0x20e0
jmp 0x3931
jmp 0x3952
movq %rax, %rbx
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x3955
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x21a0
jmp 0x3955
movq %rax, %rbx
movq %rbx, %rdi
callq 0x22c0
nop