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

Qiskit / qiskit / 26949555728
87%

Build:
DEFAULT BRANCH: main
Ran 04 Jun 2026 12:12PM UTC
Jobs 1
Files 946
Run time 2min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

04 Jun 2026 11:18AM UTC coverage: 87.482% (-0.01%) from 87.495%
26949555728

push

github

web-flow
Add additional Z and X rotation gate handling to CommutativeCancellation (#16191)

* Add additional Z and X rotation gate handling to CommutativeCancellation

This commit expands the the handling of Z and X rotations to the
commutative cancellation pass to cover missing gates that it could
easily handle. In addition for the output rotation gates special
handling is added for x and sx gates since we can easily emit those
gates if appropriate when the x rotation angle aligns with using those
gates.

* Refactor mod 4pi and mod 2pi check to be more robust

Co-authored-by: Julien Gacon <gaconju@gmail.com>

* Add tests and handle phase correctly

This commit adds test coverage for the pass emitting X and SX gates. The
global phase handling for this was incorrect because it was not
correctly accounting for the phase difference between X/SX and RX. This
would lead to the phase being tracked incorrectly because for the
internal pass tracking it's all in terms of RX gates. So if the circuit
was in terms of RX gates added and we emitted an X we'd be off because
we didn't correct for the phase difference in the output circuit. This
was also a problem if the circuit was in terms of X gates and we emit an
X gate we had added the phase difference for the RX tracking but then we
emitted the X gate and didn't need the phase correction. To address this
we need to track the circuit gates and then on the output handle the
correction according to the gate we're emitting. This is different from
how Z angles are tracked because unlike the Z rotation gates, the other
options for X gates are only for discrete angles. We would need similar
handling if Z rotations could emit a Z gate but we don't support that
currently so it's not an issue.

* Add release note

* Avoid standalone tracking of gate counts

The previous commit that was correcting for the phase difference between
gates was relying on counting the X and SX gates used to compute the
angle and phase difference. This w... (continued)

35 of 35 new or added lines in 2 files covered. (100.0%)

26 existing lines in 4 files now uncovered.

109107 of 124720 relevant lines covered (87.48%)

961517.72 hits per line

Coverage Regressions

Lines Coverage ∆ File
12
97.15
-0.95% crates/qasm2/src/parse.rs
9
73.93
-0.37% crates/circuit/src/parameter/symbol_expr.rs
4
92.03
0.0% crates/qasm2/src/lex.rs
1
91.03
0.0% crates/circuit/src/parameter/parameter_expression.rs
Jobs
ID Job ID Ran Files Coverage
1 26949555728.1 04 Jun 2026 12:12PM UTC 946
87.48
GitHub Action Run
Source Files on build 26949555728
  • Tree
  • List 946
  • Changed 7
  • Source Changed 2
  • Coverage Changed 6
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #26949555728
  • 91081cc6 on github
  • Prev Build on gh-readonly-queue/main/pr-16270-005fe52da455551733d7e1615e14eef10b942bc5 (#26945647529)
  • Next Build on main (#26950556481)
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

© 2026 Coveralls, Inc