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

Add Rust representation for CHGate, CPhaseGate, CSGate, CSdgGate, CSXGate, CSwapGate #12639

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

ElePT
Copy link
Contributor

@ElePT ElePT commented Jun 21, 2024

Summary

This PR adds Rust representations for:

  • CHGate
  • CPhaseGate
  • CSGate
  • CSdgGate
  • CSXGate
  • CSwapGate

As part of #12566.

Details and comments

This PR also includes placeholders for all missing gates in #12566 with a dummy number of qubits and number of parameters (34) that should be replaced with the actual number when implemented. It's redundant with #12646, which I added in case it could help out other contributors while this PR got sorted out. If this PR gets approved before #12646 there's no need for it.

@ElePT ElePT changed the title Add CHGate, CPhaseGate, CSGate, CSdgGate, CSXGate, CSwapGate Add Rust representation for CHGate, CPhaseGate, CSGate, CSdgGate, CSXGate, CSwapGate Jun 21, 2024
@ElePT ElePT added performance Rust This PR or issue is related to Rust code in the repository labels Jun 24, 2024
@ElePT ElePT marked this pull request as ready for review June 24, 2024 14:00
@ElePT ElePT requested a review from a team as a code owner June 24, 2024 14:00
@qiskit-bot
Copy link
Collaborator

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

  • @Cryoris
  • @Qiskit/terra-core
  • @ajavadia
  • @kevinhartman
  • @mtreinish

@ElePT ElePT added the Changelog: None Do not include in changelog label Jun 24, 2024
@coveralls
Copy link

coveralls commented Jun 24, 2024

Pull Request Test Coverage Report for Build 9646684161

Details

  • 164 of 202 (81.19%) changed or added relevant lines in 8 files are covered.
  • 26 unchanged lines in 3 files lost coverage.
  • Overall coverage decreased (-0.05%) to 89.731%

Changes Missing Coverage Covered Lines Changed/Added Lines %
qiskit/circuit/quantumcircuit.py 22 32 68.75%
crates/circuit/src/operations.rs 128 156 82.05%
Files with Coverage Reduction New Missed Lines %
crates/qasm2/src/expr.rs 1 94.02%
crates/qasm2/src/lex.rs 7 92.11%
crates/qasm2/src/parse.rs 18 96.69%
Totals Coverage Status
Change from base Build 9642268925: -0.05%
Covered Lines: 63796
Relevant Lines: 71097

💛 - Coveralls

@coveralls
Copy link

coveralls commented Jun 24, 2024

Pull Request Test Coverage Report for Build 9648400932

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 180 of 216 (83.33%) changed or added relevant lines in 8 files are covered.
  • 23 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.04%) to 89.742%

Changes Missing Coverage Covered Lines Changed/Added Lines %
qiskit/circuit/quantumcircuit.py 22 32 68.75%
crates/circuit/src/operations.rs 144 170 84.71%
Files with Coverage Reduction New Missed Lines %
crates/qasm2/src/lex.rs 5 92.88%
crates/qasm2/src/parse.rs 18 96.23%
Totals Coverage Status
Change from base Build 9647487742: -0.04%
Covered Lines: 63878
Relevant Lines: 71180

💛 - Coveralls

@coveralls
Copy link

coveralls commented Jun 25, 2024

Pull Request Test Coverage Report for Build 9658017782

Details

  • 180 of 196 (91.84%) changed or added relevant lines in 8 files are covered.
  • 21 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.008%) to 89.746%

Changes Missing Coverage Covered Lines Changed/Added Lines %
crates/circuit/src/operations.rs 144 150 96.0%
qiskit/circuit/quantumcircuit.py 22 32 68.75%
Files with Coverage Reduction New Missed Lines %
crates/qasm2/src/lex.rs 3 92.37%
crates/qasm2/src/parse.rs 18 96.69%
Totals Coverage Status
Change from base Build 9650973845: -0.008%
Covered Lines: 63901
Relevant Lines: 71202

💛 - Coveralls

@coveralls
Copy link

coveralls commented Jun 25, 2024

Pull Request Test Coverage Report for Build 9662781712

Details

  • 180 of 196 (91.84%) changed or added relevant lines in 8 files are covered.
  • 3 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.04%) to 89.756%

Changes Missing Coverage Covered Lines Changed/Added Lines %
crates/circuit/src/operations.rs 144 150 96.0%
qiskit/circuit/quantumcircuit.py 22 32 68.75%
Files with Coverage Reduction New Missed Lines %
crates/qasm2/src/lex.rs 3 92.62%
Totals Coverage Status
Change from base Build 9661630219: 0.04%
Covered Lines: 63908
Relevant Lines: 71202

💛 - Coveralls

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 changelog performance Rust This PR or issue is related to Rust code in the repository
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants