Skip to content

bloqade.lanes.rewrite.move2squin.base.AtomStateRewriter

← Module overview

classAtomStateRewritersource

bloqade.lanes.rewrite.move2squin.base.AtomStateRewriter

Bases: rewrite_abc.RewriteRule

Signature
class AtomStateRewriter(arch_spec: ArchSpec, physical_ssa_values: dict[int, ir.SSAValue])

Parameters

NameTypeDescription
arch_specArchSpec
physical_ssa_valuesdict[int, ir.SSAValue]

Attributes

NameTypeDescription
arch_specArchSpec
physical_ssa_valuesdict[int, ir.SSAValue]

methodget_qubit_ssasource

bloqade.lanes.rewrite.move2squin.base.AtomStateRewriter.get_qubit_ssa

Signature
def get_qubit_ssa(atom_state: atom.AtomState, location: LocationAddress) -> ir.SSAValue | None

Parameters

NameTypeDescription
atom_stateatom.AtomState
locationLocationAddress

Returns

ir.SSAValue | None

source

methodget_qubit_ssa_from_locationssource

bloqade.lanes.rewrite.move2squin.base.AtomStateRewriter.get_qubit_ssa_from_locations

Signature
def get_qubit_ssa_from_locations(atom_state: atom.AtomState, location_addresses: tuple[LocationAddress, ...]) -> tuple[ir.SSAValue | None, ...]

Parameters

NameTypeDescription
atom_stateatom.AtomState
location_addressestuple[LocationAddress, ...]

Returns

tuple[ir.SSAValue | None, ...]

source