munich-quantum-toolkit / munich-quantum-toolkit/qmap

🐛 Not supported control gates in Mapper.cpp

Open
#843 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

c++ enhancement refactor
Dominant language
C++
Stars
146
Forks
41
Avg merge
6h 47m
Merged PRs (30d)
45

Description

System and Environment Information

Ubuntu- 22.04 in docker image
C++ version

Bug Description

We are using a Device supporting CZ as nativ gate while in Mapper.cpp assert(g->getType() == qc::X ) we propse therefore to extend it for cases of CZ and CY else the method crashes and aboards

Steps to Reproduce

We transpile an arbitrary circuit into an architectures native gate set and try to map it on the couplingmap using Qmap.
Since our gate set contains Cz we need to decompose all Cx operations into HCzH ... . In this case Qmap crashes as it does not handle the case of an operation having controll qubits without being the type of quake.X0P

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in Mapper.cpp at the assert that requires qc::X and reproduce the crash by mapping a circuit whose native gate set contains CZ. Check how controlled operations are represented, including CZ and CY, and verify that mapping no longer aborts for the reported decomposition scenario.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.