Skip to content

✨ Add fractional Heron compilation targets - #1087

Merged
simon1hofmann merged 23 commits into
mainfrom
codex/bench-fractional-heron
Oct 21, 2026
Merged

simon1hofmann merged 23 commits into
mainfrom
codex/bench-fractional-heron

Conversation

@simon1hofmann

@simon1hofmann simon1hofmann commented Oct 21, 2026 •

Copy link
Copy Markdown
Collaborator

🤖 AI text below 🤖

Description

Add fractional IBM Heron gate sets and a 156-qubit device. Require Qiskit 2.2.3 so fractional targets register unconditionally and angle-bound tests run on every supported version. Document the new minimum and upgrade command in UPGRADING.md.

RX and RZZ use Qiskit's theta parameter name. Numeric RZZ angles fold into [0, pi/2] with local gates and exact phase corrections, without changing Qiskit's global wrapping registry.

Extracted from #1027 so this change can land independently of MQT Core 4.2. Original code authorship is retained.

Validation: the full suite passed on Qiskit 2.6.0 and in minimums-3.11 with Qiskit 2.2.3 (580 passed and four known expected failures in each run). All 206 target tests run without version skips, including all optimization levels and large RZZ angles. All lint hooks passed with Python 3.14 type checking. A fresh parallel documentation build passed with existing warnings; the upgrade section and command were checked in the rendered HTML.

GPT-6 via Codex assisted with extraction, review fixes, tests, and this description.

Checklist

  • The pull request only contains commits that are focused and relevant to this change.
  • I have added appropriate tests that cover the new/changed functionality.
  • I have updated the documentation to reflect these changes.
  • I have added entries to the changelog for any noteworthy additions, changes, fixes, or removals.
  • I have added migration instructions to the upgrade guide (if needed).
  • The changes follow the project's style guidelines and introduce no new warnings.
  • The changes are fully tested and pass the CI checks.
  • I have reviewed my own code changes.

If PR contains AI-assisted content:

  • Any agent that created, edited, or submitted GitHub content was explicitly authorized for that scope, as required by our AI Usage Guidelines.
  • Every agent-authored or agent-edited public text body begins with the visible disclosure 🤖 *AI text below* 🤖 (titles are exempt).
  • I have disclosed AI assistance in the PR description.
  • I confirm that I have personally reviewed and understood all AI-generated content, and accept full responsibility for it.

burgholzer and others added 4 commits October 21, 2026 15:35
Extracted from #1027; retain original authorship.

Co-authored-by: Simon Hofmann <simon.t.hofmann@tum.de>
Assisted-by: GPT-6 via Codex
Extracted from #1027; retain original authorship.

Co-authored-by: Simon Hofmann <simon.t.hofmann@tum.de>
Assisted-by: GPT-6 via Codex
@github-project-automation github-project-automation Bot moved this to In Progress in MQT Applications Oct 21, 2026
@simon1hofmann simon1hofmann added feature New feature or request python Pull requests that update Python code mqt.bench Issues that affect mqt.bench minor Part of a minor release labels Oct 21, 2026
@codecov

codecov Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@simon1hofmann simon1hofmann mentioned this pull request Oct 21, 2026
11 of 12 tasks
burgholzer and others added 3 commits October 21, 2026 15:46
Cover bounded target aliases and legacy Qiskit serialization. Extract registry isolation from #1027. Remove the extra test file.

Co-authored-by: Simon Hofmann <simon.t.hofmann@tum.de>
Cover old Qiskit rejection and narrower caller-defined RZZ bounds.

Co-authored-by: Simon Hofmann <simon.t.hofmann@tum.de>
@simon1hofmann
simon1hofmann added this pull request to stack #1091 October 21, 2026 13:47
simon1hofmann and others added 8 commits October 21, 2026 15:57
Keep equivalent RX aliases on every supported physical site, including targets that also expose a standard X gate. Retain phase-correct local lowering and add mapped regressions.


Assisted-by: GPT-6 via Codex
…tional-heron

# Conflicts:
#	CHANGELOG.md
#	tests/test_targets.py
Use the same notebook build ordering as #1088 to prevent concurrent HTML and Markdown builds from deleting each other’s example output.
@simon1hofmann
simon1hofmann marked this pull request as ready for review October 21, 2026 14:53

@burgholzer burgholzer left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally LGTM. Just two small requests for taking another look.

Comment thread src/mqt/bench/targets/devices/ibm.py Outdated
Comment thread src/mqt/bench/targets/gatesets/ibm.py Outdated
Comment thread src/mqt/bench/targets/gatesets/ibm.py
Use a shared packaging.version check while keeping Qiskit 2.1.2 support. Use theta parameters, simplify the local wrapping traversal and phase correction, and cover all optimization levels and large angles.

Assisted-by: GPT-6 via Codex
Preserve the merged device, documentation, and registry changes alongside native IonQ and Rigetti lowering.

Assisted-by: GPT-6 via Codex
Cover arbitrary U/RX compilation at all optimization levels for native and mapped targets, and check session equivalences remain unchanged. Keep local lowering because preset passes do not consistently enforce fixed R/RX angles. Restore noxfile.py to main.

Assisted-by: GPT-6 via Codex
Refresh the #1087 base after #1086 review fixes and current-main updates while preserving fractional gate handling.

Assisted-by: GPT-6 via Codex
Base automatically changed from codex/bench-native-gate-lowering to main October 21, 2026 17:39
Update fractional Heron against the merged #1086 base while preserving its source tree.

Assisted-by: GPT-6 via Codex

@burgholzer burgholzer left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one further idea. I think that is really the cleaner option here. 2.2 has been around for a while and should not be too controversial. Let's simply add a lower bound on the latest patch release in the 2.2 series. Then, after simplifying feel free to merge 🚀

Comment thread src/mqt/bench/targets/gatesets/ibm.py Outdated
Register fractional Heron targets unconditionally, remove obsolete compatibility guards and tests, and document the new Qiskit minimum and upgrade command.

Assisted-by: GPT-6 via Codex
@simon1hofmann
simon1hofmann merged commit 44ad5e8 into main Oct 21, 2026
15 checks passed
@simon1hofmann
simon1hofmann deleted the codex/bench-fractional-heron branch October 21, 2026 18:58
@github-project-automation github-project-automation Bot moved this from In Progress to Done in MQT Applications Oct 21, 2026
simon1hofmann added a commit that referenced this pull request Oct 22, 2026
simon1hofmann added a commit that referenced this pull request Oct 23, 2026
* Use version-aware Clifford+T synthesis

* Use packaging for Qiskit version comparison

* Remove prerelease-specific Clifford+T test

* Retain Clifford+T optimization after synthesis

* 🐛 Preserve Clifford+T basis after synthesis

Assisted-by: GPT-5 via Codex

* 📝 Link Clifford+T fix to #1093

Assisted-by: GPT-5 via Codex

* 🐛 Preserve Clifford+T basis after synthesis

Assisted-by: GPT-5 via Codex

* 📝 Link Clifford+T fix to #1093

Assisted-by: GPT-5 via Codex

* 🐛 Lower inverse Clifford gates in mirrors

Pass the target and equivalence library to high-level synthesis so inverse ISWAP and DCX definitions are lowered before basis translation. Cover both gates at every optimization level and sort the changelog reference.

Assisted-by: GPT-6 via Codex

* ♻️ Simplify Clifford+T compilation orchestration

Run continuous optimization, Solovay-Kitaev synthesis, and discrete cleanup
in one staged pass manager. Disable permutation elision for native circuits
so QASM exports preserve wire ordering without manual permutation repair.
Reuse only discrete cleanup for exact mirrors and share the final run path.

Cover all optimization levels and mirror variants with QASM2/QASM3
permutation round trips. Keep Qiskit 2.2.3 and the synthesis algorithm.

Assisted-by: GPT-6 via Codex

* 📝 Place #1081 changelog entry below #1087

---------

Signed-off-by: simon1hofmann <119581649+simon1hofmann@users.noreply.github.com>
Co-authored-by: Lukas Burgholzer <burgholzer@me.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature New feature or request minor Part of a minor release mqt.bench Issues that affect mqt.bench python Pull requests that update Python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants