LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./range_chaser.h
// Function: RangeChaser::setTopBot(unsigned int, unsigned int, unsigned int, RandomSource&, Ebwt const*)
void setTopBot(TIndexOffU top,
		       TIndexOffU bot,
		       TIndexOffU qlen,
	               RandomSource& rand,
	               const Ebwt* ebwt)
		{
			assert_neq(OFF_MASK, top);
			assert_neq(OFF_MASK, bot);
			assert_gt(bot, top);
			assert_gt(qlen, 0);
			assert(ebwt != NULL);
			ebwt_ = ebwt;
			qlen_ = qlen;
			top_ = top;
			bot_ = bot;
			TIndexOffU spread = bot - top;
			irow_ = top + (rand.nextU32() % spread); // initial row
			done = false;
			cached_ = false;
			reset();
			if(cacheFw_ != NULL || cacheBw_ != NULL) {
				if(spread > cacheThresh_) {
					bool ret = false;
					if(ebwt->fw() && cacheFw_ != NULL) {
						ret = cacheFw_->lookup(top, bot, cacheEnt_);
						if(ret) assert(cacheEnt_.ebwt()->fw());
					} else if(!ebwt->fw() && cacheBw_ != NULL) {
						ret = cacheBw_->lookup(top, bot, cacheEnt_);
						if(ret) assert(!cacheEnt_.ebwt()->fw());
					} else {
						cacheEnt_.reset();
					}
					assert_eq(cacheEnt_.valid(), ret);
					cached_ = ret;
				} else {
					cacheEnt_.reset();
				}
			}
			setRow(irow_);
			assert(chaser_.prepped_ || foundOff() || done);
		}

// Assembly:
pushq %rbx
movl %edx, %r10d
movq %rdi, %rbx
movq %r9, 0x8(%rdi)
movl %ecx, 0x10(%rdi)
movl %esi, 0x18(%rdi)
movl %edx, 0x1c(%rdi)
movl %edx, %ecx
subl %esi, %ecx
movl (%r8), %edx
movl 0x4(%r8), %edi
movl 0x8(%r8), %eax
imull %edx, %eax
addl %edi, %eax
movl %eax, %r11d
shrl $0x10, %r11d
imull %edx, %eax
addl %edi, %eax
movl %eax, 0x8(%r8)
xorl %r11d, %eax
movl $0x0, 0xc(%r8)
xorl %edi, %edi
xorl %edx, %edx
divl %ecx
addl %esi, %edx
movl %edx, 0x20(%rbx)
movb %dil, (%rbx)
movb %dil, 0xa8(%rbx)
movl $0xffffffff, 0x28(%rbx) # imm = 0xFFFFFFFF
movq 0xb0(%rbx), %rdi
movq 0xb8(%rbx), %rax
movq %rdi, %r8
orq %rax, %r8
je 0x311f7
cmpl 0x14(%rbx), %ecx
jbe 0x311bb
cmpb $0x1, 0x10(%r9)
jne 0x311c8
testq %rdi, %rdi
je 0x311e1
leaq 0x80(%rbx), %rcx
jmp 0x311d7
movq $0x0, 0x90(%rbx)
jmp 0x311f7
testq %rax, %rax
je 0x311e1
leaq 0x80(%rbx), %rcx
movq %rax, %rdi
movl %r10d, %edx
callq 0x320e0
jmp 0x311ee
movq $0x0, 0x90(%rbx)
xorl %eax, %eax
movb %al, 0xa8(%rbx)
movl 0x20(%rbx), %edx
movq %rbx, %rdi
movl %edx, %esi
popq %rbx
jmp 0x31202
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./row_chaser.h
// Function: RowChaser::advance()
void advance() {
		// Advance by 1
		assert(!done);
		while(!done) {
			assert(prepped_);
			prepped_ = false;
			if(metrics_ != NULL) metrics_->curBwtOps_++;
			uint64_t newrow = ebwt_->mapLF(sideloc_);
			ASSERT_ONLY(sideloc_.invalidate());
			jumps_++;
			assert_neq(newrow, row_);
			// Update row_ field
			row_ = newrow;
			if(row_ == ebwt_->_zOff) {
				// We arrived at the extreme left-hand end of the reference
				off_ = jumps_;
				done = true;
			} else if((row_ & eh_->_offMask) == row_) {
				// We arrived at a marked row
				off_ = ebwt_->_offs[row_ >> eh_->_offRate] + jumps_;
				done = true;
			}
			prep();
		}
	}

// Assembly:
cmpb $0x0, (%rdi)
jne 0x313a2
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x28(%rdi), %r14
movb $0x0, 0x1(%rbx)
movq 0x40(%rbx), %rax
testq %rax, %rax
je 0x31308
incl 0x4(%rax)
movq 0x8(%rbx), %rdi
movl 0x28(%rbx), %eax
addq 0xb8(%rdi), %rax
movswq 0x34(%rbx), %rcx
movzbl (%rcx,%rax), %edx
movb 0x36(%rbx), %cl
addb %cl, %cl
shrl %cl, %edx
andl $0x3, %edx
cmpb $0x1, 0x32(%rbx)
jne 0x31342
cmpb $0x0, 0x17d(%rdi)
je 0x3134c
movq %r14, %rsi
callq 0x1d45a
jmp 0x31354
movq %r14, %rsi
callq 0x1d61a
jmp 0x31354
movq %r14, %rsi
callq 0x1d276
movl 0x24(%rbx), %edx
incl %edx
movl %edx, 0x24(%rbx)
movl %eax, 0x20(%rbx)
movq 0x8(%rbx), %rsi
cmpl 0x68(%rsi), %eax
je 0x31384
movq 0x18(%rbx), %rcx
movl 0x20(%rcx), %edi
notl %edi
testl %edi, %eax
jne 0x3138a
movb 0x1c(%rcx), %cl
shrl %cl, %eax
movq 0xa8(%rsi), %rcx
addl (%rcx,%rax,4), %edx
movl %edx, 0x38(%rbx)
movb $0x1, (%rbx)
movq %rbx, %rdi
callq 0x31640
cmpb $0x1, (%rbx)
jne 0x312f8
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./range_cache.h
// Function: RangeCacheEntry::install(unsigned int, unsigned int)
void install(TIndexOffU elt, TIndexOffU val) {
		if(ents_ == NULL) {
			// This is not a valid cache entry; do nothing
			return;
		}
		assert(ents_ != NULL);
		assert(ebwt_ != NULL);
		assert_leq(jumps_, val);
		assert_neq(OFF_MASK, val);
		assert_leq(top_ + len_, ebwt_->_eh._len);
		if(elt < len_) {
			val -= jumps_;
			if(verbose_) cout << "Installed reference offset: " << (top_ + elt) << endl;
			ASSERT_ONLY(TIndexOffU sanity = RowChaser::toFlatRefOff(ebwt_, 1, top_ + elt));
			assert_eq(sanity, val);
#ifndef NDEBUG
			for(size_t i = 0; i < len_; i++) {
				if(i == elt) continue;
				assert_neq(val, ents_[i]);
			}
#endif
			ents_[elt] = val;
		} else {
			// ignore install request
			if(verbose_) cout << "Fell off end of cache entry for install: " << (top_ + elt) << endl;
		}
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq 0x10(%rdi), %rax
testq %rax, %rax
je 0x314d2
movl %esi, %ebx
movq %rdi, %r14
cmpl %esi, 0x8(%rdi)
jbe 0x3146e
movl %edx, %ebp
subl 0x4(%r14), %ebp
cmpb $0x1, 0x20(%r14)
jne 0x31467
movq 0x38b98(%rip), %r15     # 0x69fb0
leaq 0x24786(%rip), %rsi     # 0x55ba5
movl $0x1c, %edx
movq %r15, %rdi
callq 0x9560
movl (%r14), %esi
addl %ebx, %esi
movq %r15, %rdi
callq 0x92e0
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x9480
movsbl %al, %esi
movq %r15, %rdi
callq 0x9050
movq %rax, %rdi
callq 0x92f0
movq 0x10(%r14), %rax
movl %ebx, %ecx
movl %ebp, (%rax,%rcx,4)
jmp 0x314d2
cmpb $0x1, 0x20(%r14)
jne 0x314d2
movq 0x38b34(%rip), %r15     # 0x69fb0
leaq 0x2473f(%rip), %rsi     # 0x55bc2
movl $0x29, %edx
movq %r15, %rdi
callq 0x9560
addl (%r14), %ebx
movq %r15, %rdi
movq %rbx, %rsi
callq 0x92e0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x9480
movsbl %al, %esi
movq %rbx, %rdi
callq 0x9050
movq %rax, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x92f0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./range_cache.h
// Function: RangeCacheEntry::get(unsigned int) const
inline TIndexOffU get(TIndexOffU elt) const {
		if(ents_ == NULL) {
			// This is not a valid cache entry; do nothing
			return RANGE_NOT_SET;
		}
		assert(ents_ != NULL);
		assert(ebwt_ != NULL);
		assert_leq(top_ + len_, ebwt_->_eh._len);
		if(elt < len_ && ents_[elt] != RANGE_NOT_SET) {
			if(verbose_) cout << "Retrieved result from cache: " << (top_ + elt) << endl;
			TIndexOffU ret = ents_[elt] + jumps_;
			ASSERT_ONLY(TIndexOffU sanity = RowChaser::toFlatRefOff(ebwt_, 1, top_ + elt));
			assert_eq(sanity, ret);
			return ret;
		} else {
			if(verbose_) cout << "Cache entry not set: " << (top_ + elt) << endl;
			return RANGE_NOT_SET;
		}
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq 0x10(%rdi), %rax
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testq %rax, %rax
je 0x315d0
movl %esi, %r14d
movq %rdi, %rbx
cmpl %esi, 0x8(%rdi)
jbe 0x31577
movl %r14d, %r12d
movl (%rax,%r12,4), %eax
cmpl $-0x1, %eax
je 0x31577
cmpb $0x1, 0x20(%rbx)
jne 0x31570
movq 0x38a94(%rip), %r15     # 0x69fb0
leaq 0x2464e(%rip), %rsi     # 0x55b71
movl $0x1d, %edx
movq %r15, %rdi
callq 0x9560
addl (%rbx), %r14d
movq %r15, %rdi
movq %r14, %rsi
callq 0x92e0
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x9480
movsbl %al, %esi
movq %r14, %rdi
callq 0x9050
movq %rax, %rdi
callq 0x92f0
movq 0x10(%rbx), %rax
movl (%rax,%r12,4), %eax
addl 0x4(%rbx), %eax
movl %eax, %ebp
jmp 0x315d0
cmpb $0x1, 0x20(%rbx)
jne 0x315d0
movq 0x38a2c(%rip), %r15     # 0x69fb0
leaq 0x24604(%rip), %rsi     # 0x55b8f
movl $0x15, %edx
movq %r15, %rdi
callq 0x9560
addl (%rbx), %r14d
movq %r15, %rdi
movq %r14, %rsi
callq 0x92e0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x9480
movsbl %al, %esi
movq %rbx, %rdi
callq 0x9050
movq %rax, %rdi
callq 0x92f0
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./row_chaser.h
// Function: RowChaser::setRow(unsigned int, unsigned int, Ebwt const*)
void setRow(TIndexOffU row, TIndexOffU qlen, const Ebwt* ebwt) {
		assert_neq(OFF_MASK, row);
		assert_gt(qlen, 0);
		assert(ebwt != NULL);
		ebwt_ = ebwt;
		eh_ = &ebwt->_eh;
		row_ = row;
		qlen_ = qlen;
		ASSERT_ONLY(sideloc_.invalidate());
		if(row_ == ebwt_->_zOff) {
			// We arrived at the extreme left-hand end of the reference
			off_ = 0;
			done = true;
			return;
		} else if((row_ & eh_->_offMask) == row_) {
			// We arrived at a marked row
			off_ = ebwt_->_offs[row_ >> eh_->_offRate];
			done = true;
			return;
		}
		done = false;
		jumps_ = 0;
		off_ = OFF_MASK;
		prepped_ = false;
		prep();
	}

// Assembly:
movq %rcx, %rax
movq %rcx, 0x8(%rdi)
addq $0xf8, %rcx
movq %rcx, 0x18(%rdi)
movl %esi, 0x20(%rdi)
movl %edx, 0x10(%rdi)
cmpl %esi, 0x68(%rax)
jne 0x31602
movl $0x0, 0x38(%rdi)
jmp 0x31623
movl 0x118(%rax), %ecx
notl %ecx
testl %ecx, %esi
jne 0x31627
movb 0x114(%rax), %cl
shrl %cl, %esi
movq 0xa8(%rax), %rax
movl (%rax,%rsi,4), %eax
movl %eax, 0x38(%rdi)
movb $0x1, (%rdi)
retq
movw $0x0, (%rdi)
movl $0x0, 0x24(%rdi)
movl $0xffffffff, 0x38(%rdi) # imm = 0xFFFFFFFF
jmp 0x31640
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./row_chaser.h
// Function: RowChaser::prep()
void prep() {
		if(!done) {
			assert(!prepped_);
			assert(!sideloc_.valid());
			assert_leq(row_, eh_->_len);
			sideloc_.initFromRow(row_, *eh_, (const uint8_t*)ebwt_->_ebwt);
			assert(sideloc_.valid());
		}
		prepped_ = true;
	}

// Assembly:
pushq %rbx
movq %rdi, %rbx
cmpb $0x0, (%rdi)
jne 0x31664
leaq 0x28(%rbx), %rdi
movl 0x20(%rbx), %esi
movq 0x8(%rbx), %rax
movq 0x18(%rbx), %rdx
movq 0xb8(%rax), %rcx
callq 0x1b036
movb $0x1, 0x1(%rbx)
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./bitset.h
// Function: FixedBitset<1024>::str[abi:cxx11]() const
std::string str() const {
		std::ostringstream oss;
		for(int i = (int)size()-1; i >= 0; i--) {
			oss << (test(i)? "1" : "0");
		}
		return oss.str();
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x178, %rsp            # imm = 0x178
movq %rsi, %r14
movq %rdi, %rbx
movq %rsp, %r15
movq %r15, %rdi
callq 0x9620
movl 0x4(%r14), %ebp
leaq 0x25635(%rip), %r12     # 0x5761e
leaq 0x21912(%rip), %r13     # 0x53902
testl %ebp, %ebp
jle 0x3201a
decl %ebp
movl %ebp, %eax
shrl $0x5, %eax
movl 0x8(%r14,%rax,4), %eax
btl %ebp, %eax
movq %r12, %rsi
jae 0x3200b
movq %r13, %rsi
movl $0x1, %edx
movq %r15, %rdi
callq 0x9560
jmp 0x31ff0
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x97e0
movq 0x37f6a(%rip), %rsi     # 0x69f98
movq %rsp, %rdi
callq 0x9220
leaq 0x70(%rsp), %rdi
callq 0x9180
movq %rbx, %rax
addq $0x178, %rsp            # imm = 0x178
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x32057
movq %rax, %rbx
movq 0x37f37(%rip), %rsi     # 0x69f98
movq %rsp, %rdi
callq 0x9220
leaq 0x70(%rsp), %rdi
callq 0x9180
movq %rbx, %rdi
callq 0x9930
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./range_cache.h
// Function: RangeCache::lookup(unsigned int, unsigned int, RangeCacheEntry&)
bool lookup(TIndexOffU top, TIndexOffU bot, RangeCacheEntry& ent) {
		if(ebwt_ == NULL || lim_ == 0) return false;
		assert_gt(bot, top);
		ent.reset();
		TMapItr itr = map_.find(top);
		if(itr == map_.end()) {
			// No cache entry for the given 'top' offset
			if(closed_) {
				return false; // failed to get cache entry
			} else {
				if(pool_.closed()) {
					closed_ = true;
					return false; // failed to get cache entry
				}
			}
			// Use the tunnel
			bool ret = tunnel(top, bot, ent);
			return ret;
		} else {
			// There is a cache entry for the given 'top' offset
			TIndexOffU ret = itr->second;
			ent.init(pool_, top, ret, ebwt_);
			return true; // success
		}
	}

// Assembly:
xorl %eax, %eax
cmpq $0x0, 0x58(%rdi)
je 0x3213f
cmpl $0x0, (%rdi)
je 0x3213f
movq $0x0, 0x10(%rcx)
movq 0x18(%rdi), %r8
testq %r8, %r8
je 0x32129
leaq 0x10(%rdi), %r9
movq %r9, %rax
xorl %r10d, %r10d
cmpl %esi, 0x20(%r8)
setb %r10b
cmovaeq %r8, %rax
movq 0x10(%r8,%r10,8), %r8
testq %r8, %r8
jne 0x32106
cmpq %r9, %rax
je 0x32129
cmpl %esi, 0x20(%rax)
jbe 0x32140
cmpb $0x0, 0x50(%rdi)
jne 0x3213d
cmpb $0x1, 0x48(%rdi)
jne 0x32188
movb $0x1, 0x50(%rdi)
xorl %eax, %eax
retq
movl 0x24(%rax), %eax
movq 0x58(%rdi), %rdx
movl %esi, (%rcx)
movq %rdx, 0x18(%rcx)
movq 0x40(%rdi), %rdx
leaq (%rdx,%rax,4), %rax
movl (%rax), %edx
testl %edx, %edx
js 0x32164
movl $0x0, 0x4(%rcx)
jmp 0x32178
andl $0x7fffffff, %edx       # imm = 0x7FFFFFFF
movl %edx, 0x4(%rcx)
movl 0x4(%rax), %eax
shlq $0x2, %rax
addq 0x40(%rdi), %rax
movl (%rax), %edx
addq $0x4, %rax
movl %edx, 0x8(%rcx)
movq %rax, 0x10(%rcx)
movb $0x1, %al
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./aligner_metrics.h
// Function: AlignerMetrics::nextRead(SDnaStringExpandable<25, 2> const&)
void nextRead(const BTDnaString& read) {
		if(!first_) {
			finishRead();
		}
		first_ = false;
		float ent = entropyDna5(read);
		curIsLowEntropy_ = (ent < 0.75f);
		curIsHomoPoly_ = (ent < 0.001f);
		curHadRanges_ = false;
		curBwtOps_ = 0;
		curBacktracks_ = 0;
		// Count Ns
		curNumNs_ = 0;
		const size_t len = read.length();
		for(size_t i = 0; i < len; i++) {
			if((int)read[i] == 4) curNumNs_++;
		}
	}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rsi, %rbx
movq %rdi, %r14
cmpb $0x0, 0x8(%rdi)
jne 0x32825
movq %r14, %rdi
callq 0x329ce
movb $0x0, 0x8(%r14)
xorps %xmm0, %xmm0
movaps %xmm0, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
movq $0x0, 0x30(%rsp)
movq 0x20(%rbx), %rax
testq %rax, %rax
je 0x328de
movq 0x8(%rbx), %rcx
xorl %edx, %edx
movsbq (%rcx,%rdx), %rsi
incq 0x10(%rsp,%rsi,8)
incq %rdx
cmpq %rdx, %rax
jne 0x32853
movq 0x30(%rsp), %rcx
testq %rcx, %rcx
je 0x328de
movq 0x10(%rsp), %r8
movq 0x18(%rsp), %rsi
cmpq %rsi, %r8
setb %dil
movq 0x20(%rsp), %rdx
cmpq %rdx, %r8
setb %r9b
orb %dil, %r9b
movq 0x28(%rsp), %rdi
cmpq %rdi, %r8
setb %r10b
orb %r9b, %r10b
je 0x328c2
cmpq %rdx, %rsi
setb %r8b
cmpq %rdi, %rsi
setb %r9b
orb %r8b, %r9b
je 0x328cc
cmpq %rdi, %rdx
jae 0x328d6
addq %rcx, %rdi
movq %rdi, 0x28(%rsp)
jmp 0x328de
addq %rcx, %r8
movq %r8, 0x10(%rsp)
jmp 0x328de
addq %rcx, %rsi
movq %rsi, 0x18(%rsp)
jmp 0x328de
addq %rcx, %rdx
movq %rdx, 0x20(%rsp)
testq %rax, %rax
js 0x328ed
xorps %xmm0, %xmm0
cvtsi2ss %rax, %xmm0
jmp 0x32905
movq %rax, %rcx
shrq %rcx
andl $0x1, %eax
orq %rcx, %rax
xorps %xmm0, %xmm0
cvtsi2ss %rax, %xmm0
addss %xmm0, %xmm0
movss %xmm0, 0x4(%rsp)
xorps %xmm0, %xmm0
xorl %r15d, %r15d
movq 0x10(%rsp,%r15,8), %rax
testq %rax, %rax
je 0x32969
movss %xmm0, 0xc(%rsp)
js 0x3292d
xorps %xmm0, %xmm0
cvtsi2ss %rax, %xmm0
jmp 0x32945
movq %rax, %rcx
shrq %rcx
andl $0x1, %eax
orq %rcx, %rax
xorps %xmm0, %xmm0
cvtsi2ss %rax, %xmm0
addss %xmm0, %xmm0
divss 0x4(%rsp), %xmm0
movss %xmm0, 0x8(%rsp)
callq 0x99d0
mulss 0x8(%rsp), %xmm0
movss 0xc(%rsp), %xmm1
addss %xmm0, %xmm1
movaps %xmm1, %xmm0
incq %r15
cmpq $0x4, %r15
jne 0x32911
ucomiss 0x1fb0b(%rip), %xmm0    # 0x52484
seta 0x9(%r14)
ucomiss 0x1fb03(%rip), %xmm0    # 0x52488
seta 0xa(%r14)
movb $0x0, 0xb(%r14)
movq $0x0, (%r14)
movl $0x0, 0xc(%r14)
movq 0x20(%rbx), %rax
testq %rax, %rax
je 0x329c3
xorl %ecx, %ecx
xorl %edx, %edx
movq 0x8(%rbx), %rsi
cmpb $0x4, (%rsi,%rcx)
jne 0x329bb
incl %edx
movl %edx, 0xc(%r14)
incq %rcx
cmpq %rcx, %rax
jne 0x329ab
addq $0x40, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ref_aligner.h
// Function: RefAligner::find(unsigned int, unsigned long, BitPairReference const*, SDnaStringExpandable<25, 2> const&, SStringExpandable<char, 25, 2, 0> const&, unsigned int, unsigned int, EList<Range, 128>&, EList<unsigned int, 128>&, std::set<std::pair<unsigned long, unsigned long>, std::less<std::pair<unsigned long, unsigned long>>, std::allocator<std::pair<unsigned long, unsigned long>>>*, unsigned int, bool)
virtual void find(uint32_t numToFind,
	                  const size_t tidx,
	                  const BitPairReference *refs,
	                  const BTDnaString& qry,
	                  const BTString& quals,
	                  TIndexOffU begin,
	                  TIndexOffU end,
	                  TRangeVec& ranges,
	                  EList<TIndexOffU>& results,
	                  TSetPairs* pairs = NULL,
	                  TIndexOffU aoff = OFF_MASK,
	                  bool seedOnLeft = false)
		{
			assert_gt(numToFind, 0);
			assert_gt(end, begin);
			TIndexOffU spread = end - begin;
			TIndexOffU spreadPlus = spread + 12;
			// Make sure the buffer is large enough to accommodate the spread
			if(spreadPlus > this->refbufSz_) {
				this->newBuf(spreadPlus);
			}
			// Read in the relevant stretch of the reference string
			int offset = refs->getStretch(this->refbuf_, tidx, begin, spread);
			uint8_t *buf = ((uint8_t*)this->refbuf_) + offset;
			// Look for alignments
			ASSERT_ONLY(uint32_t irsz = (uint32_t)ranges.size());
			anchor64Find(numToFind, tidx, buf, qry, quals, begin,
				     end, ranges, results, pairs, aoff, seedOnLeft);
#ifndef NDEBUG
			for(size_t i = irsz; i < results.size(); i++) {
				assert_eq(ranges[i].numMms, ranges[i].mms.size());
				assert_eq(ranges[i].numMms, ranges[i].refcs.size());
			}
#endif
		}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, 0x10(%rsp)
movq %r8, 0x8(%rsp)
movq %rcx, %r13
movq %rdx, %r15
movl %esi, %ebp
movq %rdi, %r12
movl 0x58(%rsp), %ebx
movl 0x50(%rsp), %r14d
subl %r14d, %ebx
leal 0xc(%rbx), %esi
cmpl 0x20(%rdi), %esi
jbe 0x3690f
movq %r12, %rdi
callq 0x37448
movq 0x18(%r12), %rsi
movl %r14d, %ecx
movl %ebx, %r8d
movq %r13, %rdi
movq %r15, %rdx
callq 0x3751a
movslq %eax, %rcx
addq 0x18(%r12), %rcx
movq (%r12), %rax
movq 0x18(%rax), %rax
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq 0x8(%rsp), %r8
movq 0x10(%rsp), %r9
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmpq *%rax
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ref_aligner.h
// Function: RefAligner::newBuf(unsigned int)
void newBuf(uint32_t newsz) {
		if(freeRefbuf_) {
			delete[] refbuf_;
		}
		try {
			refbuf_ = new uint32_t[(newsz + 3) / 4];
			if(refbuf_ == NULL) throw std::bad_alloc();
		} catch(std::bad_alloc& e) {
			cerr << "Error: Could not allocate reference-space alignment buffer of " << newsz << "B" << endl;
			throw 1;
		}
		refbufSz_ = newsz;
		freeRefbuf_ = true;
	}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
cmpb $0x1, 0x4024(%rdi)
jne 0x37468
movq 0x18(%r14), %rdi
testq %rdi, %rdi
je 0x37468
callq 0x95e0
leal 0x3(%rbx), %edi
andl $-0x4, %edi
callq 0x9030
movq %rax, 0x18(%r14)
movl %ebx, 0x20(%r14)
movb $0x1, 0x4024(%r14)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
cmpl $0x1, %edx
jne 0x37509
movq %r14, %rdi
callq 0x91a0
movq 0x32b4e(%rip), %rdi     # 0x69ff0
leaq 0x1e7a7(%rip), %rsi     # 0x55c50
movl $0x3e, %edx
callq 0x9560
movl %ebx, %esi
movq 0x32b34(%rip), %rdi     # 0x69ff0
callq 0x92e0
movq %rax, %rbx
leaq 0x1e7c4(%rip), %rsi     # 0x55c8f
movl $0x1, %edx
movq %rax, %rdi
callq 0x9560
movq %rbx, %rdi
callq 0x91f0
movl $0x4, %edi
callq 0x9200
movl $0x1, (%rax)
movq 0x32a41(%rip), %rsi     # 0x69f38
movq %rax, %rdi
xorl %edx, %edx
callq 0x98f0
movq %rax, %r14
callq 0x9840
movq %r14, %rdi
callq 0x9930
movq %rax, %rdi
callq 0x1afa3
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./aligner.h
// Function: PairedBWAlignerV1<EbwtRangeSource>::advance()
virtual bool advance() {
		assert(!this->done);
		if(doneFw_ && doneFwFirst_) {
			if(verbose2_) cout << "--" << endl;
			chaseL_        = &chaseL_rc_;
			chaseR_        = &chaseR_rc_;
			delayedchaseL_ = &delayedchaseL_rc_;
			delayedchaseR_ = &delayedchaseR_rc_;
			drL_           = &drL_rc_;
			drR_           = &drR_rc_;
			offsLarr_      = offsLarr_rc_;
			offsRarr_      = offsRarr_rc_;
			rangesLarr_    = rangesLarr_rc_;
			rangesRarr_    = rangesRarr_rc_;
			offsLsz_       = &offsLsz_rc_;
			offsRsz_       = &offsRsz_rc_;
			donePair_      = &this->done;
			fwL_           = !fw2_;
			fwR_           = !fw1_;
			doneFwFirst_   = false;
			mixedAttempts_ = 0;
		}
		bool chasing = *chaseL_ || *chaseR_;
		if(chasing && !rchase_->foundOff() && !rchase_->done) {
			rchase_->advance();
			return false;
		}
		advanceOrientation(!doneFw_);
		if(this->done) {
			if(verbose2_) cout << "----" << endl;
			sinkPt_->finishRead(*patsrc_, true, true);
		}
		return this->done;
	}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpb $0x1, 0x68(%rdi)
jne 0x3b78c
cmpb $0x1, 0x69(%rbx)
jne 0x3b78c
cmpb $0x1, 0x22a8(%rbx)
jne 0x3b702
movq 0x2e8e9(%rip), %r14     # 0x69fb0
leaq 0x1a5ed(%rip), %rsi     # 0x55cbb
movl $0x2, %edx
movq %r14, %rdi
callq 0x9560
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x9480
movsbl %al, %esi
movq %r14, %rdi
callq 0x9050
movq %rax, %rdi
callq 0x92f0
movups 0x2178(%rbx), %xmm0
movups %xmm0, 0x21d8(%rbx)
movups 0x2188(%rbx), %xmm0
movups %xmm0, 0x21e8(%rbx)
movups 0x2198(%rbx), %xmm0
movups %xmm0, 0x21f8(%rbx)
movups 0x21a8(%rbx), %xmm0
movups %xmm0, 0x2208(%rbx)
movups 0x21b8(%rbx), %xmm0
movups %xmm0, 0x2218(%rbx)
movups 0x21c8(%rbx), %xmm0
movups %xmm0, 0x2228(%rbx)
leaq 0x8(%rbx), %rax
movq %rax, 0x2238(%rbx)
movb 0xb4(%rbx), %al
movb 0xb5(%rbx), %cl
xorb $0x1, %cl
movb %cl, 0x2240(%rbx)
xorb $0x1, %al
movb %al, 0x2241(%rbx)
movb $0x0, 0x69(%rbx)
movl $0x0, 0xb0(%rbx)
movq 0x21d8(%rbx), %rax
cmpb $0x0, (%rax)
jne 0x3b7a4
movq 0x21e0(%rbx), %rax
cmpb $0x1, (%rax)
jne 0x3b7ba
movq 0xb8(%rbx), %rdi
cmpl $-0x1, 0x28(%rdi)
jne 0x3b7ba
cmpb $0x0, (%rdi)
je 0x3b83a
movzbl 0x68(%rbx), %esi
xorl $0x1, %esi
movq %rbx, %rdi
callq 0x3bb70
cmpb $0x1, 0x8(%rbx)
jne 0x3b83f
cmpb $0x1, 0x22a8(%rbx)
jne 0x3b81a
movq 0x2e7d1(%rip), %r14     # 0x69fb0
leaq 0x1a4d3(%rip), %rsi     # 0x55cb9
movl $0x4, %edx
movq %r14, %rdi
callq 0x9560
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x9480
movsbl %al, %esi
movq %r14, %rdi
callq 0x9050
movq %rax, %rdi
callq 0x92f0
movq 0x58(%rbx), %rsi
movq 0x88(%rbx), %rdi
movq (%rdi), %rax
movl $0x1, %edx
movl $0x1, %ecx
callq *0x10(%rax)
movb 0x8(%rbx), %al
jmp 0x3b841
callq 0x3109c
xorl %eax, %eax
andb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./aligner.h
// Function: PairedBWAlignerV2<EbwtRangeSource>::~PairedBWAlignerV2()
virtual ~PairedBWAlignerV2() {
		delete driver_; driver_ = NULL;
		delete params_; params_ = NULL;
		if(paramsSe1_ != NULL) {
			delete paramsSe1_; paramsSe1_ = NULL;
			delete paramsSe2_; paramsSe2_ = NULL;
		}
		delete rchase_; rchase_ = NULL;
		delete[] btCnt_; btCnt_ = NULL;
		delete refAligner_; refAligner_ = NULL;
		sinkPtFactory_.destroy(sinkPt_); sinkPt_ = NULL;
		if(sinkPtSe1_ != NULL) {
			sinkPtFactory_.destroy(sinkPtSe1_); sinkPtSe1_ = NULL;
			sinkPtFactory_.destroy(sinkPtSe2_); sinkPtSe2_ = NULL;
		}
	}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x2c81c(%rip), %rax     # 0x69440
movq %rax, (%rdi)
movq 0xd0(%rdi), %rdi
testq %rdi, %rdi
je 0x3cc39
movq (%rdi), %rax
callq *0x8(%rax)
xorl %r14d, %r14d
movq %r14, 0xd0(%rbx)
movq 0x98(%rbx), %rdi
movl $0x18, %esi
callq 0x94c0
movq %r14, 0x98(%rbx)
movq 0xa0(%rbx), %rdi
testq %rdi, %rdi
je 0x3cc93
movl $0x18, %esi
callq 0x94c0
xorl %r14d, %r14d
movq %r14, 0xa0(%rbx)
movq 0xa8(%rbx), %rdi
movl $0x18, %esi
callq 0x94c0
movq %r14, 0xa8(%rbx)
movq 0xc8(%rbx), %rdi
movl $0xc8, %esi
callq 0x94c0
movq $0x0, 0xc8(%rbx)
movq 0xe8(%rbx), %rdi
testq %rdi, %rdi
je 0x3ccc0
callq 0x95e0
movq $0x0, 0xe8(%rbx)
movq 0x70(%rbx), %rdi
testq %rdi, %rdi
je 0x3ccda
movq (%rdi), %rax
callq *0x8(%rax)
movq $0x0, 0x70(%rbx)
movq 0x78(%rbx), %rdi
movq 0x80(%rbx), %rsi
movq (%rdi), %rax
callq *0x20(%rax)
movq $0x0, 0x80(%rbx)
movq 0x88(%rbx), %rsi
testq %rsi, %rsi
je 0x3cd3b
movq 0x78(%rbx), %rdi
movq (%rdi), %rax
callq *0x20(%rax)
movq $0x0, 0x88(%rbx)
movq 0x78(%rbx), %rdi
movq 0x90(%rbx), %rsi
movq (%rdi), %rax
callq *0x20(%rax)
movq $0x0, 0x90(%rbx)
leaq 0x120(%rbx), %rdi
callq 0x3bb20
addq $0xf0, %rbx
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x3bb20
movq %rax, %rdi
callq 0x1afa3
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./aligner.h
// Function: PairedBWAlignerV2<EbwtRangeSource>::resolveOutstanding(std::pair<unsigned int, unsigned int> const&, unsigned int, Range const&)
void resolveOutstanding(const UPair& off,
	                        const TIndexOffU tlen,
	                        const Range& range)
	{
		assert(!this->done);
		if(!donePe_) {
			bool ret = resolveOutstandingInRef(off, tlen, range);
			if(++mixedAttempts_ > mixedAttemptLim_ || ret) {
				// Give up on this pair
				donePe_ = true;
				if(sinkPtSe1_ != NULL) {
					if(doneSe1_) driver_->removeMate(1);
					if(doneSe2_) driver_->removeMate(2);
				}
			}
			this->done = (donePe_ && (!sinkPt_->empty() || sinkPtSe1_ == NULL || (doneSe1_ && doneSe2_)));
		}
		if(!this->done && sinkPtSe1_ != NULL) {
			bool doneSe = (range.mate1 ? doneSe1_ : doneSe2_);
			if(!doneSe) {
				// Hold onto this single-end alignment in case we don't
				// find any paired alignments
				reportSe(range, off, tlen);
			}
			this->done = doneSe1_ && doneSe2_ && donePe_;
		}
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %r14
movl %edx, %ebp
movq %rsi, %r15
movq %rdi, %rbx
movb 0x69(%rdi), %al
cmpb $0x1, %al
jne 0x3d225
movb 0x8(%rbx), %cl
jmp 0x3d2c0
movq %rbx, %rdi
movq %r15, %rsi
movl %ebp, %edx
movq %r14, %rcx
callq 0x3d31c
movl 0xb8(%rbx), %ecx
movl 0xbc(%rbx), %edx
incl %edx
movl %edx, 0xbc(%rbx)
testb %al, %al
jne 0x3d251
cmpl %ecx, %edx
jbe 0x3d28f
movb $0x1, 0x69(%rbx)
cmpq $0x0, 0x88(%rbx)
je 0x3d28f
cmpb $0x1, 0x6a(%rbx)
jne 0x3d277
movq 0xd0(%rbx), %rdi
movq (%rdi), %rax
movl $0x1, %esi
callq *0x48(%rax)
cmpb $0x1, 0x6b(%rbx)
jne 0x3d28f
movq 0xd0(%rbx), %rdi
movq (%rdi), %rax
movl $0x2, %esi
callq *0x48(%rax)
movb 0x69(%rbx), %al
cmpb $0x1, %al
jne 0x3d2bb
movq 0x80(%rbx), %rcx
cmpq $0x0, 0x58(%rcx)
movb $0x1, %cl
jne 0x3d2bd
cmpq $0x0, 0x88(%rbx)
je 0x3d2bd
cmpb $0x1, 0x6a(%rbx)
jne 0x3d2bb
movb 0x6b(%rbx), %cl
jmp 0x3d2bd
xorl %ecx, %ecx
movb %cl, 0x8(%rbx)
testb $0x1, %cl
jne 0x3d310
cmpq $0x0, 0x88(%rbx)
je 0x3d310
movzbl 0x6a(%rbx), %edx
movzbl 0x6b(%rbx), %ecx
cmpb $0x0, 0x15(%r14)
movl %ecx, %esi
cmovnel %edx, %esi
testb $0x1, %sil
jne 0x3d300
movq (%r15), %rdx
movq %rbx, %rdi
movq %r14, %rsi
movl %ebp, %ecx
callq 0x3d784
movb 0x69(%rbx), %al
movb 0x6a(%rbx), %dl
movb 0x6b(%rbx), %cl
andb %dl, %cl
movzbl %al, %eax
xorl %edx, %edx
testb $0x1, %cl
cmovnel %eax, %edx
movb %dl, 0x8(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ebwt_search_util.h
// Function: PartialAlignmentManager::getPartialsUnsync(unsigned int, EList<PartialAlignment, 128>&)
void getPartialsUnsync(uint32_t patid, EList<PartialAlignment>& ps) {
		assert_eq(0, ps.size());
		if(_partialsMap.find(patid) == _partialsMap.end()) {
			return;
		}
		PartialAlignment al;
		al.u64.u64 = _partialsMap[patid].u64.u64;
		uint32_t type = al.unk.type;
		if(type == 0) {
			// singleton
			ps.push_back(al);
		} else {
			// list
			assert_eq(1, type);
			uint32_t off = (uint32_t)al.off.off;
			do {
				assert_lt(off, _partialsList.size());
				ASSERT_ONLY(type = _partialsList[off].entry.type);
				assert(type == 2 || type == 3);
#ifndef NDEBUG
				// Make sure this entry isn't equal to any other entry
				for(size_t i = 0; i < ps.size(); i++) {
					assert(validPartialAlignment(ps[i]));
					assert(!samePartialAlignment(ps[i], _partialsList[off]));
				}
#endif
				assert(validPartialAlignment(_partialsList[off]));
				ps.push_back(_partialsList[off]);
				ASSERT_ONLY(uint32_t pos0 = ps.back().entry.pos0);
				ASSERT_ONLY(uint32_t pos1 = ps.back().entry.pos1);
				ASSERT_ONLY(uint32_t pos2 = ps.back().entry.pos2);
				assert(pos1 == 0xffff || pos0 != pos1);
				assert(pos2 == 0xffff || pos0 != pos2);
				assert(pos2 == 0xffff || pos1 != pos2);
			} while(_partialsList[off++].entry.type == 2);
			assert_eq(3, _partialsList[off-1].entry.type);
		}
		assert_gt(ps.size(), 0);
	}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %esi, 0xc(%rsp)
movq 0x10(%rdi), %rax
testq %rax, %rax
je 0x3e110
movq %rdx, %rbx
movq %rdi, %r14
leaq 0x8(%rdi), %rdx
movq %rdx, %rcx
xorl %edi, %edi
cmpl %esi, 0x20(%rax)
setb %dil
cmovaeq %rax, %rcx
movq 0x10(%rax,%rdi,8), %rax
testq %rax, %rax
jne 0x3e09b
cmpq %rdx, %rcx
je 0x3e110
cmpl %esi, 0x20(%rcx)
ja 0x3e110
leaq 0xc(%rsp), %rsi
movq %r14, %rdi
callq 0x40ca6
movq (%rax), %r15
movq %r15, 0x10(%rsp)
movq %r15, %rax
shrq $0x3e, %rax
jne 0x3e0e9
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x40062
jmp 0x3e110
movq 0x38(%r14), %rax
movl %r15d, %r12d
leaq (%rax,%r12,8), %rsi
movq %rbx, %rdi
callq 0x40062
incl %r15d
movq 0x38(%r14), %rax
movq (%rax,%r12,8), %rcx
shrq $0x3e, %rcx
cmpl $0x2, %ecx
je 0x3e0ed
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ebwt_search_backtrack.h
// Function: GreedyDFSRangeSource::setMuts(EList<QueryMutation, 128>*)
void setMuts(EList<QueryMutation>* muts) {
		if(_muts != NULL) {
			// Undo previous mutations
			assert_gt(_muts->size(), 0);
			undoPartialMutations();
		}
		_muts = muts;
		if(_muts != NULL) {
			assert_gt(_muts->size(), 0);
			applyPartialMutations();
		}
	}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
cmpq $0x0, 0xb0(%rdi)
je 0x3e2f2
movq %rbx, %rdi
callq 0x400f4
movq %r14, 0xb0(%rbx)
testq %r14, %r14
je 0x3e30d
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x40376
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ebwt_search_backtrack.h
// Function: GreedyDFSRangeSource::tallyNs(int&, int&)
bool tallyNs(int& nsInSeed, int& nsInFtab) {
		const Ebwt& ebwt = *_ebwt;
		int ftabChars = ebwt._eh._ftabChars;
		// Count Ns in the seed region of the read and short-circuit if
		// the configuration of Ns guarantees that there will be no
		// valid alignments given the backtracking constraints.
		for(size_t i = 0; i < _3revOff; i++) {
			if((int)(*_qry)[_qlen-i-1] == 4) {
				nsInSeed++;
				if(nsInSeed == 1) {
					if(i < _unrevOff) {
						return false; // Exceeded mm budget on Ns alone
					}
				} else if(nsInSeed == 2) {
					if(i < _1revOff) {
						return false; // Exceeded mm budget on Ns alone
					}
				} else if(nsInSeed == 3) {
					if(i < _2revOff) {
						return false; // Exceeded mm budget on Ns alone
					}
				} else {
					assert_gt(nsInSeed, 3);
					return false;     // Exceeded mm budget on Ns alone
				}
			}
		}
		// Calculate the number of Ns there are in the region that
		// would get jumped over if the ftab were used.
		for(size_t i = 0; i < (size_t)ftabChars && i < _qlen; i++) {
			if((int)(*_qry)[_qlen-i-1] == 4) nsInFtab++;
		}
		return true;
	}

// Assembly:
movq 0x20(%rdi), %rax
movslq 0x124(%rax), %rcx
cmpl $0x0, 0x3c(%rdi)
je 0x3e58a
movq $-0x1, %rax
xorl %r8d, %r8d
movq (%rdi), %r9
movq 0x8(%r9), %r9
addq 0x8(%rdi), %r9
cmpb $0x4, (%rax,%r9)
jne 0x3e57b
movl (%rsi), %r9d
leal 0x1(%r9), %r10d
movl %r10d, (%rsi)
cmpl $0x2, %r9d
je 0x3e572
cmpl $0x1, %r9d
je 0x3e56c
testl %r9d, %r9d
jne 0x3e5bf
movl 0x30(%rdi), %r9d
jmp 0x3e576
movl 0x34(%rdi), %r9d
jmp 0x3e576
movl 0x38(%rdi), %r9d
cmpq %r9, %r8
jb 0x3e5bf
incq %r8
movl 0x3c(%rdi), %r9d
decq %rax
cmpq %r9, %r8
jb 0x3e539
movb $0x1, %al
testl %ecx, %ecx
je 0x3e5be
movq $-0x1, %rsi
xorl %r8d, %r8d
movq 0x8(%rdi), %r9
cmpq %r9, %r8
jae 0x3e5be
movq (%rdi), %r10
addq 0x8(%r10), %r9
cmpb $0x4, (%rsi,%r9)
jne 0x3e5b3
incl (%rdx)
incq %r8
decq %rsi
cmpq %r8, %rcx
jne 0x3e59a
retq
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ebwt_search_backtrack.h
// Function: GreedyDFSRangeSource::undoPartialMutations()
void undoPartialMutations() {
		if(_muts == NULL) {
			// No mutations to undo
			return;
		}
		for(size_t i = 0; i < _muts->size(); i++) {
			const QueryMutation& m = (*_muts)[i];
			assert_lt(m.pos, _qlen);
			assert_leq(m.oldBase, 4);
			assert_lt(m.newBase, 4);
			assert_neq(m.oldBase, m.newBase);
			assert_eq((uint32_t)((*_qry)[m.pos]), (uint32_t)m.newBase);
			(*_qry)[m.pos] = (char)m.oldBase; // undo it
		}
	}

// Assembly:
movq 0xb0(%rdi), %rax
testq %rax, %rax
je 0x4012f
cmpq $0x0, 0x18(%rax)
je 0x4012f
xorl %ecx, %ecx
movq 0x8(%rax), %rax
movb 0x2(%rax,%rcx,4), %dl
movq (%rdi), %rsi
movzwl (%rax,%rcx,4), %eax
movq 0x8(%rsi), %rsi
movb %dl, (%rsi,%rax)
incq %rcx
movq 0xb0(%rdi), %rax
cmpq 0x18(%rax), %rcx
jb 0x40109
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ebwt_search_backtrack.h
// Function: GreedyDFSRangeSource::promotePartialMutations(int)
void promotePartialMutations(int stackDepth) {
		if(_muts == NULL) {
			// No mutations to undo
			return;
		}
		size_t numMuts = _muts->size();
		assert_leq(numMuts, _qlen);
		for(size_t i = 0; i < numMuts; i++) {
			// Entries in _mms[] are in terms of offset into
			// _qry - not in terms of offset from 3' or 5' end
			assert_lt(stackDepth + i, _qlen);
			// All partial-alignment mutations should fall
			// within bounds
			assert_lt((*_muts)[i].pos, _qlen);
			// All partial-alignment mutations should fall
			// within unrevisitable region
			assert_lt(_qlen - (*_muts)[i].pos - 1, _unrevOff);
#ifndef NDEBUG
			// Shouldn't be any overlap between mismatched positions
			// and positions that mismatched in the partial alignment.
			for(size_t j = 0; j < stackDepth + i; j++) {
				assert_neq(_mms[j], (uint32_t)(*_muts)[i].pos);
			}
#endif
			if(_mms.size() <= stackDepth + i) {
				assert_eq(_mms.size(), stackDepth + i);
				_mms.push_back((*_muts)[i].pos);
			} else {
				_mms[stackDepth + i] = (*_muts)[i].pos;
			}
			if(_refcs.size() <= stackDepth + i) {
				assert_eq(_refcs.size(), stackDepth + i);
				_refcs.push_back("ACGT"[(*_muts)[i].newBase]);
			} else {
				_refcs[stackDepth + i] = "ACGT"[(*_muts)[i].newBase];
			}
		}
	}

// Assembly:
movq 0xb0(%rdi), %rax
testq %rax, %rax
je 0x4022a
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq 0x18(%rax), %rbp
testq %rbp, %rbp
je 0x4021c
movq %rdi, %rbx
movslq %esi, %r12
leaq 0x58(%rdi), %rax
movq %rax, 0x10(%rsp)
leaq 0x78(%rdi), %r15
xorl %r13d, %r13d
leaq 0x123dd(%rip), %r14     # 0x52555
cmpq %r12, 0x70(%rbx)
jbe 0x40198
movq 0x60(%rbx), %rax
movq 0xb0(%rbx), %rcx
movq 0x8(%rcx), %rcx
movzwl (%rcx,%r13), %ecx
movl %ecx, (%rax,%r12,4)
jmp 0x401bb
movq 0xb0(%rbx), %rax
movq 0x8(%rax), %rax
movzwl (%rax,%r13), %eax
movl %eax, 0xc(%rsp)
movq 0x10(%rsp), %rdi
leaq 0xc(%rsp), %rsi
callq 0x22bde
cmpq %r12, 0x90(%rbx)
jbe 0x401e6
movq 0x80(%rbx), %rax
movq 0xb0(%rbx), %rcx
movq 0x8(%rcx), %rcx
movzbl 0x3(%rcx,%r13), %ecx
movb (%rcx,%r14), %cl
movb %cl, (%rax,%r12)
jmp 0x4020c
movq 0xb0(%rbx), %rax
movq 0x8(%rax), %rax
movzbl 0x3(%rax,%r13), %eax
movb (%rax,%r14), %al
movb %al, 0xb(%rsp)
movq %r15, %rdi
leaq 0xb(%rsp), %rsi
callq 0x2b5fc
incq %r12
addq $0x4, %r13
decq %rbp
jne 0x40178
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ebwt_search_backtrack.h
// Function: GreedyDFSRangeSource::applyPartialMutations()
void applyPartialMutations() {
		if(_muts == NULL) {
			// No mutations to apply
			return;
		}
		for(size_t i = 0; i < _muts->size(); i++) {
			const QueryMutation& m = (*_muts)[i];
			assert_lt(m.pos, _qlen);
			assert_leq(m.oldBase, 4);
			assert_lt(m.newBase, 4);
			assert_neq(m.oldBase, m.newBase);
			assert_eq((uint32_t)((*_qry)[m.pos]), (uint32_t)m.oldBase);
			(*_qry)[m.pos] = (char)m.newBase; // apply it
		}
	}

// Assembly:
movq 0xb0(%rdi), %rax
testq %rax, %rax
je 0x403b1
cmpq $0x0, 0x18(%rax)
je 0x403b1
xorl %ecx, %ecx
movq 0x8(%rax), %rax
movb 0x3(%rax,%rcx,4), %dl
movq (%rdi), %rsi
movzwl (%rax,%rcx,4), %eax
movq 0x8(%rsi), %rsi
movb %dl, (%rsi,%rax)
incq %rcx
movq 0xb0(%rdi), %rax
cmpq 0x18(%rax), %rcx
jb 0x4038b
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/pat.cpp
// Function: PatternSourcePerThread::finalize(Read&)
void PatternSourcePerThread::finalize(Read& ra) {
	ra.mate = 0;
	ra.constructRevComps();
	ra.constructReverses();
	ra.seed = genRandSeed(ra.patFw, ra.qual, ra.name, seed_);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movl $0x0, 0x188(%rsi)
leaq 0x30(%rsi), %rdi
callq 0x4e4f8
movq %rbx, %rdi
callq 0x4d9f6
movl 0x74(%r14), %r9d
movq 0x8(%rbx), %rdi
movq 0x20(%rbx), %rsi
movq 0x68(%rbx), %rdx
movq 0x158(%rbx), %rcx
movq 0x170(%rbx), %r8
callq 0x4ad76
movl %eax, 0x18c(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/pat.cpp
// Function: genRandSeed(SDnaStringExpandable<25, 2> const&, SStringExpandable<char, 25, 2, 0> const&, SStringExpandable<char, 25, 2, 0> const&, unsigned int)
static uint32_t genRandSeed(
	const BTDnaString& qry,
	const BTString& qual,
	const BTString& name,
	uint32_t seed)
{
	// Calculate a per-read random seed based on a combination of
	// the read data (incl. sequence, name, quals) and the global
	// seed
	uint32_t rseed = (seed + 101) * 59 * 61 * 67 * 71 * 73 * 79 * 83;
	size_t qlen = qry.length();
	// Throw all the characters of the read into the random seed
	for(size_t i = 0; i < qlen; i++) {
		int p = (int)qry[i];
		assert_leq(p, 4);
		size_t off = ((i & 15) << 1);
		rseed ^= (p << off);
	}
	// Throw all the quality values for the read into the random
	// seed
	for(size_t i = 0; i < qlen; i++) {
		int p = (int)qual[i];
		assert_leq(p, 255);
		size_t off = ((i & 3) << 3);
		rseed ^= (p << off);
	}
	// Throw all the characters in the read name into the random
	// seed
	size_t namelen = name.length();
	for(size_t i = 0; i < namelen; i++) {
		int p = (int)name[i];
		assert_leq(p, 255);
		size_t off = ((i & 3) << 3);
		rseed ^= (p << off);
	}
	return rseed;
}

// Assembly:
movq %rcx, %r10
imull $0x568fae7, %r9d, %eax  # imm = 0x568FAE7
addl $0x226afd23, %eax       # imm = 0x226AFD23
testq %rsi, %rsi
je 0x4adcd
pushq %rbx
xorl %r9d, %r9d
xorl %r11d, %r11d
movsbl (%rdi,%r11), %ebx
movl %r9d, %ecx
andb $0x1e, %cl
shll %cl, %ebx
xorl %ebx, %eax
incq %r11
addl $0x2, %r9d
cmpq %r11, %rsi
jne 0x4ad91
xorl %edi, %edi
xorl %r9d, %r9d
popq %rbx
movsbl (%rdx,%r9), %r11d
movl %edi, %ecx
andb $0x18, %cl
shll %cl, %r11d
xorl %r11d, %eax
incq %r9
addl $0x8, %edi
cmpq %r9, %rsi
jne 0x4adb2
testq %r8, %r8
je 0x4adef
xorl %edx, %edx
xorl %esi, %esi
movsbl (%r10,%rsi), %edi
movl %edx, %ecx
andb $0x18, %cl
shll %cl, %edi
xorl %edi, %eax
incq %rsi
addl $0x8, %edx
cmpq %rsi, %r8
jne 0x4add6
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/pat.cpp
// Function: PatternSourcePerThread::finalizePair(Read&, Read&)
void PatternSourcePerThread::finalizePair(Read& ra, Read& rb) {
	ra.mate = 1;
	ra.constructRevComps();
	ra.constructReverses();
	ra.fixMateName(1);
	ra.seed = genRandSeed(ra.patFw, ra.qual, ra.name, seed_);

	rb.mate = 2;
	rb.constructRevComps();
	rb.constructReverses();
	rb.fixMateName(2);
	rb.seed = genRandSeed(rb.patFw, rb.qual, rb.name, seed_);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movl $0x1, 0x188(%rsi)
leaq 0x30(%rsi), %rdi
callq 0x4e4f8
movq %r15, %rdi
callq 0x4d9f6
movq %r15, %rdi
movl $0x1, %esi
callq 0x4da2e
movl 0x74(%r14), %r9d
movq 0x8(%r15), %rdi
movq 0x20(%r15), %rsi
movq 0x68(%r15), %rdx
movq 0x158(%r15), %rcx
movq 0x170(%r15), %r8
callq 0x4ad76
movl %eax, 0x18c(%r15)
movl $0x2, 0x188(%rbx)
leaq 0x30(%rbx), %rdi
movq %rbx, %rsi
callq 0x4e4f8
movq %rbx, %rdi
callq 0x4d9f6
movq %rbx, %rdi
movl $0x2, %esi
callq 0x4da2e
movl 0x74(%r14), %r9d
movq 0x8(%rbx), %rdi
movq 0x20(%rbx), %rsi
movq 0x68(%rbx), %rdx
movq 0x158(%rbx), %rcx
movq 0x170(%rbx), %r8
callq 0x4ad76
movl %eax, 0x18c(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/pat.cpp
// Function: PatternSourcePerThread::nextReadPair()
pair<bool, bool> PatternSourcePerThread::nextReadPair() {
	// Prepare batch
	if(buf_.exhausted()) {
		pair<bool, int> res = nextBatch();
		if(res.first && res.second == 0) {
			return make_pair(false, true);
		}
		last_batch_ = res.first;
		last_batch_size_ = res.second;
		assert_eq(0, buf_.cur_buf_);
	} else {
		buf_.next(); // advance cursor
		assert_gt(buf_.cur_buf_, 0);
	}
	bool this_is_last = buf_.cur_buf_ == last_batch_size_-1;
	if(buf_.rdid() < skip_) {
		return make_pair(false, this_is_last ? last_batch_ : false);
	}
	// Parse read/pair
	assert(!buf_.read_a().readOrigBuf.empty());
	assert(buf_.read_a().empty());
	if(!parse(buf_.read_a(), buf_.read_b())) {
		return make_pair(false, false);
	}
	// Finalize read/pair
	if(paired()) {
		finalizePair(buf_.read_a(), buf_.read_b());
	} else {
		finalize(buf_.read_a());
	}
	return make_pair(true, this_is_last ? last_batch_ : false);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq 0x28(%rdi), %rax
movq 0x50(%rdi), %r15
decq %rax
cmpq %rax, %r15
jae 0x4aed3
incq %r15
movq %r15, 0x50(%rbx)
movq 0x58(%rbx), %rcx
movq 0x68(%rbx), %r14
jmp 0x4af31
leaq 0x8(%rbx), %r14
movq %r14, %rdi
callq 0x24c24
movq (%rbx), %rdi
movq (%rdi), %rax
movq %r14, %rsi
callq *0x18(%rax)
movq %rax, %r14
movq $0x0, 0x50(%rbx)
movq 0x58(%rbx), %rcx
movq %rcx, %rax
xorl %edx, %edx
divq 0x8(%rbx)
movq %rax, 0x78(%rbx)
movq %r14, %rax
shrq $0x20, %rax
sete %dl
movw $0x100, %ax             # imm = 0x100
testb %r14b, %dl
jne 0x4afb4
movl %r14d, %eax
andb $0x1, %al
movb %al, 0x60(%rbx)
sarq $0x20, %r14
movq %r14, 0x68(%rbx)
xorl %r15d, %r15d
decq %r14
addq %r15, %rcx
movl 0x70(%rbx), %eax
cmpq %rax, %rcx
jae 0x4af4c
movl 0x60(%rbx), %ecx
shll $0x8, %ecx
xorl %eax, %eax
cmpq %r14, %r15
jmp 0x4afb1
imulq $0x268, %r15, %rdx      # imm = 0x268
movq 0x18(%rbx), %rsi
addq %rdx, %rsi
addq 0x38(%rbx), %rdx
movq (%rbx), %rdi
movq (%rdi), %rax
callq *0x20(%rax)
testb %al, %al
je 0x4af95
movq 0x38(%rbx), %rdx
imulq $0x268, 0x50(%rbx), %rax # imm = 0x268
movq 0x18(%rbx), %rsi
addq %rax, %rsi
cmpb $0x1, 0x190(%rdx,%rax)
jne 0x4af99
addq %rax, %rdx
movq %rbx, %rdi
callq 0x4adf0
jmp 0x4afa1
xorl %eax, %eax
jmp 0x4afb4
movq %rbx, %rdi
callq 0x4ad20
movl 0x60(%rbx), %ecx
shll $0x8, %ecx
incl %ecx
cmpq %r14, %r15
movl $0x1, %eax
cmovel %ecx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/pat.cpp
// Function: SoloPatternComposer::nextBatch(PerThreadReadBuf&)
pair<bool, int> SoloPatternComposer::nextBatch(PerThreadReadBuf& pt) {
	uint32_t cur = cur_;
	while(cur < src_.size()) {
		// Patterns from srca_[cur_] are unpaired
		pair<bool, int> res;
		do {
			res = src_[cur]->nextBatch(
				pt,
				true,  // batch A (or pairs)
				true); // grab lock below
		} while(!res.first && res.second == 0);
		if(res.second == 0) {
			ThreadSafe ts(&mutex_m);
			if(cur + 1 > cur_) {
				cur_++;
			}
			cur = cur_;
			continue; // on to next pair of PatternSources
		}
		return res;
	}
	assert_leq(cur, src_.size());
	return make_pair(true, 0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movl 0xc(%rdi), %ebp
leaq 0x8(%rdi), %r15
movl %ebp, %r12d
cmpq %r12, 0x28(%r14)
jbe 0x4b028
movq 0x18(%r14), %rax
movq (%rax,%r12,8), %rdi
movq (%rdi), %rax
movq %rbx, %rsi
movl $0x1, %edx
movl $0x1, %ecx
callq *0x10(%rax)
movq %rax, %rcx
shrq $0x20, %rcx
jne 0x4b000
testb $0x1, %al
je 0x4afd8
testq %rcx, %rcx
jne 0x4b02f
movq %r15, %rdi
callq 0x4ac58
incl %r12d
cmpl 0xc(%r14), %r12d
jbe 0x4b01a
incl 0xc(%r14)
movl 0xc(%r14), %ebp
movq %r15, %rdi
callq 0x4ac94
jmp 0x4afcf
movl $0x1, %eax
jmp 0x4b03c
movabsq $-0xffffff01, %rcx      # imm = 0xFFFFFFFF000000FF
andq %rcx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rdi
callq 0x1afa3
nop
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/pat.cpp
// Function: CFilePatternSource::nextBatchImpl(PerThreadReadBuf&, bool)
pair<bool, int> CFilePatternSource::nextBatchImpl(
	PerThreadReadBuf& pt,
	bool batch_a)
{
	bool done = false;
	size_t nread = 0;
	pt.setReadId(readCnt_);
	while(true) { // loop that moves on to next file when needed
		do {
			pair<bool, int> ret = nextBatchFromFile(pt, batch_a, nread);
			done = ret.first;
			nread = ret.second;
		} while(!done && nread == 0); // not sure why this would happen
		if(done && filecur_ < infiles_.size()) { // finished with this file
			open();
			resetForNextFile(); // reset state to handle a fresh file
			filecur_++;
			if(nread == 0 || nread < pt.max_buf_) {
				continue;
			}
			done = false;
		}
		break;
	}
	assert_geq(nread, 0);
	readCnt_ += nread;
	return make_pair(done, nread);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r12
movq %rdi, %rbx
movq 0x8(%rdi), %rax
movq %rax, 0x50(%rsi)
movzbl %dl, %ebp
xorl %r13d, %r13d
movq (%rbx), %rax
movq %rbx, %rdi
movq %r12, %rsi
movl %ebp, %edx
movq %r13, %rcx
callq *0x30(%rax)
movq %rax, %r14
movq %rax, %r13
sarq $0x20, %r13
xorb $0x1, %al
movq %r14, %r15
shrq $0x20, %r15
sete %cl
testb %al, %cl
jne 0x4b24d
testb $0x1, %r14b
je 0x4b2b2
movq 0x80(%rbx), %rax
cmpq 0x38(%rbx), %rax
jae 0x4b2b2
movq %rbx, %rdi
callq 0x4b2de
movq (%rbx), %rax
movq %rbx, %rdi
callq *0x38(%rax)
incq 0x80(%rbx)
testq %r15, %r15
je 0x4b24d
cmpq (%r12), %r13
jb 0x4b24d
xorl %ecx, %ecx
jmp 0x4b2b8
movl %r14d, %ecx
andl $0x1, %ecx
addq %r13, 0x8(%rbx)
movabsq $-0x100000000, %rax     # imm = 0xFFFFFFFF00000000
andq %rax, %r14
orq %rcx, %r14
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/pat.cpp
// Function: CFilePatternSource::nextBatch(PerThreadReadBuf&, bool, bool)
pair<bool, int> CFilePatternSource::nextBatch(
	PerThreadReadBuf& pt,
	bool batch_a,
	bool lock)
{
	if(lock) {
		// synchronization at this level because both reading and manipulation of
		// current file pointer have to be protected
		ThreadSafe ts(&mutex);
		return nextBatchImpl(pt, batch_a);
	} else {
		return nextBatchImpl(pt, batch_a);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %r15
testl %ecx, %ecx
je 0x4b6af
leaq 0x10(%r15), %rbx
movq %rbx, %rdi
callq 0x4ac58
movzbl %bpl, %edx
movq %r15, %rdi
movq %r14, %rsi
callq 0x4b22e
movq %rax, %r14
movq %rbx, %rdi
callq 0x4ac94
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movzbl %bpl, %edx
movq %r15, %rdi
movq %r14, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x4b22e
jmp 0x4b6dd
movq %rax, %r14
movq %rbx, %rdi
callq 0x4ac94
movq %r14, %rdi
callq 0x9930
movq %rax, %rdi
callq 0x1afa3
nop