// File: /workspace/github_c_makefile_star2_O0/janet-lang[P]janet/src/core/ev.c
// Function: janet_ev_default_threaded_callback
void janet_ev_default_threaded_callback(JanetEVGenericMessage return_value) {
    if (return_value.fiber == NULL) {
        return;
    }
    if (janet_fiber_can_resume(return_value.fiber)) {
        switch (return_value.tag) {
            default:
            case JANET_EV_TCTAG_NIL:
                janet_schedule(return_value.fiber, janet_wrap_nil());
                break;
            case JANET_EV_TCTAG_INTEGER:
                janet_schedule(return_value.fiber, janet_wrap_integer(return_value.argi));
                break;
            case JANET_EV_TCTAG_STRING:
            case JANET_EV_TCTAG_STRINGF:
                janet_schedule(return_value.fiber, janet_cstringv((const char *) return_value.argp));
                if (return_value.tag == JANET_EV_TCTAG_STRINGF) janet_free(return_value.argp);
                break;
            case JANET_EV_TCTAG_KEYWORD:
                janet_schedule(return_value.fiber, janet_ckeywordv((const char *) return_value.argp));
                break;
            case JANET_EV_TCTAG_ERR_STRING:
            case JANET_EV_TCTAG_ERR_STRINGF:
                janet_cancel(return_value.fiber, janet_cstringv((const char *) return_value.argp));
                if (return_value.tag == JANET_EV_TCTAG_STRINGF) janet_free(return_value.argp);
                break;
            case JANET_EV_TCTAG_ERR_KEYWORD:
                janet_cancel(return_value.fiber, janet_ckeywordv((const char *) return_value.argp));
                break;
            case JANET_EV_TCTAG_BOOLEAN:
                janet_schedule(return_value.fiber, janet_wrap_boolean(return_value.argi));
                break;
        }
    }
    janet_gcunroot(janet_wrap_fiber(return_value.fiber));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
leaq 0x10(%rbp), %rax
movq %rax, -0x48(%rbp)
cmpq $0x0, 0x18(%rax)
jne 0x2f3cf
jmp 0x2f5f3
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x378b0
cmpl $0x0, %eax
je 0x2f5cf
movq -0x48(%rbp), %rax
movl (%rax), %eax
movq %rax, -0x50(%rbp)
subq $0x8, %rax
ja 0x2f409
movq -0x50(%rbp), %rax
leaq 0x56bd0(%rip), %rcx     # 0x85fd0
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
jmp 0x2f40b
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x58(%rbp)
movabsq $-0x77fffffffffff, %rdi # imm = 0xFFF8800000000001
callq 0x7b460
movq -0x58(%rbp), %rdi
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rsi
callq 0x2b160
jmp 0x2f5cd
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rcx
movq %rcx, -0x60(%rbp)
cvtsi2sdl 0x4(%rax), %xmm0
callq 0x7b820
movq -0x60(%rbp), %rdi
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rsi
callq 0x2b160
jmp 0x2f5cd
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rcx
movq %rcx, -0x68(%rbp)
movq 0x8(%rax), %rdi
callq 0x64a70
movq %rax, %rdi
movabsq $-0x6000000000000, %rsi # imm = 0xFFFA000000000000
callq 0x7b550
movq -0x68(%rbp), %rdi
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rsi
callq 0x2b160
movq -0x48(%rbp), %rax
cmpl $0x3, (%rax)
jne 0x2f4b6
movq -0x48(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x120b0
jmp 0x2f5cd
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rcx
movq %rcx, -0x70(%rbp)
movq 0x8(%rax), %rdi
callq 0x68d90
movq %rax, %rdi
movabsq $-0x5000000000000, %rsi # imm = 0xFFFB000000000000
callq 0x7b550
movq -0x70(%rbp), %rdi
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rsi
callq 0x2b160
jmp 0x2f5cd
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rcx
movq %rcx, -0x78(%rbp)
movq 0x8(%rax), %rdi
callq 0x64a70
movq %rax, %rdi
movabsq $-0x6000000000000, %rsi # imm = 0xFFFA000000000000
callq 0x7b550
movq -0x78(%rbp), %rdi
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rsi
callq 0x2b130
movq -0x48(%rbp), %rax
cmpl $0x3, (%rax)
jne 0x2f546
movq -0x48(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x120b0
jmp 0x2f5cd
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rcx
movq %rcx, -0x80(%rbp)
movq 0x8(%rax), %rdi
callq 0x68d90
movq %rax, %rdi
movabsq $-0x5000000000000, %rsi # imm = 0xFFFB000000000000
callq 0x7b550
movq -0x80(%rbp), %rdi
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rsi
callq 0x2b130
jmp 0x2f5cd
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rcx
movq %rcx, -0x88(%rbp)
cmpl $0x0, 0x4(%rax)
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
movslq %eax, %rdi
movabsq $-0x7000000000000, %rax # imm = 0xFFF9000000000000
orq %rax, %rdi
callq 0x7b460
movq -0x88(%rbp), %rdi
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rsi
callq 0x2b160
jmp 0x2f5cf
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rdi
movabsq $-0x6800000000000, %rsi # imm = 0xFFF9800000000000
callq 0x7b610
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rdi
callq 0x3a2c0
addq $0x90, %rsp
popq %rbp
retq
nopl (%rax)