// File: /workspace/github_cpp_makefile_star2_O2/aisthesis[P]realnumber/tst/array_arithmetic_test.cpp
// Function: bits::shift_right_invoker()
BOOST_AUTO_TEST_CASE(shift_right) {
		unsigned char arr[] = {129, 129, 129};
		array_arithmetic::bits::shift_right(arr, 1, 3);
		BOOST_CHECK_EQUAL(arr[0], 64);
		BOOST_CHECK_EQUAL(arr[1], 192);
		BOOST_CHECK_EQUAL(arr[2], 192);
		// reset array to original values
		for (std::size_t i = 0; i < 3; ++i) { arr[i] = 129; }
		array_arithmetic::bits::shift_right(arr, 15, 3);
		BOOST_CHECK_EQUAL(arr[0], 0);
		BOOST_CHECK_EQUAL(arr[1], 1);
		BOOST_CHECK_EQUAL(arr[2], 3);
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x240, %rsp            # imm = 0x240
movq 0xbe44(%rip), %rbx      # 0x16198
leaq 0x6d00(%rip), %r15      # 0x1105b
movq %r15, -0x70(%rbp)
leaq 0x6d12(%rip), %r12      # 0x11078
movq %r12, -0x68(%rbp)
leaq -0x208(%rbp), %r14
movl $0x198, %edx            # imm = 0x198
movq %r14, %rdi
xorl %esi, %esi
callq 0x30c0
movq %r14, %rdi
callq 0xeecc
pushq $0x22
popq %rsi
movq %r14, %rdi
callq 0x31a0
leaq 0x6f50(%rip), %rsi      # 0x112ea
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq 0x7622(%rip), %rsi      # 0x119cf
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq -0x208(%rbp), %rdi
callq 0xeefe
movq (%rax), %rdx
leaq -0x258(%rbp), %rcx
movq %rdx, (%rcx)
addq 0x8(%rax), %rdx
movq %rdx, 0x8(%rcx)
leaq -0x70(%rbp), %rsi
movl $0xbf, %edx
movq %rbx, %rdi
callq 0x32a0
leaq -0x208(%rbp), %rdi
callq 0xef42
movq 0xbd9a(%rip), %rbx      # 0x16198
movq %r15, -0x60(%rbp)
movq %r12, -0x58(%rbp)
movl $0x198, %edx            # imm = 0x198
movq %r14, %rdi
xorl %esi, %esi
callq 0x30c0
movq %r14, %rdi
callq 0xeecc
pushq $0x22
popq %rsi
movq %r14, %rdi
callq 0x31a0
leaq 0x6ebb(%rip), %rsi      # 0x112ea
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq 0x759c(%rip), %rsi      # 0x119de
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq -0x208(%rbp), %rdi
callq 0xeefe
movq (%rax), %rdx
leaq -0x248(%rbp), %rcx
movq %rdx, (%rcx)
addq 0x8(%rax), %rdx
movq %rdx, 0x8(%rcx)
leaq -0x60(%rbp), %rsi
movl $0xbf, %edx
movq %rbx, %rdi
callq 0x32a0
leaq -0x208(%rbp), %rdi
callq 0xef42
movq 0xbd05(%rip), %rbx      # 0x16198
movq %r15, -0x50(%rbp)
movq %r12, -0x48(%rbp)
movl $0x198, %edx            # imm = 0x198
movq %r14, %rdi
xorl %esi, %esi
callq 0x30c0
movq %r14, %rdi
callq 0xeecc
pushq $0x22
popq %rsi
movq %r14, %rdi
callq 0x31a0
leaq 0x6e26(%rip), %rsi      # 0x112ea
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq 0x7517(%rip), %rsi      # 0x119ee
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq -0x208(%rbp), %rdi
callq 0xeefe
movq (%rax), %rdx
leaq -0x238(%rbp), %rcx
movq %rdx, (%rcx)
addq 0x8(%rax), %rdx
movq %rdx, 0x8(%rcx)
leaq -0x50(%rbp), %rsi
movl $0xbf, %edx
movq %rbx, %rdi
callq 0x32a0
leaq -0x208(%rbp), %rdi
callq 0xef42
callq 0xa680
movq 0xbc6b(%rip), %rbx      # 0x16198
movq %r15, -0x40(%rbp)
movq %r12, -0x38(%rbp)
movl $0x198, %edx            # imm = 0x198
movq %r14, %rdi
xorl %esi, %esi
callq 0x30c0
movq %r14, %rdi
callq 0xeecc
pushq $0x22
popq %rsi
movq %r14, %rdi
callq 0x31a0
leaq 0x6d8c(%rip), %rsi      # 0x112ea
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq 0x748a(%rip), %rsi      # 0x119fb
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq -0x208(%rbp), %rdi
callq 0xeefe
movq (%rax), %rdx
leaq -0x228(%rbp), %rcx
movq %rdx, (%rcx)
addq 0x8(%rax), %rdx
movq %rdx, 0x8(%rcx)
leaq -0x40(%rbp), %rsi
movl $0xbf, %edx
movq %rbx, %rdi
callq 0x32a0
leaq -0x208(%rbp), %rdi
callq 0xef42
movq 0xbbd6(%rip), %rbx      # 0x16198
movq %r15, -0x30(%rbp)
movq %r12, -0x28(%rbp)
movl $0x198, %edx            # imm = 0x198
movq %r14, %rdi
xorl %esi, %esi
callq 0x30c0
movq %r14, %rdi
callq 0xeecc
pushq $0x22
popq %rsi
movq %r14, %rdi
callq 0x31a0
leaq 0x6cf7(%rip), %rsi      # 0x112ea
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq 0x7408(%rip), %rsi      # 0x11a0e
leaq -0x208(%rbp), %rdi
callq 0x3140
leaq -0x208(%rbp), %rdi
callq 0xeefe
movq (%rax), %rdx
leaq -0x218(%rbp), %rcx
movq %rdx, (%rcx)
addq 0x8(%rax), %rdx
movq %rdx, 0x8(%rcx)
leaq -0x30(%rbp), %rsi
movl $0xbf, %edx
movq %rbx, %rdi
callq 0x32a0
leaq -0x208(%rbp), %rdi
callq 0xef42
addq $0x240, %rsp            # imm = 0x240
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0xa668
jmp 0xa668
jmp 0xa668
jmp 0xa668
movq %rax, %rbx
leaq -0x208(%rbp), %rdi
callq 0xef42
movq %rbx, %rdi
callq 0x3260
nop