• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Qiskit / qiskit / 15166718418

21 May 2025 03:47PM UTC coverage: 88.127% (+0.01%) from 88.116%
15166718418

Pull #14424

github

mergify[bot]
Fix ConsolidateBlocks pass for collecting non-CX KAK gate (#14417)

A bug was introduced into the ConsolidateBlocks pass in #13884 around
how the KAK gate name was passed to rust from the Python pass. The
consolidate blocks internal logic around whether to consolidate a pass
or not is based on the estimate from the selected decomposer of whether
the estimated number of gates used to synthesis the unitary would exceed
the number of basis gates in the block. To do this the pass counts the
gate with the synthesis target name in the block. However, in the case
of the decomposer being the TwoQubitBasisDecomposer the name being
used for this look wasn't the name of the gate, but instead was an
internal sentinel value string "USER_GATE" which is used to handle
arbitrary user gate definitions in the decomposer. This led to the
consolidate blocks pass missing opportunities for consolidation. This
commit fixes the oversight so that the name we use for making this
determination is the actual basis gate name and the pass functions
correctly.

Fixes #14413

(cherry picked from commit 4e9231df9)
Pull Request #14424: Fix ConsolidateBlocks pass for collecting non-CX KAK gate (backport #14417)

4 of 5 new or added lines in 1 file covered. (80.0%)

4 existing lines in 2 files now uncovered.

72935 of 82761 relevant lines covered (88.13%)

356370.51 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

94.81
/crates/accelerate/src/unitary_synthesis.rs


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc