// File: /workspace/github_cpp_makefile_star2_O3/dsharlet[P]array/test/array.cpp
// Function: nda::test_array_move_body()
TEST(array_move) {
  array_of_rank<int, 3> a({4, 5, 6});
  fill_pattern(a);

  dense_array<int, 3> b({4, 5, 6});
  move(a, b);
  check_pattern(b);

  array_of_rank<int, 3> c({dim<>(0, 4, 2), 5, 6});
  move(b, c);
  check_pattern(c);

  array_of_rank<int, 3> d = make_move(a, c.shape());
  ASSERT_EQ(c.shape(), d.shape());
  check_pattern(d);

  dense_array<int, 3> e = make_move(a, b.shape());
  ASSERT_EQ(b.shape(), e.shape());
  check_pattern(e);

  dense_array<int, 3> g({4, {1, 2}, 5});
  move(a, g);
  check_pattern(g);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x468, %rsp            # imm = 0x468
movabsq $-0x8000000000000000, %r13 # imm = 0x8000000000000000
leaq 0x228(%rsp), %rbx
xorps %xmm0, %xmm0
movups %xmm0, -0x8(%rbx)
movups %xmm0, -0x18(%rbx)
movq $0x6, 0x8(%rbx)
movq %r13, 0x10(%rbx)
xorl %eax, %eax
movq %rax, 0x18(%rbx)
movq $0x5, 0x20(%rbx)
movq %r13, 0x28(%rbx)
movq %rax, 0x30(%rbx)
movq $0x4, 0x38(%rbx)
movq %r13, 0x40(%rbx)
leaq 0x208(%rsp), %r14
movq %r14, %rdi
callq 0x1a8cc
movq %r14, %rdi
callq 0x1a9a6
movq 0x18(%r14), %rcx
leaq 0x278(%rsp), %rax
movq %rcx, -0x8(%rax)
movl $0x9, %ecx
movq %rax, %rdi
movq %rbx, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x130(%rsp), %rcx
movl $0x0, (%rcx)
leaq 0xc8(%rsp), %rsi
movq %rcx, (%rsi)
leaq 0x270(%rsp), %rcx
movq %rcx, 0x8(%rsi)
movq %rax, %rdi
callq 0x1d948
leaq 0x270(%rsp), %rsi
movq $0x0, (%rsi)
movq $0x4, 0x8(%rsi)
movq %r13, 0x10(%rsi)
xorl %edi, %edi
callq 0xd133
xorps %xmm0, %xmm0
leaq 0xc8(%rsp), %rdi
movups %xmm0, 0x8(%rdi)
movups %xmm0, 0x18(%rdi)
movq $0x6, 0x28(%rdi)
movq %r13, 0x30(%rdi)
xorl %eax, %eax
movq %rax, 0x38(%rdi)
movq $0x5, 0x40(%rdi)
movq %r13, 0x48(%rdi)
movq %rax, 0x50(%rdi)
movq $0x4, 0x58(%rdi)
callq 0xc30a
leaq 0xc8(%rsp), %rdi
callq 0xc412
leaq 0xe8(%rsp), %r14
movq 0x220(%rsp), %rax
leaq 0x278(%rsp), %rdi
movq %rax, -0x8(%rdi)
movl $0x9, %ecx
movq %rbx, %rsi
rep  movsq (%rsi), %es:(%rdi)
movq -0x8(%r14), %rax
leaq 0x138(%rsp), %rdi
movq %rax, -0x8(%rdi)
movl $0x9, %ecx
movq %r14, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x270(%rsp), %r15
leaq 0x130(%rsp), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x1c2fc
xorps %xmm0, %xmm0
movaps %xmm0, 0x130(%rsp)
movq $0x0, 0x140(%rsp)
movq 0xe0(%rsp), %rcx
leaq 0x278(%rsp), %rax
movq %rcx, -0x8(%rax)
movl $0x9, %ecx
movq %rax, %rdi
movq %r14, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x1a0(%rsp), %rsi
movq %r15, (%rsi)
movq %r12, 0x8(%rsi)
movq %rax, %rdi
callq 0x1f012
leaq 0x130(%rsp), %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x18(%rdi)
movups %xmm0, 0x8(%rdi)
movq $0x6, 0x28(%rdi)
movq %r13, 0x30(%rdi)
xorl %eax, %eax
movq %rax, 0x38(%rdi)
movq $0x5, 0x40(%rdi)
movq %r13, 0x48(%rdi)
movq %rax, 0x50(%rdi)
movq $0x4, 0x58(%rdi)
movq $0x2, 0x60(%rdi)
callq 0x1a8cc
leaq 0x130(%rsp), %rdi
callq 0x1a9a6
leaq 0x150(%rsp), %r13
movq 0xe0(%rsp), %rax
leaq 0x278(%rsp), %rdi
movq %rax, -0x8(%rdi)
movl $0x9, %ecx
movq %r14, %rsi
rep  movsq (%rsi), %es:(%rdi)
movq -0x8(%r13), %rax
leaq 0x1a8(%rsp), %rdi
movq %rax, -0x8(%rdi)
movl $0x9, %ecx
movq %r13, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x270(%rsp), %r15
leaq 0x1a0(%rsp), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x1ff4d
xorps %xmm0, %xmm0
movaps %xmm0, 0x1a0(%rsp)
movq $0x0, 0x1b0(%rsp)
movq 0x148(%rsp), %rcx
leaq 0x278(%rsp), %rax
movq %rcx, -0x8(%rax)
movl $0x9, %ecx
movq %rax, %rdi
movq %r13, %rsi
rep  movsq (%rsi), %es:(%rdi)
movq %rsp, %rsi
movq %r15, (%rsi)
movq %r12, 0x8(%rsi)
movq %rax, %rdi
callq 0x1f848
movq 0x220(%rsp), %rax
leaq 0x278(%rsp), %rdi
movq %rax, -0x8(%rdi)
movl $0x9, %ecx
movq %rbx, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x1a0(%rsp), %rdi
leaq 0x270(%rsp), %rsi
movq %rsp, %rcx
movq %r13, %rdx
callq 0x1bed9
leaq 0x1c0(%rsp), %r15
movq %r13, %rdi
movq %r15, %rsi
callq 0x1dd08
movl %eax, %ebp
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x8f3f8(%rip), %rsi     # 0xa5012
leaq 0x8f407(%rip), %rdx     # 0xa5028
movq %rsp, %rdi
callq 0xd14c
movzbl %bpl, %esi
leaq 0x270(%rsp), %rdi
movq %rsp, %r12
movq %r12, %rdx
callq 0xbf80
leaq 0x8da3d(%rip), %rsi     # 0xa3684
leaq 0x270(%rsp), %rdi
callq 0x18fba
leaq 0x8f3ce(%rip), %rsi     # 0xa5029
movq %rax, %rdi
callq 0x1902a
leaq 0x915ec(%rip), %rsi     # 0xa7256
movq %rax, %rdi
callq 0x18fba
movq %rax, %rbp
cmpb $0x1, 0x188(%rax)
jne 0x15c8d
movq %rbp, %rdi
addq $0x10, %rdi
movq %r13, %rsi
callq 0x1fb71
leaq 0x8d9f0(%rip), %rsi     # 0xa3684
movq %rbp, %rdi
callq 0x18fba
leaq 0x8f37c(%rip), %rsi     # 0xa501f
movq %rax, %rdi
callq 0x1902a
leaq 0x915a4(%rip), %rsi     # 0xa7256
movq %rax, %rdi
callq 0x18fba
movq %rax, %r13
cmpb $0x1, 0x188(%rax)
jne 0x15cd5
movq %r13, %rdi
addq $0x10, %rdi
movq %r15, %rsi
callq 0x1fb71
leaq 0xa45bd(%rip), %rsi     # 0xba299
movq %r13, %rdi
callq 0x18fba
leaq 0x270(%rsp), %r13
movq %r13, %rdi
callq 0xbfd8
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0x15d0a
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x21f0
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
movq 0x1b8(%rsp), %rcx
leaq 0x278(%rsp), %rax
movq %rcx, -0x8(%rax)
movl $0x9, %ecx
movq %rax, %rdi
movq %r15, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x70(%rsp), %rsi
movq %r13, (%rsi)
movq %r12, 0x8(%rsi)
movq %rax, %rdi
callq 0x1f848
leaq 0xe8(%rsp), %r14
movq 0x220(%rsp), %rax
leaq 0x278(%rsp), %rdi
movq %rax, -0x8(%rdi)
movl $0x9, %ecx
movq %rbx, %rsi
rep  movsq (%rsi), %es:(%rdi)
movq %rsp, %rdi
leaq 0x270(%rsp), %rsi
leaq 0x70(%rsp), %rcx
movq %r14, %rdx
callq 0x1c174
movq 0x118(%rsp), %rax
xorl %ebp, %ebp
cmpq 0x50(%rsp), %rax
jne 0x15e0f
movq 0x58(%rsp), %rax
cmpq %rax, 0x120(%rsp)
jne 0x15e0f
movq 0x100(%rsp), %rax
cmpq 0x38(%rsp), %rax
jne 0x15e0d
movq 0x108(%rsp), %rax
cmpq 0x40(%rsp), %rax
jne 0x15e0d
movq 0x110(%rsp), %rax
cmpq 0x48(%rsp), %rax
jne 0x15e0d
movq 0xe8(%rsp), %rax
cmpq 0x20(%rsp), %rax
jne 0x15e0d
movq 0xf0(%rsp), %rax
cmpq 0x28(%rsp), %rax
jne 0x15e0d
movq 0xf8(%rsp), %rax
cmpq 0x30(%rsp), %rax
sete %bpl
jmp 0x15e0f
xorl %ebp, %ebp
leaq 0x80(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x8f211(%rip), %rsi     # 0xa5033
leaq 0x8f220(%rip), %rdx     # 0xa5049
leaq 0x70(%rsp), %rdi
callq 0xd14c
movzbl %bpl, %esi
leaq 0x270(%rsp), %rdi
leaq 0x70(%rsp), %r15
movq %r15, %rdx
callq 0xbf80
leaq 0x8d831(%rip), %rsi     # 0xa3684
leaq 0x270(%rsp), %rdi
callq 0x18fba
leaq 0x8f1e3(%rip), %rsi     # 0xa504a
movq %rax, %rdi
callq 0x1902a
leaq 0x913e0(%rip), %rsi     # 0xa7256
movq %rax, %rdi
callq 0x18fba
movq %rax, %r12
cmpb $0x1, 0x188(%rax)
jne 0x15e99
movq %r12, %rdi
addq $0x10, %rdi
movq %r14, %rsi
callq 0x1fcd1
leaq 0x8d7e4(%rip), %rsi     # 0xa3684
movq %r12, %rdi
callq 0x18fba
leaq 0x8f191(%rip), %rsi     # 0xa5040
movq %rax, %rdi
callq 0x1902a
leaq 0x91398(%rip), %rsi     # 0xa7256
movq %rax, %rdi
callq 0x18fba
movq %rax, %r12
leaq 0x20(%rsp), %r14
cmpb $0x1, 0x188(%rax)
jne 0x15ee6
movq %r12, %rdi
addq $0x10, %rdi
movq %r14, %rsi
callq 0x1fcd1
leaq 0xa43ac(%rip), %rsi     # 0xba299
movq %r12, %rdi
callq 0x18fba
leaq 0x270(%rsp), %r12
movq %r12, %rdi
callq 0xbfd8
movq 0x70(%rsp), %rdi
cmpq %r13, %rdi
je 0x15f1f
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x21f0
xorps %xmm0, %xmm0
movaps %xmm0, 0x70(%rsp)
movq $0x0, 0x80(%rsp)
movq 0x18(%rsp), %rcx
leaq 0x278(%rsp), %rax
movq %rcx, -0x8(%rax)
movl $0x9, %ecx
movq %rax, %rdi
movq %r14, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x400(%rsp), %rsi
movq %r12, (%rsi)
movq %r15, 0x8(%rsi)
movq %rax, %rdi
callq 0x1f012
movabsq $-0x8000000000000000, %r14 # imm = 0x8000000000000000
leaq 0x70(%rsp), %rsi
movq $0x0, (%rsi)
movq $0x4, 0x8(%rsi)
movq $0x1, 0x10(%rsi)
xorl %edi, %edi
callq 0xd133
xorps %xmm0, %xmm0
leaq 0x270(%rsp), %rdi
movups %xmm0, 0x8(%rdi)
movups %xmm0, 0x18(%rdi)
movq $0x5, 0x28(%rdi)
movq %r14, 0x30(%rdi)
movq $0x1, 0x38(%rdi)
movq $0x2, 0x40(%rdi)
movq %r14, 0x48(%rdi)
movq $0x0, 0x50(%rdi)
movq $0x4, 0x58(%rdi)
callq 0xc30a
leaq 0x270(%rsp), %rdi
callq 0xc412
leaq 0x290(%rsp), %r14
movq 0x220(%rsp), %rax
leaq 0x78(%rsp), %rdi
movq %rax, -0x8(%rdi)
movl $0x9, %ecx
movq %rbx, %rsi
rep  movsq (%rsi), %es:(%rdi)
movq -0x8(%r14), %rax
leaq 0x408(%rsp), %rdi
movq %rax, -0x8(%rdi)
movl $0x9, %ecx
movq %r14, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x70(%rsp), %rbx
leaq 0x400(%rsp), %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1c2fc
xorps %xmm0, %xmm0
movaps %xmm0, 0x400(%rsp)
movq $0x0, 0x410(%rsp)
movq 0x288(%rsp), %rcx
leaq 0x78(%rsp), %rax
movq %rcx, -0x8(%rax)
movl $0x9, %ecx
movq %rax, %rdi
movq %r14, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0x458(%rsp), %rsi
movq %rbx, (%rsi)
movq %r15, 0x8(%rsi)
movq %rax, %rdi
callq 0x1f012
leaq 0x270(%rsp), %rdi
callq 0xd206
movq %rsp, %rdi
callq 0xd206
leaq 0x1a0(%rsp), %rdi
callq 0x1d848
leaq 0x130(%rsp), %rdi
callq 0x1d848
leaq 0xc8(%rsp), %rdi
callq 0xd206
leaq 0x208(%rsp), %rdi
callq 0x1d848
addq $0x468, %rsp            # imm = 0x468
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x16204
jmp 0x16204
jmp 0x16204
jmp 0x16204
jmp 0x16204
jmp 0x16204
jmp 0x1610a
movq %rax, %rbx
leaq 0x270(%rsp), %rdi
callq 0xd206
jmp 0x1618e
jmp 0x16204
jmp 0x16157
jmp 0x16157
jmp 0x1612b
jmp 0x1612b
jmp 0x1612b
movq %rax, %rbx
jmp 0x161c0
jmp 0x16137
jmp 0x16137
movq %rax, %rbx
jmp 0x161cd
jmp 0x1614f
jmp 0x1614f
jmp 0x1615c
movq %rax, %rbx
jmp 0x16174
movq %rax, %rbx
jmp 0x161aa
movq %rax, %rbx
jmp 0x161da
movq %rax, %rbx
jmp 0x1618e
movq %rax, %rbx
jmp 0x161e7
movq %rax, %rbx
leaq 0x270(%rsp), %rdi
callq 0xbfd8
movq 0x70(%rsp), %rdi
cmpq %r13, %rdi
je 0x1618e
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x21f0
movq %rsp, %rdi
callq 0xd206
jmp 0x161c0
jmp 0x16204
movq %rax, %rbx
leaq 0x270(%rsp), %rdi
callq 0xbfd8
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0x161c0
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x21f0
leaq 0x1a0(%rsp), %rdi
callq 0x1d848
leaq 0x130(%rsp), %rdi
callq 0x1d848
leaq 0xc8(%rsp), %rdi
callq 0xd206
leaq 0x208(%rsp), %rdi
callq 0x1d848
movq %rbx, %rdi
callq 0x2300
jmp 0x16204
jmp 0x16204
jmp 0x16204
jmp 0x16204
movq %rax, %rdi
callq 0xc0a9