// File: /workspace/github_cpp_makefile_star2_O3/ridgelab[P]Kmer-SSR/src/Arguments.cpp
// Function: Arguments::split(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char)
vector<string> Arguments::split(string str, char sep)
{
	vector<string> v;
	vector<uint32_t> starts = {0};
	vector<uint32_t> ends;

	for (uint32_t i = 0; i < str.size(); ++i)
	{
		if (str[i] == sep)
		{
			ends.push_back(i);

			if (starts[starts.size() - 1] == ends[ends.size() - 1])
			{
				starts.pop_back();
				ends.pop_back();
			}

			starts.push_back(i + 1);
		}
	}

	ends.push_back(str.size());

	if (starts[starts.size() - 1] >= str.size())
	{
		starts.pop_back();
		ends.pop_back();
	}

	if (starts.size() != ends.size())
	{
		throw "ERROR: You should never see this, but starts and ends had different lengths in Arguments::split.";
	}

	for (uint32_t i = 0; i < starts.size(); ++i)
	{
		v.push_back(str.substr(starts[i], ends[i] - starts[i]));
	}

	return v;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movl %ecx, %ebp
movq %rdx, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
leaq 0x38(%rsp), %rsi
movl $0x0, (%rsi)
leaq 0x18(%rsp), %rdi
movq %rsp, %rcx
movl $0x1, %edx
callq 0x8a78
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
movl $0x0, 0x38(%rsp)
movq 0x8(%r14), %rax
testq %rax, %rax
je 0xc42e
xorl %ecx, %ecx
leaq 0x38(%rsp), %r12
leaq 0x18(%rsp), %r13
leaq 0x34(%rsp), %r15
movq (%r14), %rdx
cmpb %bpl, (%rdx,%rcx)
jne 0xc402
movq 0x8(%rsp), %rax
cmpq 0x10(%rsp), %rax
je 0xc39f
movl %ecx, (%rax)
addq $0x4, %rax
movq %rax, 0x8(%rsp)
jmp 0xc3b2
movq %rsp, %rdi
movq %rax, %rsi
movq %r12, %rdx
callq 0xcd70
movq 0x8(%rsp), %rax
movq 0x20(%rsp), %rsi
movl -0x4(%rsi), %ecx
cmpl -0x4(%rax), %ecx
jne 0xc3d1
addq $-0x4, %rsi
movq %rsi, 0x20(%rsp)
addq $-0x4, %rax
movq %rax, 0x8(%rsp)
movl 0x38(%rsp), %eax
incl %eax
movl %eax, 0x34(%rsp)
cmpq 0x28(%rsp), %rsi
je 0xc3ef
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x20(%rsp)
jmp 0xc3fa
movq %r13, %rdi
movq %r15, %rdx
callq 0x8e8e
movl 0x38(%rsp), %ecx
movq 0x8(%r14), %rax
incl %ecx
movl %ecx, 0x38(%rsp)
cmpq %rcx, %rax
ja 0xc37d
movq 0x8(%rsp), %rsi
movl %eax, 0x38(%rsp)
cmpq 0x10(%rsp), %rsi
je 0xc438
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rsp)
jmp 0xc44e
movl $0x0, 0x38(%rsp)
xorl %esi, %esi
movq %rsp, %rdi
leaq 0x38(%rsp), %rdx
callq 0x8e8e
movq 0x8(%r14), %rax
movq 0x8(%rsp), %rsi
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rcx
movl -0x4(%rcx), %edx
cmpq %rdx, %rax
ja 0xc472
addq $-0x4, %rcx
movq %rcx, 0x20(%rsp)
addq $-0x4, %rsi
movq %rsi, 0x8(%rsp)
movq %rcx, %rdx
subq %rdi, %rdx
movq (%rsp), %rax
subq %rax, %rsi
cmpq %rsi, %rdx
jne 0xc533
cmpq %rdi, %rcx
je 0xc4f5
movl $0x1, %ebp
leaq 0x48(%rsp), %r12
xorl %eax, %eax
leaq 0x38(%rsp), %r15
movl (%rdi,%rax,4), %edx
movq (%rsp), %rcx
movl (%rcx,%rax,4), %ecx
subl %edx, %ecx
movq %r15, %rdi
movq %r14, %rsi
callq 0x3320
movq %rbx, %rdi
movq %r15, %rsi
callq 0xce4c
movq 0x38(%rsp), %rdi
cmpq %r12, %rdi
je 0xc4d7
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x3300
movl %ebp, %eax
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rcx
subq %rdi, %rcx
sarq $0x2, %rcx
incl %ebp
cmpq %rax, %rcx
ja 0xc49e
movq (%rsp), %rax
testq %rax, %rax
je 0xc50f
movq 0x10(%rsp), %rsi
subq %rax, %rsi
movq %rax, %rdi
callq 0x3300
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0xc521
movq 0x28(%rsp), %rsi
subq %rdi, %rsi
callq 0x3300
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x8, %edi
callq 0x3160
leaq 0x2fd2(%rip), %rcx      # 0xf516
movq %rcx, (%rax)
movq 0x8a52(%rip), %rsi      # 0x14fa0
movq %rax, %rdi
xorl %edx, %edx
callq 0x3510
jmp 0xc565
jmp 0xc565
movq %rax, %r14
jmp 0xc5b1
jmp 0xc565
jmp 0xc565
movq %rax, %r14
jmp 0xc584
movq %rax, %r14
movq 0x38(%rsp), %rdi
cmpq %r12, %rdi
je 0xc584
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x3300
movq (%rsp), %rdi
testq %rdi, %rdi
je 0xc59a
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x3300
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0xc5b1
movq 0x28(%rsp), %rsi
subq %rdi, %rsi
callq 0x3300
movq %rbx, %rdi
callq 0xc73a
movq %r14, %rdi
callq 0x3540