|
Maestro 0.3.11
Unified interface for quantum circuit simulation
|
Typedefs | |
| typedef std::shared_ptr< AbstractSyntaxTree > | AbstractSyntaxTreePtr |
| using | ArgumentType = std::variant<std::string, IndexedId> |
| using | BarrierType = MixedListType |
| using | CondOpType = boost::fusion::vector<std::string, int, QopType> |
| using | CXGateCallType = boost::fusion::vector<ArgumentType, ArgumentType> |
| using | DeclarationRegistry = std::unordered_map<std::string, DeclarationKind> |
| using | ExpGatecallType = boost::fusion::vector<std::string, std::vector<Expression>, MixedListType> |
| using | GatecallType = std::variant<SimpleGatecallType, ExpGatecallType> |
| using | GateDeclOpType = std::variant<UopType, SimpleBarrierType> |
| using | GateDeclType = boost::fusion::vector<std::string, std::vector<std::string>, std::vector<std::string>> |
| using | InputDeclType = boost::fusion::vector<std::string, boost::optional<int>, std::string> |
| using | MeasureType = boost::fusion::vector<ArgumentType, ArgumentType> |
| using | MixedListType = std::vector<ArgumentType> |
| using | ModifiedUopType = boost::fusion::vector<ModifierListType, UopType> |
| using | ModifierListType = std::vector<ModifierType> |
| using | OpaqueDeclType = boost::fusion::vector<std::string, std::vector<std::string>, std::vector<std::string>> |
| using | ProgramType = boost::fusion::vector<std::vector<std::string>, double, std::vector<std::string>, std::vector<StatementType>> |
| using | QopType = StatementType |
| using | RegisterMap = std::unordered_map<std::string, IndexedId> |
| using | ResetType = ArgumentType |
| using | SimpleBarrierType = std::vector<std::string> |
| using | SimpleExpType = std::variant<double, int, std::string> |
| using | SimpleGatecallType = boost::fusion::vector<std::string, MixedListType> |
| using | StatementType = QoperationStatement |
| using | UGateCallType = boost::fusion::vector<std::vector<Expression>, ArgumentType> |
| using | UopType = std::variant<UGateCallType, CXGateCallType, GatecallType> |
Enumerations | |
| enum class | DeclarationKind { Qubit , Bit , Input , Gate , Opaque } |
| enum class | ModifierKind { Ctrl , NegCtrl , Inv , Pow } |
Functions | |
| void | ApplyCondition (StatementType &stmt, const std::vector< int > &conditionBits, const std::vector< bool > &expectedValues) |
| template<typename Expr> | |
| static AbstractSyntaxTreePtr | Clone (Expr const &t) |
| std::string_view | DeclarationKindName (DeclarationKind kind) |
| std::vector< bool > | DecodeRegisterCondition (const std::string ®isterName, int value, size_t width) |
| double | EvaluateGateParameter (const Expression ¶meter, const std::unordered_map< std::string, double > &variables) |
| UopType | MakeCall (const std::string &gateName, const std::vector< double > ¶ms, const MixedListType &args) |
| template<class Time> | |
| std::shared_ptr< Circuits::ICondition > | MakeEqualCondition (const std::vector< int > &conditionBits, const std::vector< bool > &expectedValues) |
| void | RegisterDeclaration (DeclarationRegistry &declarations, const std::string &name, DeclarationKind kind) |
| void | RejectPredicateMutationBeforeReevaluation (const std::vector< QopType > &body, const std::vector< int > &conditionBits, bool followedByElse, std::string_view branchName) |
| void | RequireMatchingRegisterWidths (const std::vector< int > &left, const std::vector< int > &right, std::string_view operation) |
| std::vector< int > | ResolveRegisterOperand (const ArgumentType &argument, const RegisterMap ®isters, std::string_view kind) |
| double | ValidateInputBinding (const std::string &name, const std::string &type, const boost::optional< int > &width, double value) |
| void | ValidateInputDeclaration (const std::string &name, const std::string &type, const boost::optional< int > &width) |
| int | ValidateRegisterAllocation (const IndexedId &id, int currentSize, std::string_view kind) |
| struct qasm::CondBitTest |
Definition at line 354 of file SimpleOps.h.
| Class Members | ||
|---|---|---|
| IndexedId | bit | |
| bool | expected = true | |
| struct qasm::CondHeadType |
Definition at line 360 of file SimpleOps.h.
| Class Members | ||
|---|---|---|
| vector< CondBitTest > | bits | |
| bool | isBitForm = false | |
| string | regId | |
| int | regValue = 0 | |
| struct qasm::DelayType |
Definition at line 325 of file SimpleOps.h.
| Class Members | ||
|---|---|---|
| double | duration = 0.0 | |
| MixedListType | operands | |
| typedef std::shared_ptr<AbstractSyntaxTree> qasm::AbstractSyntaxTreePtr |
| using qasm::ArgumentType = std::variant<std::string, IndexedId> |
Definition at line 131 of file SimpleOps.h.
| using qasm::BarrierType = MixedListType |
Definition at line 323 of file SimpleOps.h.
| using qasm::CondOpType = boost::fusion::vector<std::string, int, QopType> |
Definition at line 333 of file SimpleOps.h.
| using qasm::CXGateCallType = boost::fusion::vector<ArgumentType, ArgumentType> |
Definition at line 176 of file SimpleOps.h.
| using qasm::DeclarationRegistry = std::unordered_map<std::string, DeclarationKind> |
Definition at line 68 of file SimpleOps.h.
| using qasm::ExpGatecallType = boost::fusion::vector<std::string, std::vector<Expression>, MixedListType> |
Definition at line 172 of file SimpleOps.h.
| using qasm::GatecallType = std::variant<SimpleGatecallType, ExpGatecallType> |
Definition at line 173 of file SimpleOps.h.
| using qasm::GateDeclOpType = std::variant<UopType, SimpleBarrierType> |
Definition at line 427 of file SimpleOps.h.
| using qasm::GateDeclType = boost::fusion::vector<std::string, std::vector<std::string>, std::vector<std::string>> |
Definition at line 425 of file SimpleOps.h.
| using qasm::InputDeclType = boost::fusion::vector<std::string, boost::optional<int>, std::string> |
Definition at line 134 of file SimpleOps.h.
| using qasm::MeasureType = boost::fusion::vector<ArgumentType, ArgumentType> |
Definition at line 322 of file SimpleOps.h.
| using qasm::MixedListType = std::vector<ArgumentType> |
Definition at line 133 of file SimpleOps.h.
| using qasm::ModifiedUopType = boost::fusion::vector<ModifierListType, UopType> |
Definition at line 213 of file SimpleOps.h.
| using qasm::ModifierListType = std::vector<ModifierType> |
Definition at line 212 of file SimpleOps.h.
| using qasm::OpaqueDeclType = boost::fusion::vector<std::string, std::vector<std::string>, std::vector<std::string>> |
Definition at line 428 of file SimpleOps.h.
| using qasm::ProgramType = boost::fusion::vector<std::vector<std::string>, double, std::vector<std::string>, std::vector<StatementType>> |
Definition at line 319 of file SimpleOps.h.
| using qasm::QopType = StatementType |
Definition at line 332 of file SimpleOps.h.
| using qasm::RegisterMap = std::unordered_map<std::string, IndexedId> |
Definition at line 132 of file SimpleOps.h.
| using qasm::ResetType = ArgumentType |
Definition at line 321 of file SimpleOps.h.
| using qasm::SimpleBarrierType = std::vector<std::string> |
Definition at line 426 of file SimpleOps.h.
| using qasm::SimpleExpType = std::variant<double, int, std::string> |
Definition at line 129 of file SimpleOps.h.
| using qasm::SimpleGatecallType = boost::fusion::vector<std::string, MixedListType> |
Definition at line 171 of file SimpleOps.h.
Definition at line 317 of file SimpleOps.h.
| using qasm::UGateCallType = boost::fusion::vector<std::vector<Expression>, ArgumentType> |
Definition at line 175 of file SimpleOps.h.
| using qasm::UopType = std::variant<UGateCallType, CXGateCallType, GatecallType> |
Definition at line 178 of file SimpleOps.h.
|
strong |
| Enumerator | |
|---|---|
| Qubit | |
| Bit | |
| Input | |
| Gate | |
| Opaque | |
Definition at line 59 of file SimpleOps.h.
|
strong |
| Enumerator | |
|---|---|
| Ctrl | |
| NegCtrl | |
| Inv | |
| Pow | |
Definition at line 182 of file SimpleOps.h.
|
inline |
Definition at line 1116 of file SyntaxTree.h.
References ApplyCondition(), qasm::QoperationStatement::cbits, qasm::QoperationStatement::condBits, qasm::QoperationStatement::condExpected, qasm::QoperationStatement::CondUop, qasm::QoperationStatement::Measurement, qasm::QoperationStatement::opType, and qasm::QoperationStatement::Reset.
Referenced by ApplyCondition(), qasm::AddBitCondBranchExpr::operator()(), and qasm::AddCondQopExpr::operator()().
|
static |
Definition at line 68 of file Expr.h.
Referenced by qasm::BinaryOperator::BinaryOperator(), qasm::Function::Function(), and qasm::UnaryOperator::UnaryOperator().
|
inline |
Definition at line 70 of file SimpleOps.h.
References Bit, Gate, Input, Opaque, and Qubit.
Referenced by RegisterDeclaration().
|
inline |
Definition at line 1094 of file SyntaxTree.h.
References DecodeRegisterCondition().
Referenced by DecodeRegisterCondition(), qasm::AddCondQopBracedExpr::operator()(), and qasm::AddCondQopExpr::operator()().
|
inline |
Definition at line 25 of file SyntaxTree.h.
References qasm::Expression::Eval().
Referenced by qasm::AddModifiedGateExpr::Canonicalize().
|
inline |
Definition at line 36 of file SyntaxTree.h.
Referenced by qasm::AddModifiedGateExpr::ConjugateNegatedControls().
|
inline |
Definition at line 1081 of file SyntaxTree.h.
References Circuits::CircuitFactory< Time >::CreateEqualCondition(), and MakeEqualCondition().
Referenced by qasm::Program::AddToCircuit(), and MakeEqualCondition().
|
inline |
Definition at line 89 of file SimpleOps.h.
References DeclarationKindName().
Referenced by qasm::AddCregExpr::operator()(), qasm::AddGateDeclExpr::operator()(), qasm::AddInputDeclExpr::operator()(), qasm::AddOpaqueDeclExpr::operator()(), and qasm::AddQregExpr::operator()().
|
inline |
Definition at line 1184 of file SyntaxTree.h.
References qasm::QoperationStatement::Measurement, and RejectPredicateMutationBeforeReevaluation().
Referenced by qasm::AddCondQopBracedExpr::operator()(), and RejectPredicateMutationBeforeReevaluation().
|
inline |
Definition at line 165 of file SimpleOps.h.
Referenced by qasm::AddMeasureExpr::operator()().
|
inline |
Definition at line 136 of file SimpleOps.h.
References qasm::IndexedId::base, and qasm::IndexedId::index.
Referenced by qasm::AddBarrierExpr::operator()(), qasm::AddCondQopBracedExpr::operator()(), qasm::AddCondQopExpr::operator()(), qasm::AddDelayExpr::operator()(), qasm::AddMeasureExpr::operator()(), qasm::AddResetExpr::operator()(), and qasm::AddGateExpr::ParseQubits().
|
inline |
Definition at line 553 of file SimpleOps.h.
References ValidateInputDeclaration().
Referenced by qasm::AddInputDeclExpr::operator()().
|
inline |
Definition at line 519 of file SimpleOps.h.
Referenced by qasm::AddInputDeclExpr::operator()(), and ValidateInputBinding().
|
inline |
Definition at line 101 of file SimpleOps.h.
Referenced by qasm::AddCregExpr::operator()(), and qasm::AddQregExpr::operator()().
|
inline |
Definition at line 745 of file SimpleOps.h.
|
inline |
Definition at line 498 of file SimpleOps.h.
|
inline |
Definition at line 1156 of file SyntaxTree.h.
|
inline |
Definition at line 1286 of file SyntaxTree.h.
|
inline |
Definition at line 453 of file SimpleOps.h.
|
inline |
Definition at line 517 of file SimpleOps.h.
|
inline |
Definition at line 792 of file SimpleOps.h.
|
inline |
Definition at line 604 of file SyntaxTree.h.
|
inline |
Definition at line 883 of file SimpleOps.h.
|
inline |
Definition at line 640 of file SimpleOps.h.
|
inline |
Definition at line 662 of file SimpleOps.h.
|
inline |
Definition at line 993 of file SyntaxTree.h.
|
inline |
Definition at line 826 of file SimpleOps.h.
|
inline |
Definition at line 478 of file SimpleOps.h.
|
inline |
Definition at line 708 of file SimpleOps.h.
|
inline |
|
inline |
|
inline |
Definition at line 423 of file SimpleOps.h.
|
inline |
Definition at line 405 of file SimpleOps.h.
|
inline |
|
inline |
Definition at line 276 of file SimpleOps.h.
|
inline |
Definition at line 769 of file SimpleOps.h.
|
inline |
|
inline |
Definition at line 127 of file SimpleOps.h.
|
inline |
Definition at line 235 of file SimpleOps.h.
|
inline |
Definition at line 387 of file SimpleOps.h.
|
inline |
|
inline |
|
inline |
Definition at line 1015 of file SyntaxTree.h.
|
inline |
Definition at line 690 of file SimpleOps.h.
|
inline |
Definition at line 1078 of file SyntaxTree.h.
|
inline |
Definition at line 1038 of file SyntaxTree.h.