// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/hit.cpp
// Function: VerboseHitSink::append(SStringExpandable<char, 25, 2, 0>&, Hit const&, EList<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, 128> const*, bool, int, int, bool, Bitset const&)
void VerboseHitSink::append(
	BTString& o,
	const Hit& h,
	const EList<string>* refnames,
	bool fullRef,
	int partition,
	int offBase,
	bool cost,
	const Bitset& suppress)
{
	bool spill = false;
	int spillAmt = 0;
	uint32_t pdiv = 0xffffffff;
	uint32_t pmod = 0xffffffff;
	do {
		bool dospill = false;
		if(spill) {
			// The read spilled over a partition boundary and so
			// needs to be printed more than once
			spill = false;
			dospill = true;
			spillAmt++;
		}
		assert(!spill);
		size_t field = 0;
		bool firstfield = true;
		if(partition != 0) {
			int pospart = abs(partition);
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				// Output a partitioning key
				// First component of the key is the reference index
				if(refnames != NULL && h.h.first < refnames->size()) {
					printUptoWs(o, (*refnames)[h.h.first], !fullRef);
				} else {
					o << h.h.first;
				}
			}
			// Next component of the key is the partition id
			if(!dospill) {
				pdiv = (h.h.second + offBase) / pospart;
				pmod = (h.h.second + offBase) % pospart;
			}
			assert_neq(0xffffffff, pdiv);
			assert_neq(0xffffffff, pmod);
			if(dospill) assert_gt(spillAmt, 0);
			if(partition > 0 &&
			   (pmod + h.length()) >= ((uint32_t)pospart * (spillAmt + 1))) {
				// Spills into the next partition so we need to
				// output another alignment for that partition
				spill = true;
			}
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) {
					firstfield = false;
				} else {
					o << '\t';
				}
				// Print partition id with leading 0s so that Hadoop
				// can do lexicographical sort (modern Hadoop versions
				// seen to support numeric)
				int padding = 10;
				uint32_t part = (pdiv + (dospill ? spillAmt : 0));
				uint32_t parttmp = part;
				while(parttmp > 0) {
					padding--;
					parttmp /= 10;
				}
				assert_geq(padding, 0);
				for(int i = 0; i < padding; i++) {
					o << '0';
				}
				o << part;
			}
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) {
					firstfield = false;
				} else {
					o << '\t';
				}
				// Print offset with leading 0s
				int padding = 9;
				uint32_t off = h.h.second + offBase;
				uint32_t offtmp = off;
				while(offtmp > 0) {
					padding--;
					offtmp /= 10;
				}
				assert_geq(padding, 0);
				for(int i = 0; i < padding; i++) {
					o << '0';
				}
				o << off;
			}
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				o << (h.fw? "+":"-");
			}
			// end if(partition != 0)
		} else {
			assert(!dospill);
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				for (size_t i = 0; i < h.patName.length(); i++)
					o << h.patName[i];
			}
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				o << (h.fw? '+' : '-');
			}
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				// .first is text id, .second is offset
				if(refnames != NULL && h.h.first < refnames->size()) {
					printUptoWs(o, (*refnames)[h.h.first], !fullRef);
				} else {
					o << h.h.first;
				}
			}
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				o << (h.h.second + offBase);
			}
			// end else clause of if(partition != 0)
		}
		if(!suppress.test((uint32_t)field++)) {
			if(firstfield) firstfield = false;
			else o << '\t';
			o << h.patSeq.toZBuf();
		}
		if(!suppress.test((uint32_t)field++)) {
			if(firstfield) firstfield = false;
			else o << '\t';
			o << h.quals.toZBuf();
		}
		if(!suppress.test((uint32_t)field++)) {
			if(firstfield) firstfield = false;
			else o << '\t';
			o << h.oms;
		}
		if(!suppress.test((uint32_t)field++)) {
			if(firstfield) firstfield = false;
			else o << '\t';
			// Output mismatch column
			bool firstmm = true;
			for (unsigned int i = 0; i < h.patSeq.length(); ++ i) {
				if(h.mms.test(i)) {
					// There's a mismatch at this position
					if (!firstmm) {
						o << ",";
					}
					o << i; // position
					assert_gt(h.refcs.size(), i);
					char refChar = toupper(h.refcs[i]);
					char qryChar = (h.fw ? h.patSeq.toChar(i) : h.patSeq.toChar(h.patSeq.length()-i-1));
					assert_neq(refChar, qryChar);
					o << ":" << refChar << ">" << qryChar;
					firstmm = false;
				}
			}
			if(partition != 0 && firstmm) o << '-';
		}
		if(partition != 0) {
			// Fields addded as of Crossbow 0.1.4
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				o << (int)h.mate;
			}
			// Print label, or whole read name if label isn't found
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				int labelOff = -1;
				// If LB: field is present, print its value
				for(int i = 0; i < (int)h.patName.length() - 3; i++) {
					if(h.patName[i]   == 'L' &&
					   h.patName[i+1] == 'B' &&
					   h.patName[i+2] == ':' &&
					   ((i == 0) || h.patName[i-1] == ';'))
					{
						labelOff = i+3;
						for(int j = labelOff; j < (int)h.patName.length(); j++) {
							if(h.patName[j] != ';') {
								o << h.patName[j];
							} else {
								break;
							}
						}
					}
				}
				// Otherwise, print the whole read name
				if(labelOff == -1) {
					for (size_t i = 0; i < h.patName.length(); i++)
						o << h.patName[i];
				}
			}
		}
		if(cost) {
			// Stratum
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				o << (int)h.stratum;
			}
			// Cost
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				o << (int)h.cost;
			}
		}
		if(showSeed) {
			// Seed
			if(!suppress.test((uint32_t)field++)) {
				if(firstfield) firstfield = false;
				else o << '\t';
				o << h.seed;
			}
		}
		o << '\n';
	} while(spill);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movl %r9d, 0x1c(%rsp)
movq %rdx, 0x38(%rsp)
movq %rsi, %r12
movq %rdi, %r13
movl %r8d, %eax
negl %eax
movl %r8d, 0x18(%rsp)
cmovsl %r8d, %eax
movl %eax, 0x28(%rsp)
xorb $0x1, %cl
movl %ecx, 0x20(%rsp)
leaq 0x60(%rsi), %rax
movq %rax, 0x50(%rsp)
leaq 0x91(%rsi), %rax
movq %rax, 0x48(%rsp)
leaq 0x178(%rsi), %rax
movq %rax, 0x60(%rsp)
leaq 0x18c(%rsi), %rax
movq %rax, 0x58(%rsp)
movl $0xffffffff, 0x24(%rsp) # imm = 0xFFFFFFFF
leaq 0x8(%rsp), %r14
leaq 0x576a(%rip), %r15      # 0x55a3c
movl $0xffffffff, 0x2c(%rsp) # imm = 0xFFFFFFFF
movq $0x0, 0x40(%rsp)
xorl %edx, %edx
movq %r15, %rbx
movq 0x40(%rsp), %rcx
leal 0x1(%rcx), %eax
testb $0x1, %dl
movl $0x0, %ebp
cmovnel %eax, %ebp
cmovnel %eax, %ecx
movq %rcx, 0x40(%rsp)
movzbl %dl, %ecx
movl $0x0, %eax
cmovnel %eax, %ecx
movl %ecx, 0x14(%rsp)
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0x0, 0x18(%rsp)
je 0x50379
movl %edx, %r15d
testl %eax, %eax
je 0x50346
movq 0xa8(%rsp), %rax
movq 0x18(%rax), %rax
movb $0x1, %cl
movl %ecx, 0xc(%rsp)
testb $0x1, (%rax)
jne 0x503fd
movq 0x38(%rsp), %rax
testq %rax, %rax
je 0x503ea
movl (%r12), %esi
cmpq %rsi, 0x18(%rax)
jbe 0x503ea
shlq $0x5, %rsi
addq 0x8(%rax), %rsi
movzbl 0x20(%rsp), %edx
movq %r13, %rdi
callq 0x4fc12
jmp 0x503f5
testl %eax, %eax
je 0x50398
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
movb $0x1, %dl
movl %edx, 0xc(%rsp)
testb $0x1, (%rcx)
jne 0x50632
cmpq $0x0, 0x38(%r12)
movq %rbx, %r15
je 0x50637
movq %r14, %rbp
xorl %r14d, %r14d
movq 0x20(%r12), %rax
movb (%rax,%r14), %al
movb %al, 0x8(%rsp)
movq %r13, %rdi
movq %rbp, %rsi
callq 0x4dc0a
incq %r14
cmpq 0x38(%r12), %r14
jb 0x503ad
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
movl $0x0, 0xc(%rsp)
movq %rbp, %r14
jmp 0x5063f
movq %r13, %rdi
movq %r12, %rsi
callq 0x4fd81
movl $0x0, 0xc(%rsp)
testb $0x1, %r15b
jne 0x5041a
movl 0x4(%r12), %eax
addl 0x1c(%rsp), %eax
xorl %edx, %edx
divl 0x28(%rsp)
movl %edx, 0x24(%rsp)
movl %eax, 0x2c(%rsp)
cmpl $0x0, 0x18(%rsp)
movq %rbx, %r15
jle 0x5044f
movl 0x24(%rsp), %eax
addq 0x68(%r12), %rax
movq 0x40(%rsp), %rcx
incl %ecx
imull 0x28(%rsp), %ecx
cmpq %rcx, %rax
movzbl 0x14(%rsp), %ecx
movl $0x1, %eax
cmovael %eax, %ecx
movl %ecx, 0x14(%rsp)
jmp 0x50457
movl 0x14(%rsp), %ebx
movl %ebx, 0x14(%rsp)
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0x2, %eax
jb 0x5047c
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
testb $0x2, (%rcx)
jne 0x50518
cmpb $0x0, 0xc(%rsp)
je 0x5048d
movl $0x0, 0xc(%rsp)
jmp 0x5049d
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movl $0xcccccccd, %ecx       # imm = 0xCCCCCCCD
addl 0x2c(%rsp), %ebp
movl %ebp, 0x8(%rsp)
je 0x504d4
movl $0xb, %ebx
movl %ebp, %eax
imulq %rcx, %rax
shrq $0x23, %rax
decl %ebx
cmpl $0xa, %ebp
movl %eax, %ebp
jae 0x504b1
cmpl $0x2, %ebx
leaq 0x5369(%rip), %rbp      # 0x55837
jl 0x504f9
decl %ebx
jmp 0x504e0
movl $0xa, %ebx
leaq 0x5357(%rip), %rbp      # 0x55837
leaq 0x13(%rsp), %r15
movb $0x30, 0x13(%rsp)
movq %r13, %rdi
movq %r15, %rsi
callq 0x4dc0a
decl %ebx
jne 0x504e5
movq %r13, %rdi
movq %r14, %rsi
callq 0x4fd81
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
leaq 0x5526(%rip), %r15      # 0x55a3c
jmp 0x5051f
leaq 0x5318(%rip), %rbp      # 0x55837
cmpl $0x3, %eax
jb 0x50539
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
testb $0x4, (%rcx)
jne 0x505ca
cmpb $0x0, 0xc(%rsp)
je 0x5054a
movl $0x0, 0xc(%rsp)
jmp 0x5055a
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movl $0xcccccccd, %edx       # imm = 0xCCCCCCCD
movl 0x4(%r12), %eax
addl 0x1c(%rsp), %eax
movl %eax, 0x8(%rsp)
je 0x5058f
movl $0xa, %ebx
movl %eax, %ecx
imulq %rdx, %rcx
shrq $0x23, %rcx
decl %ebx
cmpl $0xa, %eax
movl %ecx, %eax
jae 0x50573
cmpl $0x2, %ebx
jl 0x505ad
decl %ebx
jmp 0x50594
movl $0x9, %ebx
leaq 0x13(%rsp), %r15
movb $0x30, 0x13(%rsp)
movq %r13, %rdi
movq %r15, %rsi
callq 0x4dc0a
decl %ebx
jne 0x50599
movq %r13, %rdi
movq %r14, %rsi
callq 0x4fd81
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
leaq 0x5472(%rip), %r15      # 0x55a3c
cmpl $0x4, %eax
jb 0x505e4
movq 0xa8(%rsp), %rax
movq 0x18(%rax), %rax
testb $0x8, (%rax)
jne 0x5076a
cmpb $0x0, 0xc(%rsp)
je 0x505f5
movl $0x0, 0xc(%rsp)
jmp 0x50605
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
cmpb $0x0, 0x17c(%r12)
leaq 0x56a7(%rip), %rsi      # 0x55cbc
leaq 0x6e86(%rip), %rax      # 0x574a2
cmovneq %rax, %rsi
movl $0x1, %edx
movq %r13, %rdi
callq 0x4fee0
jmp 0x5076a
movq %rbx, %r15
jmp 0x5063f
movl $0x0, 0xc(%rsp)
cmpl $0x2, %eax
leaq 0x51ee(%rip), %rbp      # 0x55837
jb 0x5065c
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
testb $0x2, (%rcx)
jne 0x506a5
cmpb $0x0, 0xc(%rsp)
je 0x5066d
movl $0x0, 0xc(%rsp)
jmp 0x5067d
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movb 0x17c(%r12), %al
xorb $0x1, %al
addb %al, %al
addb $0x2b, %al
movb %al, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0x3, %eax
jb 0x506bb
movq 0xa8(%rsp), %rax
movq 0x18(%rax), %rax
testb $0x4, (%rax)
jne 0x50712
cmpb $0x0, 0xc(%rsp)
je 0x506cc
movl $0x0, 0xc(%rsp)
jmp 0x506dc
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movq 0x38(%rsp), %rax
testq %rax, %rax
je 0x50707
movl (%r12), %esi
cmpq %rsi, 0x18(%rax)
jbe 0x50707
shlq $0x5, %rsi
addq 0x8(%rax), %rsi
movzbl 0x20(%rsp), %edx
movq %r13, %rdi
callq 0x4fc12
jmp 0x50712
movq %r13, %rdi
movq %r12, %rsi
callq 0x4fd81
movq 0xa8(%rsp), %rax
cmpl $0x4, 0x10(%rax)
jb 0x50729
movq 0x18(%rax), %rax
testb $0x8, (%rax)
jne 0x50762
cmpb $0x0, 0xc(%rsp)
je 0x5073a
movl $0x0, 0xc(%rsp)
jmp 0x5074a
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movl 0x4(%r12), %eax
addl 0x1c(%rsp), %eax
movl %eax, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4fd81
movl 0x14(%rsp), %ebx
movl %ebx, 0x14(%rsp)
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0x5, %eax
jb 0x5078f
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
testb $0x10, (%rcx)
jne 0x50810
cmpb $0x0, 0xc(%rsp)
je 0x507a0
movl $0x0, 0xc(%rsp)
jmp 0x507b0
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
cmpq $0x0, 0x68(%r12)
je 0x507e7
movq 0x58(%r12), %rax
xorl %ecx, %ecx
movq 0x50(%r12), %rdx
movsbq (%rdx,%rcx), %rdx
movb (%rdx,%rbp), %dl
movb %dl, (%rax,%rcx)
incq %rcx
movq 0x68(%r12), %rdx
cmpq %rdx, %rcx
jb 0x507bf
movb $0x0, (%rax,%rdx)
movq 0x58(%r12), %rbx
jmp 0x507ef
movq 0x50(%rsp), %rbx
movb $0x0, (%rbx)
movq %rbx, %rdi
callq 0x91b0
movq %r13, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x4fee0
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0x6, %eax
jb 0x50826
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
testb $0x20, (%rcx)
jne 0x50893
cmpb $0x0, 0xc(%rsp)
je 0x50837
movl $0x0, 0xc(%rsp)
jmp 0x50847
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movq 0x98(%r12), %rax
testq %rax, %rax
je 0x5086a
movq 0x80(%r12), %rcx
movb $0x0, (%rcx,%rax)
movq 0x80(%r12), %rbx
jmp 0x50872
movq 0x48(%rsp), %rbx
movb $0x0, (%rbx)
movq %rbx, %rdi
callq 0x91b0
movq %r13, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x4fee0
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0x7, %eax
jb 0x508a9
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
testb $0x40, (%rcx)
jne 0x508e2
cmpb $0x0, 0xc(%rsp)
je 0x508ba
movl $0x0, 0xc(%rsp)
jmp 0x508ca
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movq %r13, %rdi
movq 0x60(%rsp), %rsi
callq 0x4fd81
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0x8, %eax
jb 0x508fc
movq 0xa8(%rsp), %rax
movq 0x18(%rax), %rax
testb $-0x80, (%rax)
jne 0x50a48
cmpb $0x0, 0xc(%rsp)
je 0x5090d
movl $0x0, 0xc(%rsp)
jmp 0x5091d
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movl $0x0, 0x8(%rsp)
movq 0x68(%r12), %rax
testq %rax, %rax
je 0x50a2f
xorl %edx, %edx
movb $0x1, %cl
movl %edx, %esi
shrl $0x5, %esi
movl 0xb0(%r12,%rsi,4), %esi
btl %edx, %esi
jae 0x50a12
testb $0x1, %cl
jne 0x50966
movl $0x1, %edx
movq %r13, %rdi
leaq 0x5b73(%rip), %rsi      # 0x564d4
callq 0x4fee0
movq %r13, %rdi
movq %r14, %rsi
callq 0x4fd81
movl 0x8(%rsp), %r14d
movq 0x140(%r12), %rax
movsbl (%rax,%r14), %edi
callq 0x9990
movl %eax, %ebx
movq 0x50(%r12), %rax
leaq (%rax,%r14), %rcx
addq 0x68(%r12), %rax
notq %r14
addq %r14, %rax
leaq 0x8(%rsp), %r14
cmpb $0x0, 0x17c(%r12)
cmovneq %rcx, %rax
movsbq (%rax), %rax
leaq 0x4e7c(%rip), %rcx      # 0x55837
movb (%rax,%rcx), %bpl
movl $0x1, %edx
movq %r13, %rdi
leaq 0x261c(%rip), %rsi      # 0x52fea
callq 0x4fee0
movb %bl, 0x13(%rsp)
movq %r13, %rdi
leaq 0x13(%rsp), %rbx
movq %rbx, %rsi
callq 0x4dc0a
movl $0x1, %edx
movq %r13, %rdi
movq %r15, %rsi
callq 0x4fee0
movb %bpl, 0x13(%rsp)
movq %r13, %rdi
movq %rbx, %rsi
callq 0x4dc0a
movl 0x8(%rsp), %edx
movq 0x68(%r12), %rax
xorl %ecx, %ecx
incl %edx
movl %edx, 0x8(%rsp)
cmpq %rdx, %rax
ja 0x50937
cmpl $0x0, 0x18(%rsp)
je 0x50a82
testb $0x1, %cl
jne 0x50a36
jmp 0x50a4f
cmpl $0x0, 0x18(%rsp)
je 0x50a82
movb $0x2d, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
jmp 0x50a4f
cmpl $0x0, 0x18(%rsp)
je 0x50a82
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0x9, %eax
jb 0x50a71
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
testb $0x1, 0x1(%rcx)
jne 0x50abf
cmpb $0x0, 0xc(%rsp)
je 0x50a8c
movl $0x0, 0xc(%rsp)
jmp 0x50a9c
movl $0x8, %ebp
jmp 0x50bf5
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movzbl 0x188(%r12), %eax
movl %eax, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4fe23
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl $0xa, %eax
jb 0x50adf
movq 0xa8(%rsp), %rax
movq 0x18(%rax), %rax
movl $0xa, %ebp
testb $0x2, 0x1(%rax)
jne 0x50bf5
cmpb $0x0, 0xc(%rsp)
je 0x50af0
movl $0x0, 0xc(%rsp)
jmp 0x50b00
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movq 0x38(%r12), %rax
movb $0x1, %cl
cmpl $0x4, %eax
jl 0x50bc0
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movl $0x3, %ebp
movl $0x4, %r15d
xorl %ebx, %ebx
movq 0x20(%r12), %rcx
cmpb $0x4c, (%rcx,%rbx)
jne 0x50b9b
cmpb $0x42, 0x1(%rcx,%rbx)
jne 0x50b9b
cmpb $0x3a, 0x2(%rcx,%rbx)
jne 0x50b9b
testq %rbx, %rbx
je 0x50b47
cmpb $0x3b, -0x1(%rcx,%rbx)
jne 0x50b9b
leaq 0x3(%rbx), %rdx
movslq %eax, %rcx
cmpq %rcx, %rdx
jge 0x50b9b
movq %rdx, 0x30(%rsp)
movq 0x20(%r12), %rcx
movb (%rcx,%rbp), %cl
movq %r15, %r14
cmpb $0x3b, %cl
je 0x50b91
movb %cl, 0x8(%rsp)
movq %r13, %rdi
leaq 0x8(%rsp), %rsi
callq 0x4dc0a
movq 0x38(%r12), %rax
cmpl %eax, %r14d
jge 0x50b91
movq 0x20(%r12), %rcx
movb (%rcx,%r14), %cl
incq %r14
jmp 0x50b63
leaq 0x8(%rsp), %r14
movq 0x30(%rsp), %rdx
incq %rbx
leal -0x3(%rax), %ecx
movslq %ecx, %rcx
incq %rbp
incq %r15
cmpq %rcx, %rbx
jl 0x50b22
cmpl $-0x1, %edx
sete %cl
leaq 0x4e7c(%rip), %r15      # 0x55a3c
testq %rax, %rax
sete %al
xorb $0x1, %cl
movl $0xa, %ebp
orb %al, %cl
jne 0x50bf5
xorl %ebx, %ebx
movq 0x20(%r12), %rax
movb (%rax,%rbx), %al
movb %al, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
incq %rbx
cmpq 0x38(%r12), %rbx
jb 0x50bd4
cmpb $0x0, 0xa0(%rsp)
je 0x50cc6
movl %ebp, %ebx
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
cmpl %ebp, %eax
jbe 0x50c27
movq 0xa8(%rsp), %rcx
movq 0x18(%rcx), %rcx
movl (%rcx), %ecx
btl %ebx, %ecx
jb 0x50c6b
cmpb $0x0, 0xc(%rsp)
je 0x50c38
movl $0x0, 0xc(%rsp)
jmp 0x50c48
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movsbl 0x180(%r12), %eax
movl %eax, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4fe23
movq 0xa8(%rsp), %rax
movl 0x10(%rax), %eax
addq $0x2, %rbp
movl %ebx, %ecx
orl $0x1, %ecx
cmpl %ecx, %eax
jbe 0x50c8e
movq 0xa8(%rsp), %rax
movq 0x18(%rax), %rax
movl (%rax), %eax
movl %ebx, %ecx
shrl %cl, %eax
testb $0x2, %al
jne 0x50cc6
cmpb $0x0, 0xc(%rsp)
je 0x50c9f
movl $0x0, 0xc(%rsp)
jmp 0x50caf
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movl 0x184(%r12), %eax
movl %eax, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4fe23
leaq 0x1c47b(%rip), %rax     # 0x6d148
cmpb $0x1, (%rax)
jne 0x50d0e
movq 0xa8(%rsp), %rax
cmpl %ebp, 0x10(%rax)
jbe 0x50cea
movq 0x18(%rax), %rax
movl (%rax), %eax
btl %ebp, %eax
jb 0x50d0e
cmpb $0x0, 0xc(%rsp)
jne 0x50d01
movb $0x9, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movq %r13, %rdi
movq 0x58(%rsp), %rsi
callq 0x4fd81
movb $0xa, 0x8(%rsp)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4dc0a
movl 0x14(%rsp), %edx
testb $0x1, %dl
jne 0x502e5
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq