fhelium.ir.dialects.fusion
Backend-independent regions of operations selected for joint execution.
FHEliumFusion
data View source
python
FHEliumFusion = Dialect('fhelium_fusion', [FusedOp, YieldOp], [])1
FusedOp
class View source
python
FusedOp(inputs: Sequence[SSAValue], result_types: Sequence[Attribute], body: Block, *, attributes: dict[str, Attribute] | None=None)1
Bases: IRDLOperation
Execute a pure region with one selected Backend implementation.
The body preserves the original operation semantics and returns every value used outside the region. Block arguments correspond to the outer operands, including resource bindings. Fusion itself does not change value state or imply a particular device, code generator, or CUDA Graph capture.
Attributes
| Name | Type | Default/value |
|---|---|---|
name | 'fhelium_fusion.execute' | |
inputs | var_operand_def() | |
outputs | var_result_def() | |
body | region_def('single_block') | |
traits | traits_def(Pure(), IsolatedFromAbove()) |
dependencies
method
python
def dependencies() -> OperationDependencies: ...1
Describe result reads in this operation's value coordinates.
verify_
method
python
def verify_() -> None: ...1
YieldOp
class View source
python
YieldOp(values: Sequence[SSAValue])1
Bases: IRDLOperation
Return the selected results of a fusion region.
Attributes
| Name | Type | Default/value |
|---|---|---|
name | 'fhelium_fusion.yield' | |
values | var_operand_def() | |
traits | traits_def(IsTerminator()) |
OPERATION_SPECS
constant View source
python
OPERATION_SPECS = (OperationSpec(FusedOp.name, 'fusion', None, None, operation_type=FusedOp, dependencies=region_dependencies), OperationSpec(YieldOp.name, 'fusion', None, 0, operation_type=YieldOp))1