// File: /workspace/github_c_makefile_star2_O2/craigbarnes[P]lua-gumbo/gumbo/parse.c
// Function: set_children
static void
set_children(lua_State *L, const GumboVector *vec, unsigned int start)
{
    const unsigned int length = vec->length;
    lua_createtable(L, length, 0);
    setmetatable(L, NodeList);
    for (unsigned int i = 0; i < length; i++) {
        push_node(L, (const GumboNode *)vec->data[i]);
        set_value(L, "parentNode", -3); // child.parentNode = parent
        lua_rawseti(L, -2, i + start); // parent.childNodes[i+start] = child
    }
    lua_setfield(L, -2, "childNodes");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %edx, %ebp
movq %rdi, %rbx
movq %rsi, 0x28(%rsp)
movl 0x8(%rsi), %esi
movq %rsi, 0x30(%rsp)
xorl %edx, %edx
callq 0x40a0
pushq $0x8
popq %rsi
movq %rbx, %rdi
callq 0x6741
movl %ebp, %r13d
leaq 0xfc33(%rip), %rbp      # 0x1609d
pushq $-0x3
popq %r15
xorl %r14d, %r14d
cmpq %r14, 0x30(%rsp)
je 0x6721
movq 0x28(%rsp), %rax
movq (%rax), %rax
movq (%rax,%r14,8), %r12
movq %rbx, %rdi
pushq $0xa
popq %rsi
movq %rbp, %rdx
callq 0x41b0
movl (%r12), %edx
leal -0x1(%rdx), %eax
cmpl $0x5, %eax
ja 0x66d4
leaq 0xfb53(%rip), %rcx      # 0x16000
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x18(%r12), %rbp
movq %rbx, %rdi
xorl %esi, %esi
pushq $0x7
popq %rdx
callq 0x40a0
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x675f
movq 0x60(%r12), %rax
movq %rax, 0x10(%rsp)
movups 0x50(%r12), %xmm0
movups %xmm0, (%rsp)
movq %rbx, %rdi
callq 0x68c5
cmpl $0x0, 0x14(%r12)
je 0x651e
movq %rbx, %rdi
leaq 0xfbbf(%rip), %rsi      # 0x160c0
callq 0x4260
movl 0x14(%r12), %esi
movq %rbx, %rdi
callq 0x4130
movq %rbx, %rdi
movl %r15d, %esi
callq 0x40c0
subq $-0x80, %r12
movq %rbx, %rdi
movq %r12, %rsi
callq 0x6965
movq %rbx, %rdi
movq %rbp, %rsi
pushq $0x1
popq %rdx
callq 0x642e
movq %rbx, %rdi
pushq $0x3
popq %rsi
callq 0x6741
leaq 0xfb50(%rip), %rbp      # 0x1609d
jmp 0x66e5
addq $0x18, %r12
movq %rbx, %rdi
movq %r12, %rsi
pushq $0x1
popq %rdx
callq 0x6adf
movq %rbx, %rdi
leaq 0x44890(%rip), %rsi     # 0x4adfe
callq 0x4260
movq %rbx, %rdi
leaq 0xfb69(%rip), %rsi      # 0x160e6
jmp 0x65aa
addq $0x18, %r12
movq %rbx, %rdi
movq %r12, %rsi
pushq $0x1
popq %rdx
callq 0x6adf
movq %rbx, %rdi
leaq 0x44863(%rip), %rsi     # 0x4adfe
callq 0x4260
movq %rbx, %rdi
leaq 0xfb47(%rip), %rsi      # 0x160f1
callq 0x4260
movq %rbx, %rdi
movl %r15d, %esi
callq 0x40c0
jmp 0x66e5
addq $0x18, %r12
movq %rbx, %rdi
movq %r12, %rsi
pushq $0x2
jmp 0x65d9
addq $0x18, %r12
movq %rbx, %rdi
movq %r12, %rsi
pushq $0x1
popq %rdx
callq 0x6adf
jmp 0x66e5
leaq 0x18(%r12), %rax
movq %rax, 0x20(%rsp)
movq %rbx, %rdi
xorl %esi, %esi
movq %r13, %rbp
pushq $0x8
popq %r13
movl %r13d, %edx
callq 0x40a0
movq %rbx, %rdi
leaq 0xfabf(%rip), %rsi      # 0x160cb
callq 0x4260
movq %rbx, %rdi
leaq 0xfaba(%rip), %rsi      # 0x160d5
callq 0x4260
movq %rbx, %rdi
movl %r15d, %esi
callq 0x40c0
movq 0x60(%r12), %rax
movq %rax, 0x10(%rsp)
movups 0x50(%r12), %xmm0
movups %xmm0, (%rsp)
movq %rbx, %rdi
callq 0x68c5
subq $-0x80, %r12
movq %rbx, %rdi
movq %r12, %rsi
callq 0x6965
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x40a0
movq %rbx, %rdi
movl %r13d, %esi
movq %rbp, %r13
leaq 0xfa2b(%rip), %rbp      # 0x1609d
callq 0x6741
movq %rbx, %rdi
pushq $-0x2
popq %rsi
leaq 0xf9f1(%rip), %rdx      # 0x16075
callq 0x4110
movq %rbx, %rdi
xorl %esi, %esi
pushq $0x1
popq %r12
movl %r12d, %edx
callq 0x40a0
movq %rbx, %rdi
movq 0x20(%rsp), %rsi
movl %r12d, %edx
callq 0x642e
movq %rbx, %rdi
pushq $0x7
popq %rsi
callq 0x6741
movq %rbx, %rdi
pushq $-0x2
popq %rsi
leaq 0xfa1c(%rip), %rdx      # 0x160de
callq 0x4110
movq %rbx, %rdi
pushq $0x3
popq %rsi
callq 0x6741
jmp 0x66e5
movq %rbx, %rdi
leaq 0xfa19(%rip), %rsi      # 0x160f7
xorl %eax, %eax
callq 0x4230
movq %rbx, %rdi
leaq 0xf9a3(%rip), %rsi      # 0x16092
callq 0x4260
movq %rbx, %rdi
pushq $-0x4
popq %rsi
callq 0x4150
movq %rbx, %rdi
movl %r15d, %esi
callq 0x40c0
leal (%r14,%r13), %edx
movq %rbx, %rdi
pushq $-0x2
popq %rsi
callq 0x4180
incq %r14
jmp 0x6471
leaq 0xf94d(%rip), %rdx      # 0x16075
pushq $-0x2
popq %rsi
movq %rbx, %rdi
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x4110