bloqade.lanes.dialects.place.Permute
← Module overview
class
classPermute¶source
bloqade.lanes.dialects.place.Permute
Bases: QuantumStmt
Place-layer permute directive.
class PermuteProduced by RewritePlaceOperations.rewrite_Permute from movement.Permute.
Consumed by placement analysis and deleted by RewriteGates after InsertMoves
emits any forward Move IR. perm is a permutation over the positions of
qubits: qubits[i] ends up referring to what was qubits[perm[i]].
insert_moves selects how the permutation is realized (see
MoveToPlacementStrategyABC.permute_placements):
False(default): relabel only — the qubit references are permuted with no physical moves (the layout is permuted; the quantum information is permuted for free). Valid under any strategy, including palindrome.True: also commit the physical moves that route the atoms so the permutation is realized in place (Permuted; layout pinned to the pre-permute layout). Rejected byPalindromePlacementStrategy.
Attributes
| Name | Type | Default | Description |
|---|---|---|---|
qubits | tuple[int, ...] | info.attribute() | |
perm | tuple[int, ...] | info.attribute() | |
insert_moves | bool | info.attribute(default=False) |