Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for switch statements in qasm3_to_qir converter #80

Open
TheGupta2012 opened this issue Apr 6, 2024 · 0 comments
Open

Add support for switch statements in qasm3_to_qir converter #80

TheGupta2012 opened this issue Apr 6, 2024 · 0 comments
Labels
enhancement New feature or request pyqir Interfacing with QIR python bindings qasm3 Related to OpenQASM 3 conversions unitary-hack Issues tagged with Unitary Hack '24

Comments

@TheGupta2012
Copy link
Collaborator

TheGupta2012 commented Apr 6, 2024

Feature Description

  • openqasm 3 also supports switch statements which allow users to condition statement execution based on integral variables.

Implementation (Optional)

  • The pyqir._native module does have a definition of the Switch construct but it is not entirely clear how that can be incorporated into the converter. A good starting point would be the pyqir._native definition and the openqasm switch reference

  • It would be good to have a handler for the switch, like the _visit_branching_statement. Since switch is also a type of branching instruction, we can either expand this method or create a new handler.

@TheGupta2012 TheGupta2012 added enhancement New feature or request pyqir Interfacing with QIR python bindings qasm3 Related to OpenQASM 3 conversions unitary-hack Issues tagged with Unitary Hack '24 labels Apr 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request pyqir Interfacing with QIR python bindings qasm3 Related to OpenQASM 3 conversions unitary-hack Issues tagged with Unitary Hack '24
Projects
None yet
Development

No branches or pull requests

1 participant