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 conditional lowering #11

Open
chemix-lunacy opened this issue Mar 5, 2024 · 0 comments
Open

Add conditional lowering #11

chemix-lunacy opened this issue Mar 5, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@chemix-lunacy
Copy link
Contributor

Currently the symbolic executor doesn't attempt to lower conditionals even though the skeletons are there.

Requires:

  • Python APIs added to the builder to allow backends to make the correct decisions.
  • Projection objects to store the lowering. This may interfere with the new Forq-based state representation.
  • Add a step in the executor that if it is processing a conditional branch that it checks the body of the if, if it's fully quantum it then asks if any backends support lowering, if some do then it squashes that block into the projection and then continue from the end of the if.

Initially lowering can be simplistic and only requires a few checks: that the condition of the if is either quantum or a value that has been resolved; that every operation within the if is quantum as well, which should then recurse so we can squash nested if statements in.

@chemix-lunacy chemix-lunacy added the enhancement New feature or request label Mar 5, 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
Projects
None yet
Development

No branches or pull requests

1 participant