[NEW PASS] Parallelization of Commuting Gates #396
Replies: 4 comments 24 replies
-
|
Hi @gluonhiggs , I'm one of the UCC maintainers :) Thanks for your proposal! So if I understand correctly, you'd like to incorporate the logic from this Commuting2qGateRouter pass into UCCDefault1, right? |
Beta Was this translation helpful? Give feedback.
-
|
@gluonhiggs Let us know if your have any questions or need any support :) |
Beta Was this translation helpful? Give feedback.
-
|
Gotcha thanks @gluonhiggs ! Nice to see the runtimes down a bit. Can you rerun this plotting script with the your new pass data included, so we can compare the avg performance. |
Beta Was this translation helpful? Give feedback.
-
|
Hi @gluonhiggs -- I wanted to reach out and let you know if you're still interested in developing on a compiler pass in UCC, contributions are now eligible for compensation year-round :) Here's our blog post with the details it: https://unitary.foundation/posts/2025_merit_systems_uf/ |
Beta Was this translation helpful? Give feedback.

Uh oh!
There was an error while loading. Please reload this page.
-
1. How the technique works
a. Provide a written abstract without too much jargon (cite arXiv paper/GitHub repo if applicable)
The "Parallelization of Commuting Gates" pass optimizes quantum circuits by identifying two-qubit gates (like CNOTs) that can run at the same time because they operate on separate qubits and don’t interfere with each other. Using Qiskit’s
Commuting2qGateRouter, the pass reorganizes these gates into parallel layers, shortening the overall circuit depth. On quantum computers, especially NISQ devices with limited coherence times, shorter circuits can run faster and with fewer errors.https://arxiv.org/abs/1204.4570
b. (Optional) Attach a diagram showing an example circuit transformation (you can add this later)
2. Performance expectations
a. What circuit types will this improve? (e.g., dynamic circuits, error correction)
Variational algorithms, circuits with operations on separate qubit groups that don’t overlap
b. Which UCC metrics will it impact? (gate counts, errors, etc.)
Circuit Depth: By running commuting gates in parallel, it reduces the number of layers in the circuit.
Runtime: Shorter circuits should execute faster on quantum hardware or simulators.
Relative Errors: On NISQ devices, shorter circuits experience less noise
Develop your compiler pass
Once the maintainers have given you the go-ahead, you can work on the next sections:
Create a fork of UCC to develop in: [link your fork here]
Hint: We recommending syncing your fork with the main branch of UCC to stay up to date with changes.
Implement and Validate a Prototype of the Pass:
A Jupyter notebook or a small script is sufficient for the prototype: [link prototype script/notebook here].
Important: Make sure your compiler pass works as you expect on the circuits you defined in step 2a.
Implement the New Pass in the UCC Codebase:
Documentation to guide you through this process is available in the user guide. For more detailed information and examples, refer to the Qiskit documentation.
Benchmark performance
UCC benchmarks live in the separate repo called ucc-bench. We have a suite of quantum circuits that we regularly benchmark UCC and other popular quantum compilers on. Several of the key metrics we track are:
Compiling alone:
Simulating compiled circuits:
Your new pass should improve one or more of these metrics on our existing benchmark suite.
When you are ready to run benchmarks...
Useful documentation
Contributing Guide
Setting up your Developer Environment
Writing a Custom Transpiler Pass
-We use "transpiler pass" to refer to transformations that act only on the Directed Acyclic Graph (DAG) representation of the quantum circuit. Higher or lower-level optimizations (e.g. algorithm-level or pulse-level, respectively), we call "compiler passes."
Beta Was this translation helpful? Give feedback.
All reactions