Expand description
Multi-threading management.
Structs§
- AxTask
Handle - A handle to a task.
- AxWait
Queue Handle - A handle to a wait queue.
Functions§
- ax_
current_ task_ id - Returns the current task’s ID.
- ax_exit
- Exits the current task with the given exit code.
- ax_
set_ current_ affinity - Sets the cpu affinity of the current task.
- ax_
set_ current_ priority - Sets the priority of the current task.
- ax_
sleep_ until - Current task is going to sleep, it will be woken up at the given deadline.
- ax_
spawn - Spawns a new task with the given entry point and other arguments.
- ax_
wait_ for_ exit - Waits for the given task to exit, and returns its exit code (the
argument of
ax_exit). - ax_
wait_ queue_ wait - Blocks the current task and put it into the wait queue, until other tasks notify the wait queue, or the the given duration has elapsed (if specified).
- ax_
wait_ queue_ wait_ until - Blocks the current task and put it into the wait queue, until the given condition becomes true, or the the given duration has elapsed (if specified).
- ax_
wait_ queue_ wake - Wakes up one or more tasks in the wait queue.
- ax_
yield_ now - Current task gives up the CPU time voluntarily, and switches to another ready task.
Type Aliases§
- AxCpu
Mask - A mask to specify the CPU affinity.
The wrapper type for [
cpumask::CpuMask] with SMP configuration.