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

LazifyMeasurePass doesn't work on all ops #740

Closed
doug-q opened this issue Jan 8, 2025 · 0 comments · Fixed by #742
Closed

LazifyMeasurePass doesn't work on all ops #740

doug-q opened this issue Jan 8, 2025 · 0 comments · Fixed by #742
Assignees

Comments

@doug-q
Copy link
Contributor

doug-q commented Jan 8, 2025

We only rewrite Tket2Op::Measure.

It happens that we rewrite Tket2Op::Measure => TQsystemOp::Measure before we lazify, so as is it's a no-op pass.

I suggest we leave the pass ordering as is, and add cases to move to rewriting:

  • Tket2Op::Measure
  • Tket2Op::MeasureFree
  • QSystemOp::Measure
  • QSystemOp::MeasureReset

Let's simultaneously change LowerTket2ToQSystemPass to lower to lazy measures directly (sharing code obviously).

@doug-q doug-q self-assigned this Jan 8, 2025
doug-q added a commit that referenced this issue Jan 8, 2025
doug-q added a commit that referenced this issue Jan 8, 2025
github-merge-queue bot pushed a commit that referenced this issue Jan 10, 2025
… `QSystemOp::LazyMeasureReset` (#741)

Done in the process of addressing #740 

BREAKING CHANGE: The signature of `QSystemOp::LazyMeasure` is changed to
consume its qubit.
github-merge-queue bot pushed a commit that referenced this issue Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant