Loom C API
Public Loom compiler C API
Loading...
Searching...
No Matches
loomc_task_t Struct Reference

Base embedded at offset zero in one caller-defined work record. More...

Data Fields

const loomc_task_vtable_tvtable
 Static callbacks implementing the concrete task.
loomc_task_tnext
 Sink-owned intrusive link while the accepted task is queued.

Detailed Description

Base embedded at offset zero in one caller-defined work record.

A task has one ownership reference and is not reference counted. Successful submission transfers that reference to the sink, which executes the task exactly once and then destroys it exactly once. Failed submission leaves destruction to the caller.

Field Documentation

◆ next

loomc_task_t* loomc_task_t::next

Sink-owned intrusive link while the accepted task is queued.

Task initialization sets this to NULL. A sink may use it only between accepting the task and invoking its terminal callback, and must clear it before execution. Exclusive task ownership permits one queue membership at a time.


The documentation for this struct was generated from the following file: