// File: /workspace/github_c_makefile_star2_O2/janet-lang[P]janet/src/core/marsh.c
// Function: marshal_one
static void marshal_one(MarshalState *st, Janet x, int flags) {
    MARSH_STACKCHECK;
    JanetType type = janet_type(x);

    /* Check simple primitives (non reference types, no benefit from memoization) */
    switch (type) {
        default:
            break;
        case JANET_NIL:
            pushbyte(st, LB_NIL);
            return;
        case JANET_BOOLEAN:
            pushbyte(st, janet_unwrap_boolean(x) ? LB_TRUE : LB_FALSE);
            return;
        case JANET_NUMBER: {
            double xval = janet_unwrap_number(x);
            if (janet_checkintrange(xval)) {
                pushint(st, (int32_t) xval);
                return;
            }
            break;
        }
    }

    /* Check reference and registry value */
    {
        Janet check;
        if (st->maybe_cycles) {
            check = janet_table_get(&st->seen, x);
            if (janet_checkint(check)) {
                pushbyte(st, LB_REFERENCE);
                pushint(st, janet_unwrap_integer(check));
                return;
            }
        }
        if (st->rreg) {
            check = janet_table_get(st->rreg, x);
            if (janet_checktype(check, JANET_SYMBOL)) {
                MARK_SEEN();
                const uint8_t *regname = janet_unwrap_symbol(check);
                pushbyte(st, LB_REGISTRY);
                pushint(st, janet_string_length(regname));
                pushbytes(st, regname, janet_string_length(regname));
                return;
            }
        }
    }

    /* Reference types */
    switch (type) {
        case JANET_NUMBER: {
            union {
                double d;
                uint8_t bytes[8];
            } u;
            u.d = janet_unwrap_number(x);
#ifdef JANET_BIG_ENDIAN
            /* Swap byte order */
            uint8_t temp;
            temp = u.bytes[7];
            u.bytes[7] = u.bytes[0];
            u.bytes[0] = temp;
            temp = u.bytes[6];
            u.bytes[6] = u.bytes[1];
            u.bytes[1] = temp;
            temp = u.bytes[5];
            u.bytes[5] = u.bytes[2];
            u.bytes[2] = temp;
            temp = u.bytes[4];
            u.bytes[4] = u.bytes[3];
            u.bytes[3] = temp;
#endif
            pushbyte(st, LB_REAL);
            pushbytes(st, u.bytes, 8);
            MARK_SEEN();
            return;
        }
        case JANET_STRING:
        case JANET_SYMBOL:
        case JANET_KEYWORD: {
            const uint8_t *str = janet_unwrap_string(x);
            int32_t length = janet_string_length(str);
            /* Record reference */
            MARK_SEEN();
            uint8_t lb = (type == JANET_STRING) ? LB_STRING :
                         (type == JANET_SYMBOL) ? LB_SYMBOL :
                         LB_KEYWORD;
            pushbyte(st, lb);
            pushint(st, length);
            pushbytes(st, str, length);
            return;
        }
        case JANET_BUFFER: {
            JanetBuffer *buffer = janet_unwrap_buffer(x);
            /* Record reference */
            MARK_SEEN();
#ifdef JANET_EV
            if ((flags & JANET_MARSHAL_UNSAFE) &&
                    (buffer->gc.flags & JANET_BUFFER_FLAG_NO_REALLOC)) {
                pushbyte(st, LB_POINTER_BUFFER);
                pushint(st, buffer->count);
                pushint(st, buffer->capacity);
                pushpointer(st, buffer->data);
                return;
            }
#endif
            pushbyte(st, LB_BUFFER);
            pushint(st, buffer->count);
            pushbytes(st, buffer->data, buffer->count);
            return;
        }
        case JANET_ARRAY: {
            int32_t i;
            JanetArray *a = janet_unwrap_array(x);
            MARK_SEEN();
            enum JanetMemoryType memtype = janet_gc_type(a);
            pushbyte(st, memtype == JANET_MEMORY_ARRAY_WEAK ? LB_ARRAY_WEAK : LB_ARRAY);
            pushint(st, a->count);
            for (i = 0; i < a->count; i++)
                marshal_one(st, a->data[i], flags + 1);
            return;
        }
        case JANET_TUPLE: {
            int32_t i, count, flag;
            const Janet *tup = janet_unwrap_tuple(x);
            count = janet_tuple_length(tup);
            flag = janet_tuple_flag(tup) >> 16;
            pushbyte(st, LB_TUPLE);
            pushint(st, count);
            pushint(st, flag);
            for (i = 0; i < count; i++)
                marshal_one(st, tup[i], flags + 1);
            /* Mark as seen AFTER marshaling */
            MARK_SEEN();
            return;
        }
        case JANET_TABLE: {
            JanetTable *t = janet_unwrap_table(x);
            MARK_SEEN();
            enum JanetMemoryType memtype = janet_gc_type(t);
            if (memtype == JANET_MEMORY_TABLE_WEAKK) {
                pushbyte(st, t->proto ? LB_TABLE_WEAKK_PROTO : LB_TABLE_WEAKK);
            } else if (memtype == JANET_MEMORY_TABLE_WEAKV) {
                pushbyte(st, t->proto ? LB_TABLE_WEAKV_PROTO : LB_TABLE_WEAKV);
            } else if (memtype == JANET_MEMORY_TABLE_WEAKKV) {
                pushbyte(st, t->proto ? LB_TABLE_WEAKKV_PROTO : LB_TABLE_WEAKKV);
            } else {
                pushbyte(st, t->proto ? LB_TABLE_PROTO : LB_TABLE);
            }
            pushint(st, t->count);
            if (t->proto)
                marshal_one(st, janet_wrap_table(t->proto), flags + 1);
            for (int32_t i = 0; i < t->capacity; i++) {
                if (janet_checktype(t->data[i].key, JANET_NIL))
                    continue;
                marshal_one(st, t->data[i].key, flags + 1);
                marshal_one(st, t->data[i].value, flags + 1);
            }
            return;
        }
        case JANET_STRUCT: {
            int32_t count;
            const JanetKV *struct_ = janet_unwrap_struct(x);
            count = janet_struct_length(struct_);
            pushbyte(st, janet_struct_proto(struct_) ? LB_STRUCT_PROTO : LB_STRUCT);
            pushint(st, count);
            if (janet_struct_proto(struct_))
                marshal_one(st, janet_wrap_struct(janet_struct_proto(struct_)), flags + 1);
            for (int32_t i = 0; i < janet_struct_capacity(struct_); i++) {
                if (janet_checktype(struct_[i].key, JANET_NIL))
                    continue;
                marshal_one(st, struct_[i].key, flags + 1);
                marshal_one(st, struct_[i].value, flags + 1);
            }
            /* Mark as seen AFTER marshaling */
            MARK_SEEN();
            return;
        }
        case JANET_ABSTRACT: {
            marshal_one_abstract(st, x, flags);
            return;
        }
        case JANET_FUNCTION: {
            pushbyte(st, LB_FUNCTION);
            JanetFunction *func = janet_unwrap_function(x);
            pushint(st, func->def->environments_length);
            /* Mark seen before reading def */
            MARK_SEEN();
            marshal_one_def(st, func->def, flags);
            for (int32_t i = 0; i < func->def->environments_length; i++)
                marshal_one_env(st, func->envs[i], flags + 1);
            return;
        }
        case JANET_FIBER: {
            MARK_SEEN();
            pushbyte(st, LB_FIBER);
            marshal_one_fiber(st, janet_unwrap_fiber(x), flags + 1);
            return;
        }
        case JANET_CFUNCTION: {
            if (!(flags & JANET_MARSHAL_UNSAFE)) goto no_registry;
            MARK_SEEN();
            pushbyte(st, LB_UNSAFE_CFUNCTION);
            JanetCFunction cfn = janet_unwrap_cfunction(x);
            pushbytes(st, (uint8_t *) &cfn, sizeof(JanetCFunction));
            return;
        }
        case JANET_POINTER: {
            if (!(flags & JANET_MARSHAL_UNSAFE)) goto no_registry;
            MARK_SEEN();
            pushbyte(st, LB_UNSAFE_POINTER);
            pushpointer(st, janet_unwrap_pointer(x));
            return;
        }
    no_registry:
        default: {
            janet_panicf("no registry value and cannot marshal %p", x);
        }
    }
#undef MARK_SEEN
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movl %edx, %r14d
movq %rsi, %r13
movq %rdi, %rbx
leaq 0x8(%rdi), %rax
movq %rax, -0x30(%rbp)
movq %rdi, -0x38(%rbp)
movzwl %r14w, %eax
cmpl $0x401, %eax            # imm = 0x401
jae 0x2d908
movq %r13, %xmm0
movq %r13, %r12
shrq $0x2f, %r12
andl $0xf, %r12d
ucomisd %xmm0, %xmm0
movl $0x0, %eax
cmovnpl %eax, %r12d
testl %r12d, %r12d
je 0x2ce47
cmpl $0x2, %r12d
je 0x2d6dc
cmpl $0x1, %r12d
jne 0x2ce73
jmp 0x2d6d2
ucomisd 0x21629(%rip), %xmm0    # 0x4e478
jb 0x2ce73
movsd 0x21627(%rip), %xmm1    # 0x4e480
ucomisd %xmm0, %xmm1
jb 0x2ce73
cvttpd2dq %xmm0, %xmm1
cvtdq2pd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x2ce73
jnp 0x2d5de
cmpl $0x0, 0x54(%rbx)
je 0x2ce98
movq -0x30(%rbp), %rdi
movq %r13, %rsi
callq 0x43c35
movq %rax, %r15
movq %rax, %rdi
callq 0x45e2b
testl %eax, %eax
jne 0x2d5cc
movq 0x38(%rbx), %rdi
testq %rdi, %rdi
je 0x2cecc
movq %r13, %rsi
callq 0x43c35
movq %rax, %r15
movabsq $-0x800000000000, %rcx  # imm = 0xFFFF800000000000
andq %rcx, %rax
movabsq $-0x5800000000000, %rcx # imm = 0xFFFA800000000000
cmpq %rcx, %rax
je 0x2d5f8
cmpl $0xf, %r12d
ja 0x2d914
movl %r12d, %eax
leaq 0x2e830(%rip), %rcx     # 0x5b710
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
cmpl $0x0, 0x54(%rbx)
je 0x2cf10
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x43e19
movq %rbx, %rdi
movl $0xcc, %esi
callq 0x2cd91
movq %r13, %rdi
callq 0x4b1f1
movq %rax, %r12
leal 0x1(%r14), %eax
movzwl %ax, %eax
cmpl $0x401, %eax            # imm = 0x401
jae 0x2d908
movl 0x10(%r12), %r13d
movq 0x38(%r12), %r15
movq 0x28(%r12), %rbx
movq %r12, %rdi
callq 0x27553
cmpl $0xf, %eax
je 0x2d920
movl %r13d, %eax
orl $0x20000000, %eax       # imm = 0x20000000
testq %r15, %r15
cmovel %r13d, %eax
movl %eax, %esi
orl $0x40000000, %esi       # imm = 0x40000000
testq %rbx, %rbx
cmovel %eax, %esi
movq -0x38(%rbp), %rbx
movq %rbx, %rdi
callq 0x2ccd8
movq %r12, %r15
addq $0x14, %r15
movl 0x14(%r12), %esi
movq %rbx, %rdi
callq 0x2ccd8
movl 0x18(%r12), %esi
movq %rbx, %rdi
callq 0x2ccd8
movl 0x1c(%r12), %esi
movq %rbx, %rdi
callq 0x2ccd8
movl 0x24(%r12), %esi
movq %rbx, %rdi
callq 0x2ccd8
movl 0x18(%r12), %r13d
addl $0x2, %r14d
movslq (%r15), %rcx
testq %rcx, %rcx
jle 0x2d09d
movq 0x30(%r12), %rax
movq %rcx, -0x40(%rbp)
leaq (%rax,%rcx,8), %r15
cmpq $0x0, -0x10(%r15)
je 0x2cfec
orb $-0x80, -0x1(%r15)
cmpq $0x0, -0x20(%r15)
je 0x2d8e4
movl -0x4(%r15), %esi
movq %rbx, %rdi
callq 0x2ccd8
movl -0x8(%r15), %esi
movq %rbx, %rdi
callq 0x2ccd8
movq -0x20(%r15), %rax
movq -0x18(%r15), %rsi
movq 0x10(%rax), %rax
subq 0x28(%rax), %rsi
shrq $0x2, %rsi
movq %rbx, %rdi
callq 0x2ccd8
movq -0x20(%r15), %rdi
movabsq $-0x2000000000000, %rsi # imm = 0xFFFE000000000000
callq 0x4b3ab
movq %rbx, %rdi
movq %rax, %rsi
movq %r14, %rbx
movl %ebx, %edx
callq 0x2cddb
movq -0x10(%r15), %rsi
testq %rsi, %rsi
je 0x2d062
movq -0x38(%rbp), %rdi
movl %ebx, %edx
callq 0x2f3e1
addl $-0x4, %r13d
addq $-0x8, %r15
movq -0x40(%rbp), %rbx
cmpl %ebx, %r13d
jle 0x2d08d
movq 0x30(%r12), %rax
movq (%rax,%rbx,8), %rsi
movq -0x38(%rbp), %rdi
movl %r14d, %edx
callq 0x2cddb
incq %rbx
jmp 0x2d06e
movq -0x40(%rbp), %rax
movl %eax, %r13d
movq -0x38(%rbp), %rbx
jmp 0x2cfc7
movq 0x28(%r12), %rdi
testq %rdi, %rdi
je 0x2d0c4
movabsq $-0x3800000000000, %rsi # imm = 0xFFFC800000000000
callq 0x4b3ab
movq %rbx, %rdi
movq %rax, %rsi
movl %r14d, %edx
callq 0x2cddb
movq 0x38(%r12), %rdi
testq %rdi, %rdi
je 0x2d0eb
movabsq $-0x6800000000000, %rsi # imm = 0xFFF9800000000000
callq 0x4b3ab
movq %rbx, %rdi
movq %rax, %rsi
movl %r14d, %edx
callq 0x2cddb
movq 0x40(%r12), %r13
jmp 0x2ce01
movq %r13, %rdi
callq 0x4b1f1
movq %rax, %r14
movq %r13, %r15
movl -0x8(%rax), %r13d
cmpl $0x0, 0x54(%rbx)
je 0x2d12e
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x43e19
cmpl $0x5, %r12d
sete %al
movb $-0x30, %cl
subb %al, %cl
cmpl $0x4, %r12d
movzbl %cl, %eax
movl $0xce, %ecx
cmovnel %eax, %ecx
movzbl %cl, %esi
movq %rbx, %rdi
callq 0x2cd91
movq %rbx, %rdi
movl %r13d, %esi
callq 0x2ccd8
movq %rbx, %rdi
movq %r14, %rsi
movl %r13d, %edx
jmp 0x2d64d
movq %r13, %rdi
callq 0x4b1f1
movq %r13, %r15
movq %rax, %r13
cmpl $0x0, 0x54(%rbx)
je 0x2d1a1
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x43e19
movzbl (%r13), %ecx
movq 0x28(%r13), %rax
cmpl $0x10, %ecx
je 0x2d7c6
cmpl $0xf, %ecx
je 0x2d7b4
cmpl $0xe, %ecx
jne 0x2d7d8
xorl %ecx, %ecx
testq %rax, %rax
setne %cl
leal (%rcx,%rcx,2), %eax
addl $0xe2, %eax
jmp 0x2d7e0
btl $0x11, %r14d
jae 0x2d914
cmpl $0x0, 0x54(%rbx)
je 0x2d20c
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x43e19
movq %rbx, %rdi
movl $0xdd, %esi
callq 0x2cd91
movq %r13, %rdi
callq 0x4b1f1
leaq -0x78(%rbp), %rsi
movq %rax, (%rsi)
pushq $0x8
popq %rdx
movq %rbx, %rdi
callq 0x2cdbc
jmp 0x2d896
movq %r13, %rdi
callq 0x4b1f1
movq %r13, %r15
movq %rax, %r13
cmpl $0x0, 0x54(%rbx)
je 0x2d26d
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x43e19
cmpb $0x11, (%r13)
movl $0xe8, %eax
movl $0xd1, %esi
cmovel %eax, %esi
movq %rbx, %rdi
callq 0x2cd91
movl 0x10(%r13), %esi
movq %rbx, %rdi
callq 0x2ccd8
incl %r14d
xorl %ebx, %ebx
movslq 0x10(%r13), %rax
cmpq %rax, %rbx
jge 0x2d896
movq 0x18(%r13), %rax
movq (%rax,%rbx,8), %rsi
movq -0x38(%rbp), %rdi
movl %r14d, %edx
callq 0x2cddb
incq %rbx
jmp 0x2d298
btl $0x11, %r14d
jae 0x2d914
cmpl $0x0, 0x54(%rbx)
je 0x2d2f0
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x43e19
movq %rbx, %rdi
movl $0xde, %esi
callq 0x2cd91
movq %r13, %rdi
callq 0x4b1f1
movq %rbx, %rdi
movq %rax, %rsi
jmp 0x2d8d1
leaq -0x78(%rbp), %r14
movq %r13, (%r14)
movq %rbx, %rdi
movl $0xc8, %esi
callq 0x2cd91
pushq $0x8
popq %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2cdbc
cmpl $0x0, 0x54(%rbx)
je 0x2d896
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x43e19
jmp 0x2d896
movq %r13, %r12
movq %r13, %rdi
callq 0x4b1f1
movq %rax, %r13
movq %rax, -0x50(%rbp)
btl $0x11, %r14d
jae 0x2d660
cmpb $0xd, -0x20(%r13)
jne 0x2d660
movq %r13, %rdi
callq 0x12f4c
movq %rbx, %rdi
movl $0xe0, %esi
callq 0x2cd91
leaq -0x50(%rbp), %rsi
pushq $0x8
popq %rdx
movq %rbx, %rdi
callq 0x2cdbc
cmpl $0x0, 0x54(%rbx)
je 0x2d896
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r12, %rsi
jmp 0x2d355
movq %rbx, %rdi
movl $0xd7, %esi
callq 0x2cd91
movq %r13, %rdi
callq 0x4b1f1
movq %r13, %r15
movq %rax, %r13
movq 0x10(%rax), %rax
movl 0x74(%rax), %esi
movq %rbx, %rdi
callq 0x2ccd8
cmpl $0x0, 0x54(%rbx)
je 0x2d424
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x43e19
movq 0x10(%r13), %rsi
movq %rbx, %rdi
movl %r14d, %edx
callq 0x2f0e2
incl %r14d
xorl %ebx, %ebx
movq 0x10(%r13), %rax
movslq 0x74(%rax), %rax
cmpq %rax, %rbx
jge 0x2d896
movq 0x18(%r13,%rbx,8), %rsi
movq -0x38(%rbp), %rdi
movl %r14d, %edx
callq 0x2f3e1
incq %rbx
jmp 0x2d438
movq %r13, %rdi
callq 0x4b1f1
movq %r13, %r15
movq %rax, %r13
cmpl $0x0, 0x54(%rbx)
je 0x2d494
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x43e19
btl $0x11, %r14d
jae 0x2d4a6
testb $0x1, 0x2(%r13)
jne 0x2d8a5
movq %rbx, %rdi
movl $0xd6, %esi
callq 0x2cd91
movl 0x10(%r13), %esi
movq %rbx, %rdi
callq 0x2ccd8
movq 0x18(%r13), %rsi
movl 0x10(%r13), %edx
movq %rbx, %rdi
jmp 0x2d64d
movq %r13, %r12
movq %r13, %rdi
callq 0x4b1f1
movq %rax, %r13
movl -0x10(%rax), %r15d
movswl -0x1e(%rax), %eax
movl %eax, -0x40(%rbp)
movq %rbx, %rdi
movl $0xd2, %esi
callq 0x2cd91
movq %rbx, %rdi
movl %r15d, %esi
callq 0x2ccd8
movq %rbx, %rdi
movl -0x40(%rbp), %esi
callq 0x2ccd8
incl %r14d
xorl %ebx, %ebx
testl %r15d, %r15d
cmovlel %ebx, %r15d
cmpq %rbx, %r15
je 0x2d532
movq (%r13,%rbx,8), %rsi
movq -0x38(%rbp), %rdi
movl %r14d, %edx
callq 0x2cddb
incq %rbx
jmp 0x2d517
movq -0x38(%rbp), %rax
cmpl $0x0, 0x54(%rax)
je 0x2d896
movq -0x38(%rbp), %rdx
movl 0x50(%rdx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rdx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r12, %rsi
jmp 0x2d79e
movq %r13, -0x48(%rbp)
movq %r13, %rdi
callq 0x4b1f1
movq %rax, %r13
movl -0x18(%rax), %r15d
cmpq $0x0, -0x8(%rax)
movl $0xd5, %eax
movl $0xdf, %esi
cmovel %eax, %esi
movq %rbx, %rdi
callq 0x2cd91
movq %rbx, %rdi
movl %r15d, %esi
callq 0x2ccd8
movq -0x8(%r13), %rdi
testq %rdi, %rdi
je 0x2d700
movabsq $-0x3000000000000, %rsi # imm = 0xFFFD000000000000
callq 0x4b366
incl %r14d
movq %rbx, %rdi
movq %rax, %rsi
movl %r14d, %edx
callq 0x2cddb
jmp 0x2d703
movq %rbx, %rdi
movl $0xda, %esi
callq 0x2cd91
movq %r15, %xmm0
cvttsd2si %xmm0, %esi
movq %rbx, %rdi
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2ccd8
cmpl $0x0, 0x54(%rbx)
je 0x2d61f
movl 0x50(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rbx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x43e19
movq %r15, %rdi
callq 0x4b1f1
movq %rax, %r14
movq %rbx, %rdi
movl $0xd8, %esi
callq 0x2cd91
movl -0x8(%r14), %esi
movq %rbx, %rdi
callq 0x2ccd8
movl -0x8(%r14), %edx
movq %rbx, %rdi
movq %r14, %rsi
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2cdbc
movq -0x10(%r13), %rbx
cmpq $0x0, 0x28(%rbx)
je 0x2d92c
movq %r14, %r15
movq -0x38(%rbp), %r14
movq %r14, %rdi
movl $0xd9, %esi
callq 0x2cd91
movq (%rbx), %rdi
callq 0x439c6
movq %rax, %rdi
movabsq $-0x5800000000000, %rsi # imm = 0xFFFA800000000000
callq 0x4b366
incl %r15d
movq %r14, %rdi
movq %rax, %rsi
movl %r15d, %edx
callq 0x2cddb
leaq -0x78(%rbp), %rsi
movq %r14, (%rsi)
andq $0x0, 0x8(%rsi)
movl %r15d, 0x10(%rsi)
andq $0x0, 0x18(%rsi)
movq %rbx, 0x20(%rsi)
movq %r13, %rdi
callq *0x28(%rbx)
jmp 0x2d896
movq %rbx, %rdi
movl $0xc9, %esi
jmp 0x2d6ed
andl $0x1, %r13d
orl $0xca, %r13d
movq %rbx, %rdi
movl %r13d, %esi
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2cd91
incl %r14d
movabsq $-0x7800000000000, %rdx # imm = 0xFFF8800000000000
movq %r13, %r15
addq $0x8, %r15
xorl %r12d, %r12d
movq %r13, -0x40(%rbp)
movslq -0x10(%r13), %rax
cmpq %rax, %r12
jge 0x2d772
movq -0x8(%r15), %rsi
movq %rsi, %rax
movabsq $-0x800000000000, %rcx  # imm = 0xFFFF800000000000
andq %rcx, %rax
cmpq %rdx, %rax
je 0x2d769
movq %r14, %rbx
movq -0x38(%rbp), %r14
movq %r14, %rdi
movq %rdx, %r13
movl %ebx, %edx
callq 0x2cddb
movq (%r15), %rsi
movq %r14, %rdi
movq %rbx, %r14
movl %r14d, %edx
callq 0x2cddb
movq %r13, %rdx
movq -0x40(%rbp), %r13
incq %r12
addq $0x10, %r15
jmp 0x2d71b
movq -0x38(%rbp), %rax
cmpl $0x0, 0x54(%rax)
je 0x2d896
movq -0x38(%rbp), %rdx
movl 0x50(%rdx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x50(%rdx)
cvtsi2sd %eax, %xmm0
callq 0x4b471
movq -0x30(%rbp), %rdi
movq -0x48(%rbp), %rsi
movq %rax, %rdx
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x43e19
xorl %ecx, %ecx
testq %rax, %rax
setne %cl
leal (%rcx,%rcx,2), %eax
addl $0xe3, %eax
jmp 0x2d7e0
xorl %ecx, %ecx
testq %rax, %rax
setne %cl
leal (%rcx,%rcx,2), %eax
orl $0xe4, %eax
jmp 0x2d7e0
cmpq $0x1, %rax
movb $-0x2c, %al
sbbb $0x0, %al
movzbl %al, %esi
movq %rbx, %rdi
callq 0x2cd91
movl 0x10(%r13), %esi
movq %rbx, %rdi
callq 0x2ccd8
movq 0x28(%r13), %rdi
testq %rdi, %rdi
je 0x2d822
movabsq $-0x3800000000000, %rsi # imm = 0xFFFC800000000000
callq 0x4b3ab
incl %r14d
movq %rbx, %rdi
movq %rax, %rsi
movl %r14d, %edx
callq 0x2cddb
jmp 0x2d825
incl %r14d
movabsq $-0x7800000000000, %rdx # imm = 0xFFF8800000000000
xorl %r15d, %r15d
xorl %r12d, %r12d
movslq 0x14(%r13), %rax
cmpq %rax, %r12
jge 0x2d896
movq 0x20(%r13), %rax
movq (%rax,%r15), %rsi
movq %rsi, %rax
movabsq $-0x800000000000, %rcx  # imm = 0xFFFF800000000000
andq %rcx, %rax
cmpq %rdx, %rax
je 0x2d88d
movq %r14, %rbx
movq -0x38(%rbp), %r14
movq %r14, %rdi
movl %ebx, %edx
callq 0x2cddb
movq 0x20(%r13), %rax
movq 0x8(%rax,%r15), %rsi
movq %r14, %rdi
movq %rbx, %r14
movl %r14d, %edx
callq 0x2cddb
movabsq $-0x7800000000000, %rdx # imm = 0xFFF8800000000000
incq %r12
addq $0x10, %r15
jmp 0x2d835
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rbx, %rdi
movl $0xe1, %esi
callq 0x2cd91
movl 0x10(%r13), %esi
movq %rbx, %rdi
callq 0x2ccd8
movl 0x14(%r13), %esi
movq %rbx, %rdi
callq 0x2ccd8
movq 0x18(%r13), %rsi
movq %rbx, %rdi
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2cd64
movq -0x18(%r15), %rdi
movabsq $-0x1800000000000, %rsi # imm = 0xFFFE800000000000
callq 0x4b3ab
leaq 0x2e38b(%rip), %rdi     # 0x5bc89
movq %rax, %rsi
xorl %eax, %eax
callq 0x176c9
leaq 0x2b5e4(%rip), %rdi     # 0x58ef3
callq 0x177b1
leaq 0x2e32b(%rip), %rdi     # 0x5bc46
movq %r13, %rsi
jmp 0x2d901
leaq 0x2e347(%rip), %rdi     # 0x5bc6e
callq 0x177b1
leaq 0x2e329(%rip), %rdi     # 0x5bc5c
movq %r12, %rsi
jmp 0x2d901