ISAQuery Class

Abstract base class for all nodes in the ISA enumeration tree.

Enumeration nodes define the structure of the search space for ISAs starting from architectures and modified by ISA transforms such as error correction schemes. They can be composed using operators like + (sum) and * (product) to build complex enumeration strategies.

Constructor

ISAQuery()

Methods

bind

Create a BindingNode with this node as the component.

Example:

enumerate

Yields all ISA instances represented by this enumeration node.

populate

Populate the provenance graph with instructions from this node.

Unlike enumerate, this does not yield ISA objects. Each transform queries the graph for Pareto-optimal instructions matching its requirements, and adds produced instructions directly to the graph.

bind

Create a BindingNode with this node as the component.

Example:

bind(name: str, node: ISAQuery) -> _BindingNode

Parameters

Name Description
name
Required

The name to bind the component to.

node
Required

The child enumeration node that may contain ISARefNodes.

Returns

Type Description

A BindingNode with self as the component.

enumerate

Yields all ISA instances represented by this enumeration node.

abstract enumerate(ctx: ISAContext) -> Generator[ISA, None, None]

Parameters

Name Description
ctx
Required

The enumeration context containing shared state, e.g., access to the underlying architecture.

populate

Populate the provenance graph with instructions from this node.

Unlike enumerate, this does not yield ISA objects. Each transform queries the graph for Pareto-optimal instructions matching its requirements, and adds produced instructions directly to the graph.

populate(ctx: ISAContext) -> int

Parameters

Name Description
ctx
Required

The enumeration context whose provenance graph will be populated.

Returns

Type Description
int

The starting node index of the instructions contributed by this subtree. Used by consumers to scope graph queries to only see their source's nodes.