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

Avoid routing 2q barriers in SabreSwap #11295

Merged
merged 6 commits into from
Nov 23, 2023

Commits on Nov 22, 2023

  1. Avoid routing 2q barriers in SabreSwap

    This commit fixes an oversight in the sabre swap pass where a 2 qubit
    barrier would have been treated like a 2 qubit gate and swaps could
    potentially be inserted if the sabre algorithm thought it didn't have
    connectivity for the qargs to the barrier. However as barrier is just
    a compiler directive it is valid on all qubit pairs so this swap
    insertion was unnecessary, it was still valid but just not an optimal
    output. This commit fixes it by adding context to the sabre dag around
    whether a given node is a directive (and valid on all qubits) or not.
    mtreinish committed Nov 22, 2023
    Configuration menu
    Copy the full SHA
    1264e08 View commit details
    Browse the repository at this point in the history
  2. Update rust tests too

    mtreinish committed Nov 22, 2023
    Configuration menu
    Copy the full SHA
    afe2e3c View commit details
    Browse the repository at this point in the history
  3. Skip directives in extended set generation too

    Co-authored-by: Kevin Hartman <kevin@hart.mn>
    mtreinish and kevinhartman committed Nov 22, 2023
    Configuration menu
    Copy the full SHA
    89da56e View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    34e4a20 View commit details
    Browse the repository at this point in the history
  5. Add release note

    mtreinish committed Nov 22, 2023
    Configuration menu
    Copy the full SHA
    4389336 View commit details
    Browse the repository at this point in the history
  6. Update test layout in test_layout_many_search_trials

    This commit updates a layout in the:
    `TestSabreLayout.test_layout_many_search_trials` test case which was
    recently changed in Qiskit#10323. The change in test ouput caused by Qiskit#10323
    is what triggered the investigation into this bugfix and now that
    barriers are being treated correctly by sabre the layout doesn't change
    in the test case anymore and this is reverting the test assertion to use
    the original layout before Qiskit#10323 was merged.
    mtreinish committed Nov 22, 2023
    Configuration menu
    Copy the full SHA
    93a3241 View commit details
    Browse the repository at this point in the history