|
Loom C API
Public Loom compiler C API
|
Compile invocation options. More...
#include <compile.h>
Data Fields | |
| loomc_structure_type_t | type |
| Structure type. | |
| loomc_host_size_t | structure_size |
| Size of this structure in bytes. | |
| const void * | next |
| Extension chain for compile invocation options such as loomc_target_specialization_options_t. | |
| loomc_string_view_t | module_name |
| Runtime artifact module name for this invocation. | |
| loomc_compile_artifact_flags_t | artifact_flags |
| Requested result artifacts. | |
| loomc_config_policy_flags_t | config_flags |
| Config validation and final-resolution policy. | |
| const loomc_module_t * | config_module |
| Optional module containing only exact config.def operations. | |
Compile invocation options.
A compile invocation borrows a mutable module and returns a result with diagnostics and artifacts. Exact values from an optional config module materialize into the program module before the selected pass program runs. Configuration lives here rather than on the prepared compiler so autotuning and JIT sweeps can vary config without constructing many compiler handles. Per-function target specializations and target-declaration bindings are supplied through loomc_target_specialization_options_t on next, so one invocation can compile several function versions for different exact targets.
| loomc_compile_artifact_flags_t loomc_compile_options_t::artifact_flags |
Requested result artifacts.
Zero avoids artifact serialization and keeps the hot path focused on diagnostics and in-place module transformation.
| const loomc_module_t* loomc_compile_options_t::config_module |
Optional module containing only exact config.def operations.
The module is borrowed, remains immutable, must use the compiler context, and must be distinct from the mutable program module. Definitions without matching program config symbols are ignored so one config module can serve several related programs. Load text or bytecode config modules through the normal format-specific module deserialization APIs.
| loomc_string_view_t loomc_compile_options_t::module_name |
Runtime artifact module name for this invocation.
Empty uses the compiler's default.
| loomc_structure_type_t loomc_compile_options_t::type |
Structure type.
Must be LOOMC_STRUCTURE_TYPE_COMPILE_OPTIONS when nonzero.