Skip to main content

Module thread

Module thread 

Source

Structs§

AutoExpiringPreemptDisabler
RAII guard that sets a timeslice extension for its scope.
AutoPreemptDisabler
RAII guard that disables preemption for its scope.
FxtRef
Rust representation of the C++ FxtRef struct.
ThreadPtr
Type-safe wrapper around a raw pointer to a Zircon kernel Thread.

Functions§

create
Creates a new kernel thread with default priority.
preempt_clear_timeslice_extension
Clears an expiring timeslice extension on the current thread’s preemption state.
preempt_disable
Disables preemption on the current thread.
preempt_enable
Re-enables preemption on the current thread.
preempt_set_timeslice_extension
Sets a timeslice extension on the current thread’s preemption state.
restricted_enter
Enters restricted mode using the given vector table pointer and context.
sleep_relative
Sleeps the current thread for the specified relative duration.
spawn
Spawns a new kernel thread with default priority and resumes it.
yield
Yields the current thread’s CPU time slice.