Skip to content

Unify common helper functions in rust transpiler passes#16433

Open
ShellyGarion wants to merge 1 commit into
Qiskit:mainfrom
ShellyGarion:unify_fidelity_funcs
Open

Unify common helper functions in rust transpiler passes#16433
ShellyGarion wants to merge 1 commit into
Qiskit:mainfrom
ShellyGarion:unify_fidelity_funcs

Conversation

@ShellyGarion

@ShellyGarion ShellyGarion commented Jun 15, 2026

Copy link
Copy Markdown
Member

There are some helper functions:

  • average_gate_fidelity_below_tol
  • is_angle_close_to_multiple_of_pi_k

and a constant MINIMUM_TOL = 1e-12

that are used in several transpiler passes in rust:

  • commutative_optimization.rs
  • remove_identity_equiv.rs
  • litinski_transformation.rs
  • substitute_pi4_rotation.rs

These functions and constant are moved to a new common.rs file for a better code organization.

AI/LLM disclosure

  • I didn't use LLM tooling, or only used it privately.
  • I used the following tool to help write this PR description:
  • I used the following tool to generate or modify code: Claude Sonnet 4.6

@ShellyGarion ShellyGarion requested a review from a team as a code owner June 15, 2026 09:57
@ShellyGarion ShellyGarion added the Changelog: None Do not include in the GitHub Release changelog. label Jun 15, 2026
@ShellyGarion ShellyGarion requested a review from Cryoris June 15, 2026 09:57
@qiskit-bot

Copy link
Copy Markdown
Collaborator

One or more of the following people are relevant to this code:

  • @Qiskit/terra-core

@ShellyGarion ShellyGarion added mod: transpiler Issues and PRs related to Transpiler Rust This PR or issue is related to Rust code in the repository labels Jun 15, 2026
@ShellyGarion ShellyGarion added this to the 2.6.0 milestone Jun 15, 2026
@ShellyGarion ShellyGarion added the fault tolerance related to fault tolerance compilation label Jun 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Changelog: None Do not include in the GitHub Release changelog. fault tolerance related to fault tolerance compilation mod: transpiler Issues and PRs related to Transpiler Rust This PR or issue is related to Rust code in the repository

Projects

Status: Ready

Development

Successfully merging this pull request may close these issues.

2 participants