Skip to main content

jit_spawn_task

Function jit_spawn_task 

Source
#[unsafe(no_mangle)]
pub extern "C" fn jit_spawn_task( _ctx: *mut JITContext, callable_bits: u64, ) -> u64
Expand description

Spawn a new async task.

Delegates to the registered trampoline which has access to the VM’s task scheduler.

§Arguments

  • ctx - JIT execution context (unused directly, but kept for ABI consistency)
  • callable_bits - NaN-boxed callable value (function or closure)

§Returns

NaN-boxed Future(task_id) on success, TAG_NULL if no trampoline registered.