// File: /workspace/github_cpp_makefile_star2_O2/swxlion[P]swxJson/src/swxJson.cpp
// Function: swxJson::Json::createNode(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, bool)
JsonPtr Json::createNode(const std::string& path, const std::string& delim, bool throwable)
{
	std::vector<std::string> sections;
	pathSplit(path, delim, sections);

	if (sections.empty())
		sections.push_back("");

	JsonPtr node;
	size_t i = 0;
	for (; i < sections.size(); i++)
	{
		JsonPtr next = (i>0) ? node->getNodeByKey(sections[i]) : getNodeByKey(sections[0]);
		if (next == nullptr)
		{
			enum ElementType nodeType = (i>0) ? node->type() : type();
			if (nodeType == JSON_Object)
				break;				//-- not found
			else if (nodeType == JSON_Uninit)
			{
				if (i < sections.size() - 1)
				{
					if (i > 0)
						node->setDict();
					else
						setDict();
				}
				break;
			}
			else
			{
				if (throwable)
					throw JSON_ERROR_FMT(JsonNodeTypeMissMatchError, "Section %d (%s)(base 0) in path is not object.", (int)i, sections[i].c_str());

				return nullptr;
			}
		}
		else
			node = next;
	}

	for (; i < sections.size() - 1; i++)
	{
		node = (i > 0) ? node->dictAddObject(sections[i]) : dictAddObject(sections[0]);
	}

	if (i == sections.size() - 1)
	{
		JsonPtr n(new Json());
		if (i > 0)
			node->addNode(sections[i], n);
		else
			addNode(sections[0], n);

		return n;
	}

	return node;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movl %r8d, %ebp
movq %rdx, %rax
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rdx
movaps %xmm0, (%rdx)
andq $0x0, 0x10(%rdx)
movq %rax, %rdi
movq %rcx, %rsi
callq 0x16905
movq 0x10(%rsp), %rax
cmpq 0x18(%rsp), %rax
jne 0x16e0d
leaq 0x868d(%rip), %rsi      # 0x1f474
leaq 0x48(%rsp), %rdi
movq %rsp, %rdx
callq 0x14fc0
leaq 0x10(%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0x1afe0
leaq 0x48(%rsp), %rdi
callq 0xe0c0
movl %ebp, 0x3c(%rsp)
movq %rbx, 0x30(%rsp)
leaq 0x90(%rsp), %rax
movq %rax, 0x40(%rsp)
xorps %xmm0, %xmm0
movq %rsp, %r15
movaps %xmm0, (%r15)
leaq 0x70(%rsp), %rbp
xorl %r12d, %r12d
leaq 0x68(%rsp), %rbx
xorl %r13d, %r13d
movq 0x10(%rsp), %rdx
movq 0x18(%rsp), %rax
subq %rdx, %rax
sarq $0x5, %rax
cmpq %rax, %r13
jae 0x16eeb
testq %r13, %r13
je 0x16e75
movq (%rsp), %rsi
addq %r12, %rdx
movq %rbx, %rdi
callq 0x16a20
cmpq $0x0, 0x68(%rsp)
jne 0x16e88
jmp 0x16ea4
movq %rbx, %rdi
movq %r14, %rsi
callq 0x16a20
cmpq $0x0, 0x68(%rsp)
je 0x16eaa
movq %r15, %rdi
movq %rbx, %rsi
callq 0x1ae3a
movq %rbp, %rdi
callq 0x161f0
incq %r13
addq $0x20, %r12
jmp 0x16e3d
movq (%rsp), %rax
jmp 0x16ead
movq %r14, %rax
movl (%rax), %eax
testl %eax, %eax
je 0x16ee3
cmpl $0x8, %eax
jne 0x16fbc
movq 0x18(%rsp), %rax
subq 0x10(%rsp), %rax
sarq $0x5, %rax
decq %rax
cmpq %rax, %r13
jae 0x16ee3
movq %r14, %rdi
testq %r13, %r13
je 0x16ede
movq (%rsp), %rdi
callq 0x17126
movq %rbp, %rdi
callq 0x161f0
leaq 0x50(%rsp), %rbx
leaq 0x48(%rsp), %r15
movq %rsp, %rbp
movq 0x10(%rsp), %rdx
movq 0x18(%rsp), %rax
subq %rdx, %rax
sarq $0x5, %rax
decq %rax
cmpq %rax, %r13
jae 0x16f44
movq %r14, %rsi
testq %r13, %r13
je 0x16f1d
movq (%rsp), %rsi
addq %r12, %rdx
movq %r15, %rdi
callq 0x1716e
movq %rbp, %rdi
movq %r15, %rsi
callq 0x16632
movq %rbx, %rdi
callq 0x161f0
incq %r13
addq $0x20, %r12
jmp 0x16ef8
jne 0x16fa2
pushq $0x10
popq %rdi
callq 0xe240
movq 0x30(%rsp), %rbp
movl $0x8, (%rax)
andq $0x0, 0x8(%rax)
movq %rbp, %rdi
movq %rax, %rsi
callq 0x15db2
testq %r13, %r13
je 0x16fd6
movq (%rsp), %rbx
addq 0x10(%rsp), %r12
leaq 0x88(%rsp), %r14
movq %r14, %rdi
movq %rbp, %rsi
callq 0x161bc
movq %rbx, %rdi
movq %r12, %rsi
movq %r14, %rdx
callq 0x1722e
leaq 0x90(%rsp), %rdi
jmp 0x17001
movaps (%rsp), %xmm0
andq $0x0, 0x8(%rsp)
movq 0x30(%rsp), %rbp
movups %xmm0, (%rbp)
andq $0x0, (%rsp)
jmp 0x17006
cmpb $0x0, 0x3c(%rsp)
jne 0x1702f
xorps %xmm0, %xmm0
movq 0x30(%rsp), %rax
movups %xmm0, (%rax)
movq %rbp, %rdi
movq %rax, %rbp
jmp 0x17001
movq 0x10(%rsp), %rbx
leaq 0x78(%rsp), %r15
movq %r15, %rdi
movq %rbp, %rsi
callq 0x161bc
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x1722e
leaq 0x80(%rsp), %rdi
callq 0x161f0
leaq 0x8(%rsp), %rdi
callq 0x161f0
leaq 0x10(%rsp), %rdi
callq 0x15930
movq %rbp, %rax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
pushq $0x60
popq %rdi
callq 0xe0e0
movq %rax, %rbx
movq 0x10(%rsp), %rax
movq (%rax,%r12), %rcx
leaq 0x8663(%rip), %rsi      # 0x1f6ad
leaq 0x48(%rsp), %rdi
movl %r13d, %edx
xorl %eax, %eax
callq 0x1d16e
movb $0x1, %r15b
leaq 0x8633(%rip), %rsi      # 0x1f696
leaq 0x8638(%rip), %rdx      # 0x1f6a2
leaq 0x48(%rsp), %r8
movq %rbx, %rdi
movl $0x18e, %ecx            # imm = 0x18E
callq 0x1a812
xorl %r15d, %r15d
leaq 0x10c42(%rip), %rsi     # 0x27cc8
leaq 0x390b(%rip), %rdx      # 0x1a998
movq %rbx, %rdi
callq 0xe380
movq %rax, %r14
leaq 0x48(%rsp), %rdi
callq 0xe0c0
testb %r15b, %r15b
jne 0x170ac
jmp 0x170b9
movq %rax, %r14
movq %rbx, %rdi
callq 0xe190
jmp 0x170b9
movq %rax, %r14
movq %rbp, %rdi
jmp 0x170e6
movq %rax, %r14
leaq 0x80(%rsp), %rax
movq %rax, 0x40(%rsp)
jmp 0x170d3
movq %rax, %r14
movq 0x40(%rsp), %rdi
callq 0x161f0
movq 0x30(%rsp), %rdi
addq $0x8, %rdi
callq 0x161f0
jmp 0x1710a
movq %rax, %r14
leaq 0x48(%rsp), %rdi
callq 0xe0c0
jmp 0x17114
jmp 0x17100
jmp 0x17107
movq %rax, %r14
jmp 0x17114
jmp 0x17107
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x161f0
leaq 0x10(%rsp), %rdi
callq 0x15930
movq %r14, %rdi
callq 0xe3a0