// File: /workspace/github_cpp_makefile_star2_O2/readmapping[P]alfalfa/src/fasta.cpp
// Function: fastqInputReader::nextRead(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
bool fastqInputReader::nextRead(string& meta, string& sequence, string& qualities){
    l = kseq_read(seq);
    if(l < 0)
        return false;
    else{
        meta = seq->name.s;
        sequence = seq->seq.s;
        for(size_t i = 0; i <= sequence.length(); i++) {
            char c = std::tolower(sequence[i]);
            if(nucleotidesOnly) {
                switch(c) {
                    case 'a': case 't': case 'g': case 'c': break;
                    default:
                        c = '~';
                }
            }
            sequence[i] = c;
        }
        
        if (seq->qual.l)
            qualities = seq->qual.s;
        
        return true;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movq 0x8(%rdi), %r13
movq 0x68(%r13), %rbp
cmpl $0x0, 0x60(%r13)
jne 0x15085
jmp 0x1506b
cmpl $0x40, %eax
je 0x1507d
cmpl $0x3e, %eax
je 0x1507d
movq %rbp, %rdi
callq 0x152dc
cmpl $-0x1, %eax
jne 0x15061
jmp 0x1522f
movl %eax, 0x4(%rsp)
movl %eax, 0x60(%r13)
andq $0x0, 0x48(%r13)
andq $0x0, 0x30(%r13)
andq $0x0, 0x18(%r13)
leaq 0x4(%rsp), %rcx
movq %rbp, %rdi
xorl %esi, %esi
movq %r13, %rdx
callq 0x15349
testl %eax, %eax
js 0x1514a
cmpl $0xa, 0x4(%rsp)
je 0x150c6
leaq 0x18(%r13), %rdx
pushq $0x2
popq %rsi
movq %rbp, %rdi
xorl %ecx, %ecx
callq 0x15349
movq %r12, 0x18(%rsp)
movq %r14, 0x20(%rsp)
movq %rbx, 0x10(%rsp)
cmpq $0x0, 0x40(%r13)
jne 0x150f2
movq $0x100, 0x38(%r13)      # imm = 0x100
movl $0x100, %edi            # imm = 0x100
callq 0x7430
movq %rax, 0x40(%r13)
leaq 0x48(%r13), %r12
leaq 0x30(%r13), %r14
pushq $0x1
popq %rbx
movq %rbp, %rdi
callq 0x152dc
movl %eax, 0x4(%rsp)
cmpl $0xa, %eax
je 0x150fd
cmpl $-0x1, %eax
je 0x15155
cmpl $0x2b, %eax
je 0x15155
cmpl $0x3e, %eax
je 0x15151
cmpl $0x40, %eax
je 0x15151
movq 0x30(%r13), %rcx
movq 0x40(%r13), %rdx
leaq 0x1(%rcx), %rsi
movq %rsi, 0x30(%r13)
movb %al, (%rdx,%rcx)
movq %rbp, %rdi
pushq $0x2
popq %rsi
movq %r14, %rdx
xorl %ecx, %ecx
movl %ebx, %r8d
callq 0x1534e
jmp 0x150fd
pushq $-0x1
jmp 0x1522e
movl %eax, 0x60(%r13)
movq 0x30(%r13), %rcx
movq 0x40(%r13), %rax
leaq 0x1(%rcx), %rdx
cmpq 0x38(%r13), %rdx
jb 0x151af
movq %rdx, %rcx
shrq %rcx
orq %rdx, %rcx
movq %rcx, %rdx
shrq $0x2, %rdx
orq %rcx, %rdx
movq %rdx, %rcx
shrq $0x4, %rcx
orq %rdx, %rcx
movq %rcx, %rdx
shrq $0x8, %rdx
orq %rcx, %rdx
movq %rdx, %rsi
shrq $0x10, %rsi
orq %rdx, %rsi
incq %rsi
movq %rsi, 0x38(%r13)
movq %rax, %rdi
callq 0x7590
movq %rax, 0x40(%r13)
movq 0x30(%r13), %rcx
movb $0x0, (%rax,%rcx)
cmpl $0x2b, 0x4(%rsp)
jne 0x15246
movq 0x38(%r13), %rsi
cmpq %rsi, 0x50(%r13)
jae 0x151d9
movq %rsi, 0x50(%r13)
movq 0x58(%r13), %rdi
callq 0x7590
movq %rax, 0x58(%r13)
movq %rbp, %rdi
callq 0x152dc
movl %eax, 0x4(%rsp)
cmpl $-0x1, %eax
je 0x1522c
cmpl $0xa, %eax
jne 0x151d9
movq %r15, 0x8(%rsp)
pushq $0x2
popq %rbx
pushq $0x1
popq %r15
movq %rbp, %rdi
movl %ebx, %esi
movq %r12, %rdx
xorl %ecx, %ecx
movl %r15d, %r8d
callq 0x1534e
movq (%r14), %rcx
movq (%r12), %rdx
testl %eax, %eax
js 0x1521d
cmpq %rcx, %rdx
jb 0x151fb
andl $0x0, 0x60(%r13)
cmpq %rdx, %rcx
movq 0x8(%rsp), %r15
je 0x15249
pushq $-0x2
popq %rax
movl %eax, 0x10(%r15)
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq (%r14), %rcx
movl %ecx, 0x10(%r15)
testl %ecx, %ecx
js 0x15233
movq 0x8(%r15), %rax
movq 0x10(%rax), %rsi
movq 0x18(%rsp), %rdi
callq 0x7660
movq 0x8(%r15), %rax
movq 0x40(%rax), %rsi
movq 0x20(%rsp), %r12
movq %r12, %rdi
callq 0x7660
xorl %ebx, %ebx
movl $0x80045, %ebp          # imm = 0x80045
cmpq 0x8(%r12), %rbx
ja 0x152b8
movq (%r12), %r14
movsbl (%r14,%rbx), %edi
callq 0x7490
cmpb $0x1, 0x14(%r15)
jne 0x152ab
movsbl %al, %ecx
addl $-0x61, %ecx
cmpl $0x13, %ecx
ja 0x152b4
btl %ecx, %ebp
jae 0x152b4
movb %al, (%r14,%rbx)
incq %rbx
jmp 0x1527f
movb $0x7e, %al
jmp 0x152ab
movq 0x8(%r15), %rax
movb $0x1, %bl
cmpq $0x0, 0x48(%rax)
je 0x15235
movq 0x58(%rax), %rsi
movq 0x10(%rsp), %rdi
callq 0x7660
jmp 0x15235