// File: /workspace/github_c_makefile_star2_O2/janet-lang[P]janet/src/core/vm.c
// Function: janet_continue_no_check
static JanetSignal janet_continue_no_check(JanetFiber *fiber, Janet in, Janet *out) {

    JanetFiberStatus old_status = janet_fiber_status(fiber);

#ifdef JANET_EV
    janet_fiber_did_resume(fiber);
#endif

    /* Clear last value */
    fiber->last_value = janet_wrap_nil();

    /* Continue child fiber if it exists */
    if (fiber->child) {
        if (janet_vm.root_fiber == NULL) janet_vm.root_fiber = fiber;
        JanetFiber *child = fiber->child;
        uint32_t instr = (janet_stack_frame(fiber->data + fiber->frame)->pc)[0];
        janet_vm.stackn++;
        JanetSignal sig = janet_continue(child, in, &in);
        janet_vm.stackn--;
        if (janet_vm.root_fiber == fiber) janet_vm.root_fiber = NULL;
        if (sig != JANET_SIGNAL_OK && !(child->flags & (1 << sig))) {
            *out = in;
            janet_fiber_set_status(fiber, sig);
            fiber->last_value = child->last_value;
            return sig;
        }
        /* Check if we need any special handling for certain opcodes */
        switch (instr & 0x7F) {
            default:
                break;
            case JOP_NEXT: {
                if (sig == JANET_SIGNAL_OK ||
                        sig == JANET_SIGNAL_ERROR ||
                        sig == JANET_SIGNAL_USER0 ||
                        sig == JANET_SIGNAL_USER1 ||
                        sig == JANET_SIGNAL_USER2 ||
                        sig == JANET_SIGNAL_USER3 ||
                        sig == JANET_SIGNAL_USER4) {
                    in = janet_wrap_nil();
                } else {
                    in = janet_wrap_integer(0);
                }
                break;
            }
        }
        fiber->child = NULL;
    }

    /* Handle new fibers being resumed with a non-nil value */
    if (old_status == JANET_STATUS_NEW && !janet_checktype(in, JANET_NIL)) {
        Janet *stack = fiber->data + fiber->frame;
        JanetFunction *func = janet_stack_frame(stack)->func;
        if (func) {
            if (func->def->arity > 0) {
                stack[0] = in;
            } else if (func->def->flags & JANET_FUNCDEF_FLAG_VARARG) {
                stack[0] = janet_wrap_tuple(janet_tuple_n(&in, 1));
            }
        }
    }

    /* Save global state */
    JanetTryState tstate;
    JanetSignal sig = janet_try(&tstate);
    if (!sig) {
        /* Normal setup */
        if (janet_vm.root_fiber == NULL) janet_vm.root_fiber = fiber;
        janet_vm.fiber = fiber;
        janet_fiber_set_status(fiber, JANET_STATUS_ALIVE);
        sig = run_vm(fiber, in);
    }

    /* Restore */
    if (janet_vm.root_fiber == fiber) janet_vm.root_fiber = NULL;
    janet_fiber_set_status(fiber, sig);
    janet_restore(&tstate);
    fiber->last_value = tstate.payload;
    *out = tstate.payload;

    return sig;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x118, %rsp            # imm = 0x118
movq %rdx, -0x40(%rbp)
movq %rsi, %r14
movq %rdi, %rbx
movabsq $-0x77fffffffffff, %r15 # imm = 0xFFF8800000000001
movq %rsi, -0x30(%rbp)
callq 0x27553
movl %eax, %r12d
movq %rbx, %rdi
callq 0x205af
movq %r15, %rdi
callq 0x4b313
movq %rax, 0x40(%rbx)
movq 0x38(%rbx), %r13
testq %r13, %r13
je 0x4aa12
movl %r12d, -0x34(%rbp)
movq %fs:0x0, %rax
leaq -0x348(%rax), %rax
movq %rax, %r12
cmpq $0x0, 0x28(%rax)
jne 0x4a989
movq %rbx, 0x28(%r12)
movq 0x30(%rbx), %rax
movslq 0x14(%rbx), %rcx
movq -0x18(%rax,%rcx,8), %rax
movl (%rax), %r15d
incl 0x18(%r12)
leaq -0x30(%rbp), %rdx
movq %r13, %rdi
movq %r14, %rsi
callq 0x47bb8
decl 0x18(%r12)
cmpq %rbx, 0x28(%r12)
jne 0x4a9bf
andq $0x0, 0x28(%r12)
movl %eax, %ecx
testl %eax, %eax
je 0x4a9d2
movl 0x10(%r13), %edx
btl %eax, %edx
jae 0x4ab56
andl $0x7f, %r15d
cmpl $0x49, %r15d
movabsq $-0x77fffffffffff, %r15 # imm = 0xFFF8800000000001
movl -0x34(%rbp), %r12d
jne 0x4aa0d
cmpl $0x8, %eax
ja 0x4ab7d
movl $0x1f3, %eax            # imm = 0x1F3
btl %ecx, %eax
jae 0x4ab7d
movq %r15, %rdi
callq 0x4b313
movq %rax, -0x30(%rbp)
andq $0x0, 0x38(%rbx)
cmpl $0xe, %r12d
jne 0x4aa75
movq -0x30(%rbp), %rax
movabsq $-0x800000000000, %rcx  # imm = 0xFFFF800000000000
andq %rax, %rcx
decq %r15
cmpq %r15, %rcx
je 0x4aa75
movq 0x30(%rbx), %r14
movslq 0x14(%rbx), %r15
movq -0x20(%r14,%r15,8), %rcx
testq %rcx, %rcx
je 0x4aa75
movq 0x10(%rcx), %rcx
cmpl $0x0, 0x60(%rcx)
jg 0x4aa71
testb $0x1, 0x5a(%rcx)
je 0x4aa75
leaq -0x30(%rbp), %rdi
pushq $0x1
popq %rsi
callq 0x44692
movabsq $-0x4000000000000, %rsi # imm = 0xFFFC000000000000
movq %rax, %rdi
callq 0x4b366
movq %rax, (%r14,%r15,8)
leaq -0x138(%rbp), %rdi
callq 0x4a78b
leaq -0x118(%rbp), %rdi
callq 0x12580
movl %eax, %r14d
movl %eax, %r12d
movq %fs:0x0, %rax
leaq -0x348(%rax), %rax
movq %rax, %r15
movl %r12d, %eax
testl %r14d, %r14d
jne 0x4aad9
cmpq $0x0, 0x28(%r15)
jne 0x4aab9
movq %rbx, 0x28(%r15)
movq %rbx, 0x20(%r15)
movl $0xffc0ffff, %eax       # imm = 0xFFC0FFFF
andl 0x10(%rbx), %eax
orl $0xf0000, %eax          # imm = 0xF0000
movl %eax, 0x10(%rbx)
movq -0x30(%rbp), %rsi
movq %rbx, %rdi
callq 0x47f05
cmpq %rbx, 0x28(%r15)
jne 0x4aae4
andq $0x0, 0x28(%r15)
movl $0xffc0ffff, %ecx       # imm = 0xFFC0FFFF
andl 0x10(%rbx), %ecx
movl %eax, %edx
shll $0x10, %edx
orl %ecx, %edx
movl %edx, 0x10(%rbx)
movl -0x138(%rbp), %ecx
movl %ecx, 0x18(%r15)
movl -0x134(%rbp), %ecx
movl %ecx, 0xb8(%r15)
movq -0x130(%rbp), %rcx
movq %rcx, 0x20(%r15)
movq -0x128(%rbp), %rcx
movq %rcx, 0x30(%r15)
movq -0x120(%rbp), %rcx
movq %rcx, 0x38(%r15)
movl -0x48(%rbp), %ecx
movl %ecx, 0x40(%r15)
movq -0x50(%rbp), %rcx
movq %rcx, 0x40(%rbx)
movq -0x40(%rbp), %rdx
movq %rcx, (%rdx)
addq $0x118, %rsp            # imm = 0x118
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq -0x30(%rbp), %rdx
movq -0x40(%rbp), %rsi
movq %rdx, (%rsi)
movl $0xffc0ffff, %edx       # imm = 0xFFC0FFFF
andl 0x10(%rbx), %edx
shll $0x10, %eax
orl %edx, %eax
movl %eax, 0x10(%rbx)
movq 0x40(%r13), %rax
movq %rax, 0x40(%rbx)
movl %ecx, %eax
jmp 0x4ab44
xorps %xmm0, %xmm0
callq 0x4b471
jmp 0x4aa09