// File: /workspace/github_cpp_makefile_star2_O3/BenLangmead[P]bowtie/./ebwt.h
// Function: Ebwt::printRangeBw(unsigned int, unsigned int) const
void Ebwt::printRangeBw(uint32_t begin, uint32_t end) const {
	assert(isInMemory());
	uint32_t occ[] = {0, 0, 0, 0};
	assert_gt(end, begin);
	for(uint32_t i = end-1; i >= begin; i--) {
		uint8_t by = this->_ebwt[i];
		for(int j = 3; j >= 0; j--) {
			// Unpack from lowest to highest bit pair
			int twoBit = unpack_2b_from_8b(by, j);
			occ[twoBit]++;
			cout << "ACGT"[twoBit];
		}
		assert_eq(0, (occ[0] + occ[1] + occ[2] + occ[3]) & 3);
		if(i == 0) break;
	}
	cout << ":{" << occ[0] << "," << occ[1] << "," << occ[2] << "," << occ[3] << "}" << endl;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %edx, %ebp
movl %esi, %ebx
movq %rdi, 0x30(%rsp)
callq 0xf948
testb %al, %al
je 0x5783
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
cmpl %ebx, %ebp
jbe 0x57a2
movl %ebp, %r15d
movl %ebx, %eax
decq %r15
movq %rax, 0x28(%rsp)
cmpq %rax, %r15
jae 0x54fb
xorl %r15d, %r15d
xorl %r12d, %r12d
xorl %r13d, %r13d
xorl %r14d, %r14d
jmp 0x5589
leaq 0x26cbf(%rip), %r12     # 0x2c1c1
movq 0x31aaf(%rip), %r13     # 0x36fb8
leaq 0xf(%rsp), %rbx
movq 0x30(%rsp), %rax
movq 0xc8(%rax), %rax
movl $0x3, %ebp
movzbl (%rax,%r15), %r14d
movl %r14d, %edi
movl %ebp, %esi
callq 0x53e3
movl %eax, %eax
incl 0x10(%rsp,%rax,4)
movb (%rax,%r12), %al
movb %al, 0xf(%rsp)
movl $0x1, %edx
movq %r13, %rdi
movq %rbx, %rsi
callq 0x43b0
addl $-0x1, %ebp
jb 0x5524
movl 0x10(%rsp), %r14d
movl 0x14(%rsp), %esi
movl 0x18(%rsp), %edx
movl 0x1c(%rsp), %ecx
leal (%rcx,%rdx), %ebp
addl %esi, %ebp
addl %r14d, %ebp
andl $0x3, %ebp
jne 0x565d
subq $0x1, %r15
jb 0x5580
cmpq 0x28(%rsp), %r15
jae 0x550e
movq %rcx, %r15
movq %rdx, %r12
movq %rsi, %r13
movq 0x31a28(%rip), %rbx     # 0x36fb8
leaq 0x26c52(%rip), %rsi     # 0x2c1e9
movl $0x2, %edx
movq %rbx, %rdi
callq 0x43b0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x41d0
movq %rax, %r14
leaq 0x27360(%rip), %rbx     # 0x2c919
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x43b0
movq %r14, %rdi
movq %r13, %rsi
callq 0x41d0
movq %rax, %r14
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x43b0
movq %r14, %rdi
movq %r12, %rsi
callq 0x41d0
movq %rax, %r14
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x43b0
movq %r14, %rdi
movq %r15, %rsi
callq 0x41d0
movq %rax, %rbx
leaq 0x26bd2(%rip), %rsi     # 0x2c1ec
movl $0x1, %edx
movq %rax, %rdi
callq 0x43b0
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4300
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x41e0
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x31954(%rip), %rbx     # 0x36fb8
leaq 0x26b5b(%rip), %rsi     # 0x2c1c6
movq %rbx, %rdi
callq 0x4310
movq %rax, %rdi
xorl %esi, %esi
callq 0x4610
leaq 0x26b58(%rip), %r14     # 0x2c1dc
movq %rax, %rdi
movq %r14, %rsi
callq 0x4310
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
movl 0x18(%rax,%rcx), %edx
andl $-0x4b, %edx
orl $0x8, %edx
movl %edx, 0x18(%rax,%rcx)
movq %rax, %rdi
xorl %esi, %esi
callq 0x4610
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
movl 0x18(%rax,%rcx), %edx
andl $-0x4b, %edx
orl $0x2, %edx
movl %edx, 0x18(%rax,%rcx)
leaq 0x26b17(%rip), %rsi     # 0x2c1e1
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
movl %ebp, %esi
callq 0x4440
movq %rax, %rdi
movq %r14, %rsi
callq 0x4310
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
movl 0x18(%rax,%rcx), %edx
andl $-0x4b, %edx
orl $0x8, %edx
movl %edx, 0x18(%rax,%rcx)
movq %rax, %rdi
movl %ebp, %esi
callq 0x4440
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
movl 0x18(%rax,%rcx), %edx
andl $-0x4b, %edx
orl $0x2, %edx
movl %edx, 0x18(%rax,%rcx)
leaq 0x28c83(%rip), %rsi     # 0x2e3a5
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
callq 0x4150
leaq 0x26a31(%rip), %r14     # 0x2c16a
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4310
leaq 0x2805d(%rip), %rsi     # 0x2d7a8
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
movl $0x624, %esi            # imm = 0x624
callq 0x4610
movq %rax, %rdi
callq 0x4150
leaq 0x27f19(%rip), %rdi     # 0x2d688
leaq 0x26a78(%rip), %rcx     # 0x2c1ee
movq %r14, %rsi
movl $0x624, %edx            # imm = 0x624
callq 0x41c0
leaq 0x269d3(%rip), %rdi     # 0x2c15d
leaq 0x269d9(%rip), %rsi     # 0x2c16a
leaq 0x26a56(%rip), %rcx     # 0x2c1ee
movl $0x619, %edx            # imm = 0x619
callq 0x41c0
movq 0x3180f(%rip), %r14     # 0x36fb8
leaq 0x269f5(%rip), %rsi     # 0x2c1a5
movq %r14, %rdi
callq 0x4310
movq %rax, %rdi
movl %ebp, %esi
callq 0x4440
leaq 0x269f2(%rip), %rsi     # 0x2c1bb
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
movl %ebx, %esi
callq 0x4440
leaq 0x28bc3(%rip), %rsi     # 0x2e3a5
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
callq 0x4150
leaq 0x26971(%rip), %rbx     # 0x2c16a
movq %r14, %rdi
movq %rbx, %rsi
callq 0x4310
leaq 0x27f9d(%rip), %rsi     # 0x2d7a8
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
movl $0x61b, %esi            # imm = 0x61B
callq 0x4610
movq %rax, %rdi
callq 0x4150
leaq 0x27e59(%rip), %rdi     # 0x2d688
leaq 0x269b8(%rip), %rcx     # 0x2c1ee
movq %rbx, %rsi
movl $0x61b, %edx            # imm = 0x61B
callq 0x41c0
nop