// File: /workspace/github_cpp_makefile_star2_O2/BenLangmead[P]bowtie/pat.cpp
// Function: VectorPatternSource::VectorPatternSource(EList<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, 128> const&, int, int)
VectorPatternSource::VectorPatternSource(
	const EList<string>& seqs,
	int trim3,
	int trim5) :
	TrimmingPatternSource(trim3, trim5),
	cur_(0),
	paired_(false),
	tokbuf_(),
	bufs_()
{
	// Install sequences in buffers, ready for immediate copying in
	// nextBatch().  Formatting of the buffer is just like
	// TabbedPatternSource.
	const size_t seqslen = seqs.size();
	for(size_t i = 0; i < seqslen; i++) {
		tokbuf_.clear();
		tokenize(seqs[i], ":", tokbuf_, 2);
		assert_gt(tokbuf_.size(), 0);
		assert_leq(tokbuf_.size(), 2);
		// Get another buffer ready
		bufs_.resize(bufs_.size()+1);
		bufs_.back().clear();
		// Install name
		itoa10<TReadId>(static_cast<TReadId>(i), nametmp_);
		bufs_.back() = nametmp_;
		bufs_.back().push_back('\t');
		// Install sequence
		bufs_.back().append(tokbuf_[0].c_str());
		bufs_.back().push_back('\t');
		// Install qualities
		if(tokbuf_.size() > 1) {
			bufs_.back().append(tokbuf_[1].c_str());
		} else {
			const size_t len = tokbuf_[0].length();
			for(size_t i = 0; i < len; i++) {
				bufs_.back().push_back('I');
			}
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rdi, %r15
xorl %r13d, %r13d
movq %r13, 0x8(%rdi)
movb %r13b, 0x10(%rdi)
movl %edx, 0x14(%rdi)
movl %ecx, 0x18(%rdi)
leaq 0x200a3(%rip), %rax     # 0x618d8
movq %rax, (%rdi)
andq $0x0, 0x20(%rdi)
movb %r13b, 0x28(%rdi)
andl $0x0, 0x30(%rdi)
orl $-0x1, 0x34(%rdi)
andq $0x0, 0x38(%rdi)
movl $0x80, %eax
movq %rax, 0x40(%rdi)
andq $0x0, 0x48(%rdi)
leaq 0x30(%rdi), %rcx
movq %rcx, 0x10(%rsp)
andl $0x0, 0x50(%rdi)
leaq 0x50(%rdi), %rcx
movq %rcx, 0x8(%rsp)
orl $-0x1, 0x54(%rdi)
andq $0x0, 0x58(%rdi)
movq %rax, 0x60(%rdi)
andq $0x0, 0x68(%rdi)
movq %rsi, 0x20(%rsp)
movq 0x18(%rsi), %rax
movq %rax, 0x28(%rsp)
leaq 0x70(%rdi), %r12
leaq 0x58(%rsp), %rbp
leaq 0x38(%rsp), %r14
movq %r12, 0x18(%rsp)
cmpq 0x28(%rsp), %r13
je 0x41a7e
andq $0x0, 0x48(%r15)
movq %r13, 0x30(%rsp)
shlq $0x5, %r13
movq 0x20(%rsp), %rax
addq 0x8(%rax), %r13
movq %rbp, %rdi
leaq 0x6684(%rip), %rsi      # 0x47f55
leaq 0x7(%rsp), %rdx
callq 0x15df2
movq %r13, %rdi
movq %rbp, %rsi
xorl %edx, %edx
callq 0x9430
movq %rax, %rbx
movq %r13, %rdi
movq %rbp, %rsi
movq %rax, %rdx
callq 0x9470
movq %rax, %r12
movq %rbx, %rax
andq %r12, %rax
cmpq $-0x1, %rax
je 0x41961
movq %r12, %rcx
subq %rbx, %rcx
movq %r14, %rdi
movq %r13, %rsi
movq %rbx, %rdx
callq 0x9520
movq 0x10(%rsp), %rdi
movq %r14, %rsi
callq 0x16afe
movq %r14, %rdi
callq 0x9a68
movq %r13, %rdi
movq %rbp, %rsi
movq %r12, %rdx
callq 0x9430
movq %rax, %rbx
movq %r13, %rdi
movq %rbp, %rsi
movq %rax, %rdx
callq 0x9470
movq %rax, %r12
cmpq $0x1, 0x48(%r15)
pushq $-0x1
popq %rax
cmoveq %rax, %r12
jmp 0x418fc
movq %rbp, %rdi
callq 0x9a68
movq 0x68(%r15), %rsi
incq %rsi
movq 0x8(%rsp), %rdi
callq 0x4385a
movq 0x30(%rsp), %r13
movq 0x18(%rsp), %r12
movq 0x58(%r15), %rax
movq 0x68(%r15), %rcx
shlq $0x5, %rcx
andq $0x0, -0x18(%rax,%rcx)
movq -0x20(%rax,%rcx), %rax
movb $0x0, (%rax)
movq %r13, 0x38(%rsp)
movq %r14, %rdi
movq %r12, %rsi
callq 0x4389b
movq 0x58(%r15), %rax
movq 0x68(%r15), %rcx
shlq $0x5, %rcx
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
movq %r12, %rsi
callq 0x9a20
movq 0x58(%r15), %rax
movq 0x68(%r15), %rcx
shlq $0x5, %rcx
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
pushq $0x9
popq %rsi
callq 0x9440
movq 0x38(%r15), %rax
movq 0x58(%r15), %rcx
movq 0x68(%r15), %rdx
shlq $0x5, %rdx
leaq (%rcx,%rdx), %rdi
addq $-0x20, %rdi
movq (%rax), %rsi
callq 0x9a10
movq 0x58(%r15), %rax
movq 0x68(%r15), %rcx
shlq $0x5, %rcx
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
pushq $0x9
popq %rsi
callq 0x9440
cmpq $0x2, 0x48(%r15)
jb 0x41a52
movq 0x38(%r15), %rax
movq 0x58(%r15), %rcx
movq 0x68(%r15), %rdx
shlq $0x5, %rdx
leaq (%rcx,%rdx), %rdi
addq $-0x20, %rdi
movq 0x20(%rax), %rsi
callq 0x9a10
incq %r13
jmp 0x418a5
movq 0x38(%r15), %rax
movq 0x8(%rax), %rbx
subq $0x1, %rbx
jb 0x41a4a
movq 0x58(%r15), %rax
movq 0x68(%r15), %rcx
shlq $0x5, %rcx
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
pushq $0x49
popq %rsi
callq 0x9440
jmp 0x41a5a
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x41a93
jmp 0x41a93
jmp 0x41a93
movq %rax, %r14
jmp 0x41ab4
movq %rax, %r14
jmp 0x41aaa
movq %rax, %r14
leaq 0x38(%rsp), %rdi
callq 0x9a68
leaq 0x58(%rsp), %rdi
callq 0x9a68
movq 0x8(%rsp), %rdi
callq 0x197f0
movq 0x10(%rsp), %rdi
callq 0x197f0
movq %r14, %rdi
callq 0x9950