// File: /workspace/github_cpp_makefile_star2_O2/kdungs[P]cpp-prelude/test_prelude.cc
// Function: test_splitAt()
auto test_splitAt() -> void {
  using Prelude::splitAt;
  auto expectL = std::vector<int>{1, 2, 3, 4};
  auto expectR = std::vector<int>{5, 6, 7, 8};
  std::vector<int> resultL, resultR;
  std::tie(resultL, resultR) =
      splitAt(4, std::vector<int>{1, 2, 3, 4, 5, 6, 7, 8});
  assert(resultL == expectL);
  assert(resultR == expectR);
  // empty first half
  expectL = std::vector<int>{};
  expectR = std::vector<int>{1, 2, 3, 4};
  std::tie(resultL, resultR) = splitAt(0, std::vector<int>{1, 2, 3, 4});
  assert(resultL == expectL);
  assert(resultR == expectR);
  // empty second half
  expectL = std::vector<int>{1, 2, 3, 4};
  expectR = std::vector<int>{};
  std::tie(resultL, resultR) = splitAt(10, std::vector<int>{1, 2, 3, 4});
  assert(resultL == expectL);
  assert(resultR == expectR);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x100, %rsp            # imm = 0x100
movaps 0x5371(%rip), %xmm0     # 0x9010
leaq 0xa0(%rsp), %rbx
movaps %xmm0, (%rbx)
leaq 0x88(%rsp), %rdi
pushq $0x4
popq %r14
leaq 0x10(%rsp), %rcx
movq %rbx, %rsi
movq %r14, %rdx
callq 0x55b0
movaps 0x5373(%rip), %xmm0     # 0x9040
movaps %xmm0, (%rbx)
leaq 0x70(%rsp), %rdi
leaq 0xa0(%rsp), %rsi
leaq 0x10(%rsp), %rcx
movq %r14, %rdx
callq 0x55b0
xorps %xmm0, %xmm0
movaps %xmm0, 0xd0(%rsp)
andq $0x0, 0xe0(%rsp)
movaps %xmm0, 0x50(%rsp)
andq $0x0, 0x60(%rsp)
movups 0x5ef4(%rip), %xmm0     # 0x9c04
leaq 0x10(%rsp), %rsi
movaps %xmm0, 0x10(%rsi)
movups 0x5ed4(%rip), %xmm0     # 0x9bf4
movaps %xmm0, (%rsi)
leaq 0x30(%rsp), %rdi
pushq $0x8
popq %rdx
leaq 0xf(%rsp), %rcx
callq 0x55b0
leaq 0xa0(%rsp), %rdi
pushq $0x4
popq %rsi
leaq 0x30(%rsp), %rdx
callq 0x59c8
leaq 0x50(%rsp), %rax
leaq 0xf0(%rsp), %rdi
movq %rax, (%rdi)
leaq 0xd0(%rsp), %rbx
movq %rbx, 0x8(%rdi)
leaq 0xa0(%rsp), %r14
movq %r14, %rsi
callq 0x5a38
movq %r14, %rdi
callq 0x5a4e
leaq 0x30(%rsp), %rdi
callq 0x62fa
leaq 0x88(%rsp), %rsi
movq %rbx, %rdi
callq 0x5670
testb %al, %al
je 0x3ffd
leaq 0x50(%rsp), %r14
leaq 0x70(%rsp), %rsi
movq %r14, %rdi
callq 0x5670
testb %al, %al
je 0x401c
xorps %xmm0, %xmm0
leaq 0xa0(%rsp), %r15
movaps %xmm0, (%r15)
andq $0x0, 0x10(%r15)
leaq 0x88(%rsp), %rdi
movq %r15, %rsi
callq 0x7474
movq %r15, %rdi
callq 0x62fa
leaq 0x10(%rsp), %rsi
movaps 0x521e(%rip), %xmm0     # 0x9010
movaps %xmm0, (%rsi)
leaq 0xa0(%rsp), %rdi
pushq $0x4
popq %rdx
leaq 0x30(%rsp), %rcx
callq 0x55b0
leaq 0x70(%rsp), %rdi
leaq 0xa0(%rsp), %r15
movq %r15, %rsi
callq 0x7474
movq %r15, %rdi
callq 0x62fa
leaq 0x30(%rsp), %rsi
movaps 0x51dd(%rip), %xmm0     # 0x9010
movaps %xmm0, (%rsi)
leaq 0x10(%rsp), %rdi
pushq $0x4
popq %rdx
leaq 0xf(%rsp), %rcx
callq 0x55b0
leaq 0xa0(%rsp), %rdi
leaq 0x10(%rsp), %rdx
xorl %esi, %esi
callq 0x59c8
leaq 0xf0(%rsp), %rdi
movq %r14, (%rdi)
movq %rbx, 0x8(%rdi)
leaq 0xa0(%rsp), %r14
movq %r14, %rsi
callq 0x5a38
movq %r14, %rdi
callq 0x5a4e
leaq 0x10(%rsp), %rdi
callq 0x62fa
leaq 0x88(%rsp), %rsi
movq %rbx, %rdi
callq 0x5670
testb %al, %al
je 0x403b
leaq 0x50(%rsp), %r14
leaq 0x70(%rsp), %rsi
movq %r14, %rdi
callq 0x5670
testb %al, %al
je 0x405a
leaq 0x10(%rsp), %rsi
movaps 0x5145(%rip), %xmm0     # 0x9010
movaps %xmm0, (%rsi)
leaq 0xa0(%rsp), %rdi
pushq $0x4
popq %rdx
leaq 0x30(%rsp), %rcx
callq 0x55b0
leaq 0x88(%rsp), %rdi
leaq 0xa0(%rsp), %r15
movq %r15, %rsi
callq 0x7474
movq %r15, %rdi
callq 0x62fa
xorps %xmm0, %xmm0
movaps %xmm0, (%r15)
andq $0x0, 0x10(%r15)
leaq 0x70(%rsp), %rdi
leaq 0xa0(%rsp), %r15
movq %r15, %rsi
callq 0x7474
movq %r15, %rdi
callq 0x62fa
leaq 0x30(%rsp), %rsi
movaps 0x50d8(%rip), %xmm0     # 0x9010
movaps %xmm0, (%rsi)
leaq 0x10(%rsp), %rdi
pushq $0x4
popq %rdx
leaq 0xf(%rsp), %rcx
callq 0x55b0
leaq 0xa0(%rsp), %rdi
pushq $0xa
popq %rsi
leaq 0x10(%rsp), %rdx
callq 0x59c8
leaq 0xf0(%rsp), %rdi
movq %r14, (%rdi)
movq %rbx, 0x8(%rdi)
leaq 0xa0(%rsp), %r14
movq %r14, %rsi
callq 0x5a38
movq %r14, %rdi
callq 0x5a4e
leaq 0x10(%rsp), %rdi
callq 0x62fa
leaq 0x88(%rsp), %rsi
movq %rbx, %rdi
callq 0x5670
testb %al, %al
je 0x4079
leaq 0x50(%rsp), %rdi
leaq 0x70(%rsp), %rsi
callq 0x5670
testb %al, %al
je 0x4098
leaq 0x50(%rsp), %rdi
callq 0x62fa
leaq 0xd0(%rsp), %rdi
callq 0x62fa
leaq 0x70(%rsp), %rdi
callq 0x62fa
leaq 0x88(%rsp), %rdi
callq 0x62fa
addq $0x100, %rsp            # imm = 0x100
popq %rbx
popq %r14
popq %r15
retq
leaq 0x5536(%rip), %rdi      # 0x953a
leaq 0x5064(%rip), %rsi      # 0x906f
leaq 0x553b(%rip), %rcx      # 0x954d
movl $0xe2, %edx
callq 0x20c0
leaq 0x553e(%rip), %rdi      # 0x9561
leaq 0x5045(%rip), %rsi      # 0x906f
leaq 0x551c(%rip), %rcx      # 0x954d
movl $0xe3, %edx
callq 0x20c0
leaq 0x54f8(%rip), %rdi      # 0x953a
leaq 0x5026(%rip), %rsi      # 0x906f
leaq 0x54fd(%rip), %rcx      # 0x954d
movl $0xe8, %edx
callq 0x20c0
leaq 0x5500(%rip), %rdi      # 0x9561
leaq 0x5007(%rip), %rsi      # 0x906f
leaq 0x54de(%rip), %rcx      # 0x954d
movl $0xe9, %edx
callq 0x20c0
leaq 0x54ba(%rip), %rdi      # 0x953a
leaq 0x4fe8(%rip), %rsi      # 0x906f
leaq 0x54bf(%rip), %rcx      # 0x954d
movl $0xee, %edx
callq 0x20c0
leaq 0x54c2(%rip), %rdi      # 0x9561
leaq 0x4fc9(%rip), %rsi      # 0x906f
leaq 0x54a0(%rip), %rcx      # 0x954d
movl $0xef, %edx
callq 0x20c0
jmp 0x40bd
jmp 0x40e1
jmp 0x40e1
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
jmp 0x40d3
jmp 0x40e1
jmp 0x40e1
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x62fa
jmp 0x40e4
jmp 0x40e1
movq %rax, %rbx
jmp 0x4105
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x62fa
leaq 0xd0(%rsp), %rdi
callq 0x62fa
leaq 0x70(%rsp), %rdi
callq 0x62fa
leaq 0x88(%rsp), %rdi
callq 0x62fa
movq %rbx, %rdi
callq 0x21d0