scopeΒΆ
Scope configuration for a pass.
A PassScope defines the parts of a HUGR that a pass should be applied to, and which parts is it allowed to modify. Each variant defines three properties: root, preserve_interface and recursive.
From these, regions and in_scope can be derived.
A pass will always optimize the entrypoint region, unless the entrypoint is the module root.
Classes
Custom metaclass for things that inherit from both ABC and Enum. |
|
Run the pass on the whole Hugr, regardless of the entrypoint. |
|
Whether a pass may modify a particular node. |
|
A PassScope that means the pass should modify the hugr only beneath the entrypoint, unless the entrypoint is the module root, in which case the pass should do nothing. |
|
Abstract superclass for concrete implementations of PassScope. |