munich-quantum-toolkit / munich-quantum-toolkit/qmap
🐛 Not supported control gates in Mapper.cpp
Nobody has claimed this yet.
- 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
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- 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