// File: /workspace/github_cpp_makefile_star2_O1/dsharlet[P]array/test/split.cpp
// Function: nda::test_split_uneven_nonconstant_body()
TEST(split_uneven_nonconstant) {
  dense_array<int, 3> a({dense_dim<>(2, 8), dim<>(1, 9), 4});
  size_t total_size = 0;
  for (auto zo : split(a.z(), 12)) {
    for (auto xo : split(a.x(), 5)) {
      auto a_inner = a(xo, _, zo);
      total_size += a_inner.size();
      fill_pattern(a_inner);
    }
  }
  // The total number of items in the inner splits should be equal to the size
  // of the array (no overlap among inner splits).
  ASSERT_EQ(total_size, a.size());
  check_pattern(a);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x268, %rsp            # imm = 0x268
movl $0x2, %r14d
leaq 0xd8(%rsp), %rsi
movq %r14, (%rsi)
movl $0x8, %r12d
movq %r12, 0x8(%rsi)
movl $0x1, %r13d
movq %r13, 0x10(%rsi)
xorl %ebp, %ebp
xorl %edi, %edi
callq 0xd09f
xorps %xmm0, %xmm0
leaq 0x60(%rsp), %r15
movups %xmm0, 0x8(%r15)
movups %xmm0, 0x18(%r15)
movq $0x4, 0x28(%r15)
movabsq $-0x8000000000000000, %rax # imm = 0x8000000000000000
movq %rax, 0x30(%r15)
movq %r13, 0x38(%r15)
movq $0x9, 0x40(%r15)
movq %rax, 0x48(%r15)
movq %r14, 0x50(%r15)
movq %r12, 0x58(%r15)
movq %r15, %rdi
callq 0xc2a2
movq %r15, %rdi
callq 0xc38a
movq 0x28(%r15), %rax
testq %rax, %rax
je 0x9d54c
leaq 0x98(%rsp), %rcx
movq -0x18(%rcx), %rcx
leaq (%rax,%rcx), %rdx
movq %rdx, 0x40(%rsp)
cmpq $0xc, %rax
movl $0xc, %ebx
cmovlq %rax, %rbx
movq %rcx, 0x8(%rsp)
addq %rcx, %rax
decq %rax
movq %rax, 0x38(%rsp)
xorl %ebp, %ebp
movq 0xb8(%rsp), %r13
testq %r13, %r13
je 0x9d51c
movq 0xb0(%rsp), %r15
leaq (%r15,%r13), %rax
movq %rax, 0x50(%rsp)
leaq (%r15,%r13), %rax
decq %rax
movq %rax, 0x48(%rsp)
cmpq $0x5, %r13
movl $0x5, %eax
cmovgeq %rax, %r13
movq %rbp, %r12
movq 0x78(%rsp), %rbp
leaq 0x98(%rsp), %rcx
movq 0x10(%rcx), %rax
leaq 0xf8(%rsp), %rdx
movq %rax, 0x10(%rdx)
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq 0x90(%rsp), %rax
movq %rax, 0x58(%rsp)
movq %r15, 0x10(%rsp)
movq %r13, 0x18(%rsp)
movq $0x1, 0x20(%rsp)
xorl %edi, %edi
leaq 0x10(%rsp), %r14
movq %r14, %rsi
callq 0xd09f
movq %r15, %rax
subq 0xb0(%rsp), %rax
movq 0x8(%rsp), %rdx
movq %rdx, %rcx
subq 0x80(%rsp), %rcx
imulq 0x90(%rsp), %rcx
testq %rbp, %rbp
leaq (%rbp,%rax,4), %rax
leaq (%rax,%rcx,4), %rax
cmoveq %rbp, %rax
movq %rax, 0xd8(%rsp)
movq %rdx, 0xe0(%rsp)
movq %rbx, 0xe8(%rsp)
movq 0x58(%rsp), %rax
movq %rax, 0xf0(%rsp)
movq %r15, 0x110(%rsp)
movq %r13, 0x118(%rsp)
movq 0x100(%rsp), %rbp
movl $0x0, 0xc8(%rsp)
leaq 0xc8(%rsp), %rax
movq %rax, 0x10(%rsp)
leaq 0xd8(%rsp), %rax
movq %rax, 0x18(%rsp)
leaq 0xe0(%rsp), %rdi
movq %r14, %rsi
callq 0x5fc7c
movq %r13, %rax
imulq %rbx, %rax
imulq %rbp, %rax
testq %rax, %rax
movl $0x0, %ecx
cmovleq %rcx, %rax
movq %r12, %rbp
addq %rax, %rbp
addq %r13, %r15
addq %r15, %r13
decq %r13
movq 0x48(%rsp), %rax
cmpq %r13, %rax
cmovlq %rax, %r13
subq %r15, %r13
incq %r13
cmpq 0x50(%rsp), %r15
jne 0x9d3de
movq 0x8(%rsp), %rax
addq %rbx, %rax
addq %rax, %rbx
decq %rbx
movq 0x38(%rsp), %rcx
cmpq %rbx, %rcx
cmovlq %rcx, %rbx
subq %rax, %rbx
incq %rbx
movq %rax, 0x8(%rsp)
cmpq 0x40(%rsp), %rax
jne 0x9d3a3
movq 0xb8(%rsp), %r13
movq 0x88(%rsp), %r15
movq 0xa0(%rsp), %r14
leaq 0x20(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x217c0(%rip), %rsi     # 0xbed35
leaq 0x217cf(%rip), %rdx     # 0xbed4b
leaq 0x10(%rsp), %rdi
callq 0xd0b8
imulq %r13, %r14
imulq %r15, %r14
xorl %eax, %eax
testq %r14, %r14
cmovgq %r14, %rax
xorl %esi, %esi
cmpq %rax, %rbp
sete %sil
leaq 0xd8(%rsp), %rdi
leaq 0x10(%rsp), %r14
movq %r14, %rdx
callq 0xbf0a
leaq 0x4098(%rip), %rsi      # 0xa1654
leaq 0xd8(%rsp), %rdi
callq 0x18a16
leaq 0x21afa(%rip), %rsi     # 0xbf0ca
movq %rax, %rdi
callq 0x18abe
leaq 0x7d4b(%rip), %rsi      # 0xa532a
movq %rax, %rdi
callq 0x18a16
movq %rax, %r15
cmpb $0x1, 0x188(%rax)
jne 0x9d602
movq %r15, %rdi
addq $0x10, %rdi
movq %rbp, %rsi
callq 0x2110
leaq 0x404b(%rip), %rsi      # 0xa1654
movq %r15, %rdi
callq 0x18a16
leaq 0x2172b(%rip), %rsi     # 0xbed43
movq %rax, %rdi
callq 0x19c24
leaq 0x7d03(%rip), %rsi      # 0xa532a
movq %rax, %rdi
callq 0x18a16
movq %rax, %rbx
cmpb $0x1, 0x188(%rax)
jne 0x9d66a
movq 0xb8(%rsp), %rax
imulq 0xa0(%rsp), %rax
imulq 0x88(%rsp), %rax
xorl %esi, %esi
testq %rax, %rax
cmovgq %rax, %rsi
movq %rbx, %rdi
addq $0x10, %rdi
callq 0x2110
leaq 0x1acf8(%rip), %rsi     # 0xb8369
movq %rbx, %rdi
callq 0x18a16
leaq 0xd8(%rsp), %rbx
movq %rbx, %rdi
callq 0xbf62
leaq 0x80(%rsp), %r15
movq 0x10(%rsp), %rdi
cmpq %r12, %rdi
je 0x9d6a8
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x21f0
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movq $0x0, 0x20(%rsp)
movq 0x78(%rsp), %rcx
leaq 0xe0(%rsp), %rax
movq %rcx, -0x8(%rax)
movl $0x9, %ecx
movq %rax, %rdi
movq %r15, %rsi
rep  movsq (%rsi), %es:(%rdi)
leaq 0xc8(%rsp), %rsi
movq %rbx, (%rsi)
movq %r14, 0x8(%rsi)
movq %rax, %rdi
callq 0x1e56e
leaq 0x60(%rsp), %rdi
callq 0xd16c
addq $0x268, %rsp            # imm = 0x268
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x9d758
jmp 0x9d743
jmp 0x9d743
jmp 0x9d718
movq %rax, %rbx
jmp 0x9d728
movq %rax, %rbx
leaq 0xd8(%rsp), %rdi
callq 0xbf62
movq 0x10(%rsp), %rdi
cmpq %r12, %rdi
je 0x9d746
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x21f0
jmp 0x9d746
jmp 0x9d758
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0xd16c
movq %rbx, %rdi
callq 0x2300
movq %rax, %rdi
callq 0xc036