// File: /workspace/github_cpp_makefile_star2_O1/BenLangmead[P]bowtie/./ebwt.h
// Function: SideLocus::initFromRow(unsigned long, EbwtParams const&, unsigned char const*)
void initFromRow(TIndexOffU row, const EbwtParams& ep, const uint8_t* ebwt) {
		const uint32_t sideSz     = ep._sideSz;
		// Side length is hard-coded for now; this allows the compiler
		// to do clever things to accelerate / and %.
		if (ep._isBt2Index) {
			_sideNum = row / (48*OFF_SIZE);
			_charOff = row % (48*OFF_SIZE);
		} else {
			_sideNum = row / (56*OFF_SIZE);
			_charOff = row % (56*OFF_SIZE);
		}
		_sideByteOff = _sideNum * sideSz;
		assert_leq(row, ep._len);
		assert_leq(_sideByteOff + sideSz, ep._ebwtTotSz);
#ifndef NO_PREFETCH
		__builtin_prefetch((const void *)(ebwt + _sideByteOff),
		                   0 /* prepare for read */,
		                   PREFETCH_LOCALITY);
#endif
		// prefetch this side too
		_fw = ep._isBt2Index ? true : ((_sideNum & 1) != 0); // odd-numbered sides are forward
		_by = _charOff >> 2; // byte within side
		assert_lt(_by, (int)ep._sideBwtSz);
		_bp = _charOff & 3;  // bit-pair within byte
		if(!_fw) {
			_by = ep._sideBwtSz - _by - 1;
			_bp ^= 3;
		}
	}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r12
movl 0x84(%rdx), %r15d
movzbl 0xb9(%rdx), %esi
xorl $0x1, %esi
shll $0x6, %esi
orq $0x180, %rsi            # imm = 0x180
movq %r12, %rax
xorl %edx, %edx
divq %rsi
movq %rax, 0x8(%rdi)
movw %dx, 0x10(%rdi)
movq %rax, %rdx
imulq %r15, %rdx
movq %rdx, (%rdi)
cmpq %r12, (%rbx)
jb 0x107ca
movq %rdi, %r14
leaq (%rdx,%r15), %rsi
cmpq 0xb0(%rbx), %rsi
ja 0x1086d
prefetcht1 (%rcx,%rdx)
andb $0x1, %al
cmpb $0x0, 0xb9(%rbx)
movzbl %al, %eax
movl $0x1, %ecx
cmovel %eax, %ecx
movb %cl, 0x12(%r14)
movzwl 0x10(%r14), %eax
movl %eax, %edx
shrl $0x2, %edx
movw %dx, 0x14(%r14)
cmpl %edx, 0x88(%rbx)
jle 0x10917
andb $0x3, %al
movb %al, 0x16(%r14)
testb %cl, %cl
jne 0x107be
movzwl %dx, %ecx
notl %ecx
addw 0x88(%rbx), %cx
movw %cx, 0x14(%r14)
xorb $0x3, %al
movb %al, 0x16(%r14)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq 0x267e7(%rip), %r14     # 0x36fb8
leaq 0x1c9e8(%rip), %rsi     # 0x2d1c0
movq %r14, %rdi
callq 0x4310
movq %rax, %rdi
movq %r12, %rsi
callq 0x40c0
leaq 0x1c9e5(%rip), %rsi     # 0x2d1d7
movq %rax, %rdi
callq 0x4310
movq (%rbx), %rsi
movq %rax, %rdi
callq 0x40c0
leaq 0x1eb09(%rip), %rsi     # 0x2f315
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
callq 0x4150
leaq 0x1c8b7(%rip), %rbx     # 0x2d0da
movq %r14, %rdi
movq %rbx, %rsi
callq 0x4310
leaq 0x1dee3(%rip), %rsi     # 0x2e718
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
movl $0x5c9, %esi            # imm = 0x5C9
callq 0x4610
movq %rax, %rdi
callq 0x4150
leaq 0x1dd9f(%rip), %rdi     # 0x2e5f8
leaq 0x1dad4(%rip), %rcx     # 0x2e334
movq %rbx, %rsi
movl $0x5c9, %edx            # imm = 0x5C9
callq 0x41c0
movq 0x26744(%rip), %r12     # 0x36fb8
leaq 0x1c945(%rip), %rsi     # 0x2d1c0
movq %r12, %rdi
callq 0x4310
addq (%r14), %r15
movq %rax, %rdi
movq %r15, %rsi
callq 0x40c0
leaq 0x1c93f(%rip), %rsi     # 0x2d1d7
movq %rax, %rdi
callq 0x4310
movq 0xb0(%rbx), %rsi
movq %rax, %rdi
callq 0x40c0
leaq 0x1ea5f(%rip), %rsi     # 0x2f315
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
callq 0x4150
leaq 0x1c80d(%rip), %rbx     # 0x2d0da
movq %r12, %rdi
movq %rbx, %rsi
callq 0x4310
leaq 0x1de39(%rip), %rsi     # 0x2e718
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
movl $0x5ca, %esi            # imm = 0x5CA
callq 0x4610
movq %rax, %rdi
callq 0x4150
leaq 0x1dcf5(%rip), %rdi     # 0x2e5f8
leaq 0x1da2a(%rip), %rcx     # 0x2e334
movq %rbx, %rsi
movl $0x5ca, %edx            # imm = 0x5CA
callq 0x41c0
movq 0x2669a(%rip), %r15     # 0x36fb8
leaq 0x1c93f(%rip), %rsi     # 0x2d264
movq %r15, %rdi
callq 0x4310
movswl 0x14(%r14), %esi
movq %rax, %rdi
callq 0x42c0
leaq 0x1c939(%rip), %rsi     # 0x2d27a
movq %rax, %rdi
callq 0x4310
movl 0x88(%rbx), %esi
movq %rax, %rdi
callq 0x4610
leaq 0x1e9b7(%rip), %rsi     # 0x2f315
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
callq 0x4150
leaq 0x1c765(%rip), %rbx     # 0x2d0da
movq %r15, %rdi
movq %rbx, %rsi
callq 0x4310
leaq 0x1dd91(%rip), %rsi     # 0x2e718
movq %rax, %rdi
callq 0x4310
movq %rax, %rdi
movl $0x5d3, %esi            # imm = 0x5D3
callq 0x4610
movq %rax, %rdi
callq 0x4150
leaq 0x1dc4d(%rip), %rdi     # 0x2e5f8
leaq 0x1d982(%rip), %rcx     # 0x2e334
movq %rbx, %rsi
movl $0x5d3, %edx            # imm = 0x5D3
callq 0x41c0
nop